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_CORES 611 SJAVAC_SERVER_JAVA 612 JOBS 613 MEMORY_SIZE 614 NUM_CORES 615 ENABLE_INTREE_EC 616 SALIB_NAME 617 HOTSPOT_MAKE_ARGS 618 FIXPATH 619 LIBCXX 620 LLVM_LIBS 621 LLVM_LDFLAGS 622 LLVM_CFLAGS 623 LLVM_CONFIG 624 LIBFFI_LIBS 625 LIBFFI_CFLAGS 626 STATIC_CXX_SETTING 627 LIBDL 628 LIBM 629 LIBZIP_CAN_USE_MMAP 630 USE_EXTERNAL_LIBZ 631 USE_EXTERNAL_LIBGIF 632 USE_EXTERNAL_LIBJPEG 633 ALSA_LIBS 634 ALSA_CFLAGS 635 FREETYPE2_LIB_PATH 636 USING_SYSTEM_FT_LIB 637 FREETYPE2_LIBS 638 FREETYPE2_CFLAGS 639 CUPS_CFLAGS 640 OPENWIN_HOME 641 X_EXTRA_LIBS 642 X_LIBS 643 X_PRE_LIBS 644 X_CFLAGS 645 XMKMF 646 CXXFLAGS_DEBUG_SYMBOLS 647 CFLAGS_DEBUG_SYMBOLS 648 ZIP_DEBUGINFO_FILES 649 ENABLE_DEBUG_SYMBOLS 650 LDFLAGS_CXX_JDK 651 LDFLAGS_JDKEXE_SUFFIX 652 LDFLAGS_JDKLIB_SUFFIX 653 LDFLAGS_JDKEXE 654 LDFLAGS_JDKLIB 655 CXXFLAGS_JDKEXE 656 CXXFLAGS_JDKLIB 657 CFLAGS_JDKEXE 658 CFLAGS_JDKLIB 659 MACOSX_VERSION_MIN 660 PACKAGE_PATH 661 LEGACY_EXTRA_LDFLAGS 662 LEGACY_EXTRA_CXXFLAGS 663 LEGACY_EXTRA_CFLAGS 664 CXX_FLAG_DEPS 665 C_FLAG_DEPS 666 CXX_O_FLAG_NONE 667 CXX_O_FLAG_NORM 668 CXX_O_FLAG_HI 669 CXX_O_FLAG_HIGHEST 670 C_O_FLAG_NONE 671 C_O_FLAG_NORM 672 C_O_FLAG_HI 673 C_O_FLAG_HIGHEST 674 POST_MCS_CMD 675 POST_STRIP_CMD 676 SET_EXECUTABLE_ORIGIN 677 SET_SHARED_LIBRARY_ORIGIN 678 CXX_FLAG_REORDER 679 C_FLAG_REORDER 680 SET_SHARED_LIBRARY_MAPFILE 681 SET_SHARED_LIBRARY_NAME 682 SHARED_LIBRARY_FLAGS 683 EXE_SUFFIX 684 STATIC_LIBRARY_SUFFIX 685 SHARED_LIBRARY_SUFFIX 686 LIBRARY_PREFIX 687 STATIC_LIBRARY 688 SHARED_LIBRARY 689 OBJ_SUFFIX 690 COMPILER_SUPPORTS_TARGET_BITS_FLAG 691 LIPO 692 ac_ct_OBJDUMP 693 OBJDUMP 694 ac_ct_OBJCOPY 695 OBJCOPY 696 MCS 697 STRIP 698 GNM 699 NM 700 AS 701 CXXCPP 702 CPP 703 COMPILER_TYPE 704 RC_FLAGS 705 DUMPBIN 706 WINAR 707 HOTSPOT_RC 708 HOTSPOT_MT 709 RC 710 MT 711 WINLD 712 HOTSPOT_LD 713 HOTSPOT_CXX 714 ARFLAGS 715 AR 716 LDEXECXX 717 LDCXX 718 LDEXE 719 LD 720 ac_ct_OBJC 721 OBJCFLAGS 722 OBJC 723 ac_ct_CXX 724 CXXFLAGS 725 CXX 726 ac_ct_PROPER_COMPILER_CXX 727 PROPER_COMPILER_CXX 728 POTENTIAL_CXX 729 TOOLS_DIR_CXX 730 ac_ct_PROPER_COMPILER_CC 731 PROPER_COMPILER_CC 732 POTENTIAL_CC 733 TOOLS_DIR_CC 734 BUILD_LD 735 BUILD_CXX 736 BUILD_CC 737 MSVCR_DLL 738 DXSDK_INCLUDE_PATH 739 DXSDK_LIB_PATH 740 VS_PATH 741 VS_LIB 742 VS_INCLUDE 743 CYGWIN_LINK 744 AR_OUT_OPTION 745 LD_OUT_OPTION 746 EXE_OUT_OPTION 747 CC_OUT_OPTION 748 BUILD_HOTSPOT 749 HOTSPOT_DIST 750 BUILD_OUTPUT 751 OVERRIDE_SRC_ROOT 752 ADD_SRC_ROOT 753 JDK_TOPDIR 754 NASHORN_TOPDIR 755 HOTSPOT_TOPDIR 756 JAXWS_TOPDIR 757 JAXP_TOPDIR 758 CORBA_TOPDIR 759 LANGTOOLS_TOPDIR 760 BOOT_JDK_JVMARGS 761 JAVAC_FLAGS 762 BOOT_JDK_SOURCETARGET 763 BOOT_JDK 764 BOOT_TOOLSJAR 765 BOOT_RTJAR 766 JAVA_CHECK 767 JAVAC_CHECK 768 COOKED_BUILD_NUMBER 769 JDK_VERSION 770 COPYRIGHT_YEAR 771 MACOSX_BUNDLE_ID_BASE 772 MACOSX_BUNDLE_NAME_BASE 773 COMPANY_NAME 774 JDK_RC_PLATFORM_NAME 775 PRODUCT_SUFFIX 776 PRODUCT_NAME 777 LAUNCHER_NAME 778 MILESTONE 779 JDK_BUILD_NUMBER 780 JDK_UPDATE_VERSION 781 JDK_MICRO_VERSION 782 JDK_MINOR_VERSION 783 JDK_MAJOR_VERSION 784 USER_RELEASE_SUFFIX 785 COMPRESS_JARS 786 UNLIMITED_CRYPTO 787 CACERTS_FILE 788 TEST_IN_BUILD 789 BUILD_HEADLESS 790 SUPPORT_HEADFUL 791 SUPPORT_HEADLESS 792 BDEPS_FTP 793 BDEPS_UNZIP 794 OS_VERSION_MICRO 795 OS_VERSION_MINOR 796 OS_VERSION_MAJOR 797 PKG_CONFIG 798 XATTR 799 TIME 800 STAT 801 HG 802 READELF 803 OTOOL 804 LDD 805 ZIP 806 UNZIP 807 FIND_DELETE 808 MAKE 809 CHECK_TOOLSDIR_MAKE 810 CHECK_TOOLSDIR_GMAKE 811 CHECK_MAKE 812 CHECK_GMAKE 813 PKGHANDLER 814 OUTPUT_ROOT 815 CONF_NAME 816 SPEC 817 BUILD_VARIANT_RELEASE 818 DEBUG_CLASSFILES 819 FASTDEBUG 820 VARIANT 821 DEBUG_LEVEL 822 MACOSX_UNIVERSAL 823 INCLUDE_SA 824 JVM_VARIANT_ZEROSHARK 825 JVM_VARIANT_ZERO 826 JVM_VARIANT_KERNEL 827 JVM_VARIANT_MINIMAL1 828 JVM_VARIANT_CLIENT 829 JVM_VARIANT_SERVER 830 JVM_VARIANTS 831 JDK_VARIANT 832 SET_OPENJDK 833 BUILD_LOG_WRAPPER 834 BUILD_LOG_PREVIOUS 835 BUILD_LOG 836 SYS_ROOT 837 PATH_SEP 838 SRC_ROOT 839 ZERO_ARCHDEF 840 ZERO_ARCHFLAG 841 OBJEXT 842 EXEEXT 843 ac_ct_CC 844 CPPFLAGS 845 LDFLAGS 846 CFLAGS 847 CC 848 DEFINE_CROSS_COMPILE_ARCH 849 LP64 850 OPENJDK_TARGET_OS_API_DIR 851 OPENJDK_TARGET_CPU_JLI_CFLAGS 852 OPENJDK_TARGET_CPU_OSARCH 853 OPENJDK_TARGET_CPU_ISADIR 854 OPENJDK_TARGET_CPU_LIBDIR 855 OPENJDK_TARGET_CPU_LEGACY_LIB 856 OPENJDK_TARGET_CPU_LEGACY 857 REQUIRED_OS_VERSION 858 REQUIRED_OS_NAME 859 COMPILE_TYPE 860 OPENJDK_TARGET_CPU_ENDIAN 861 OPENJDK_TARGET_CPU_BITS 862 OPENJDK_TARGET_CPU_ARCH 863 OPENJDK_TARGET_CPU 864 OPENJDK_TARGET_OS_API 865 OPENJDK_TARGET_OS 866 OPENJDK_BUILD_CPU_ENDIAN 867 OPENJDK_BUILD_CPU_BITS 868 OPENJDK_BUILD_CPU_ARCH 869 OPENJDK_BUILD_CPU 870 OPENJDK_BUILD_OS_API 871 OPENJDK_BUILD_OS 872 OPENJDK_BUILD_AUTOCONF_NAME 873 OPENJDK_TARGET_AUTOCONF_NAME 874 target_os 875 target_vendor 876 target_cpu 877 target 878 host_os 879 host_vendor 880 host_cpu 881 host 882 build_os 883 build_vendor 884 build_cpu 885 build 886 SETFILE 887 DF 888 READLINK 889 CYGPATH 890 NAWK 891 SED 892 FGREP 893 EGREP 894 GREP 895 AWK 896 XARGS 897 WHICH 898 WC 899 UNIQ 900 UNAME 901 TR 902 TOUCH 903 TEE 904 TAR 905 TAIL 906 SORT 907 SH 908 RM 909 THEPWDCMD 910 PRINTF 911 MV 912 MKTEMP 913 MKDIR 914 LS 915 LN 916 HEAD 917 FIND 918 FILE 919 EXPR 920 ECHO 921 DIRNAME 922 DIFF 923 DATE 924 CUT 925 CPIO 926 CP 927 COMM 928 CMP 929 CHMOD 930 CAT 931 BASH 932 BASENAME 933 DATE_WHEN_CONFIGURED 934 CONFIGURE_COMMAND_LINE 935 CUSTOM_MAKE_DIR 936 target_alias 937 host_alias 938 build_alias 939 LIBS 940 ECHO_T 941 ECHO_N 942 ECHO_C 943 DEFS 944 mandir 945 localedir 946 libdir 947 psdir 948 pdfdir 949 dvidir 950 htmldir 951 infodir 952 docdir 953 oldincludedir 954 includedir 955 localstatedir 956 sharedstatedir 957 sysconfdir 958 datadir 959 datarootdir 960 libexecdir 961 sbindir 962 bindir 963 program_transform_name 964 prefix 965 exec_prefix 966 PACKAGE_URL 967 PACKAGE_BUGREPORT 968 PACKAGE_STRING 969 PACKAGE_VERSION 970 PACKAGE_TARNAME 971 PACKAGE_NAME 972 PATH_SEPARATOR 973 SHELL' 974 ac_subst_files='' 975 ac_user_opts=' 976 enable_option_checking 977 with_custom_make_dir 978 with_target_bits 979 with_sys_root 980 with_tools_dir 981 with_devkit 982 enable_openjdk_only 983 with_jdk_variant 984 with_jvm_variants 985 enable_debug 986 with_debug_level 987 with_conf_name 988 with_builddeps_conf 989 with_builddeps_server 990 with_builddeps_dir 991 with_builddeps_group 992 enable_headful 993 enable_hotspot_test_in_build 994 with_cacerts_file 995 enable_unlimited_crypto 996 with_milestone 997 with_build_number 998 with_user_release_suffix 999 with_boot_jdk 1000 with_boot_jdk_jvmargs 1001 with_add_source_root 1002 with_override_source_root 1003 with_adds_and_overrides 1004 with_override_langtools 1005 with_override_corba 1006 with_override_jaxp 1007 with_override_jaxws 1008 with_override_hotspot 1009 with_override_jdk 1010 with_import_hotspot 1011 with_msvcr_dll 1012 with_dxsdk 1013 with_dxsdk_lib 1014 with_dxsdk_include 1015 with_extra_cflags 1016 with_extra_cxxflags 1017 with_extra_ldflags 1018 enable_debug_symbols 1019 enable_zip_debug_info 1020 enable_macosx_runtime_support 1021 with_x 1022 with_cups 1023 with_cups_include 1024 with_freetype 1025 with_alsa 1026 with_alsa_include 1027 with_alsa_lib 1028 with_giflib 1029 with_zlib 1030 with_stdc__lib 1031 with_num_cores 1032 with_memory_size 1033 with_jobs 1034 with_sjavac_server_java 1035 with_sjavac_server_cores 1036 enable_sjavac 1037 enable_precompiled_headers 1038 enable_ccache 1039 with_ccache_dir 1040 ' 1041 ac_precious_vars='build_alias 1042 host_alias 1043 target_alias 1044 CC 1045 CFLAGS 1046 LDFLAGS 1047 LIBS 1048 CPPFLAGS 1049 PKG_CONFIG 1050 CXX 1051 CXXFLAGS 1052 CCC 1053 OBJC 1054 OBJCFLAGS 1055 CPP 1056 CXXCPP 1057 XMKMF 1058 FREETYPE2_CFLAGS 1059 FREETYPE2_LIBS 1060 ALSA_CFLAGS 1061 ALSA_LIBS 1062 LIBFFI_CFLAGS 1063 LIBFFI_LIBS' 1064 1065 1066 # Initialize some variables set by options. 1067 ac_init_help= 1068 ac_init_version=false 1069 ac_unrecognized_opts= 1070 ac_unrecognized_sep= 1071 # The variables have the same names as the options, with 1072 # dashes changed to underlines. 1073 cache_file=/dev/null 1074 exec_prefix=NONE 1075 no_create= 1076 no_recursion= 1077 prefix=NONE 1078 program_prefix=NONE 1079 program_suffix=NONE 1080 program_transform_name=s,x,x, 1081 silent= 1082 site= 1083 srcdir= 1084 verbose= 1085 x_includes=NONE 1086 x_libraries=NONE 1087 1088 # Installation directory options. 1089 # These are left unexpanded so users can "make install exec_prefix=/foo" 1090 # and all the variables that are supposed to be based on exec_prefix 1091 # by default will actually change. 1092 # Use braces instead of parens because sh, perl, etc. also accept them. 1093 # (The list follows the same order as the GNU Coding Standards.) 1094 bindir='${exec_prefix}/bin' 1095 sbindir='${exec_prefix}/sbin' 1096 libexecdir='${exec_prefix}/libexec' 1097 datarootdir='${prefix}/share' 1098 datadir='${datarootdir}' 1099 sysconfdir='${prefix}/etc' 1100 sharedstatedir='${prefix}/com' 1101 localstatedir='${prefix}/var' 1102 includedir='${prefix}/include' 1103 oldincludedir='/usr/include' 1104 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 1105 infodir='${datarootdir}/info' 1106 htmldir='${docdir}' 1107 dvidir='${docdir}' 1108 pdfdir='${docdir}' 1109 psdir='${docdir}' 1110 libdir='${exec_prefix}/lib' 1111 localedir='${datarootdir}/locale' 1112 mandir='${datarootdir}/man' 1113 1114 ac_prev= 1115 ac_dashdash= 1116 for ac_option 1117 do 1118 # If the previous option needs an argument, assign it. 1119 if test -n "$ac_prev"; then 1120 eval $ac_prev=\$ac_option 1121 ac_prev= 1122 continue 1123 fi 1124 1125 case $ac_option in 1126 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 1127 *=) ac_optarg= ;; 1128 *) ac_optarg=yes ;; 1129 esac 1130 1131 # Accept the important Cygnus configure options, so we can diagnose typos. 1132 1133 case $ac_dashdash$ac_option in 1134 --) 1135 ac_dashdash=yes ;; 1136 1137 -bindir | --bindir | --bindi | --bind | --bin | --bi) 1138 ac_prev=bindir ;; 1139 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 1140 bindir=$ac_optarg ;; 1141 1142 -build | --build | --buil | --bui | --bu) 1143 ac_prev=build_alias ;; 1144 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 1145 build_alias=$ac_optarg ;; 1146 1147 -cache-file | --cache-file | --cache-fil | --cache-fi \ 1148 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 1149 ac_prev=cache_file ;; 1150 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 1151 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 1152 cache_file=$ac_optarg ;; 1153 1154 --config-cache | -C) 1155 cache_file=config.cache ;; 1156 1157 -datadir | --datadir | --datadi | --datad) 1158 ac_prev=datadir ;; 1159 -datadir=* | --datadir=* | --datadi=* | --datad=*) 1160 datadir=$ac_optarg ;; 1161 1162 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 1163 | --dataroo | --dataro | --datar) 1164 ac_prev=datarootdir ;; 1165 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 1166 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 1167 datarootdir=$ac_optarg ;; 1168 1169 -disable-* | --disable-*) 1170 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 1171 # Reject names that are not valid shell variable names. 1172 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1173 as_fn_error $? "invalid feature name: $ac_useropt" 1174 ac_useropt_orig=$ac_useropt 1175 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1176 case $ac_user_opts in 1177 *" 1178 "enable_$ac_useropt" 1179 "*) ;; 1180 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 1181 ac_unrecognized_sep=', ';; 1182 esac 1183 eval enable_$ac_useropt=no ;; 1184 1185 -docdir | --docdir | --docdi | --doc | --do) 1186 ac_prev=docdir ;; 1187 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 1188 docdir=$ac_optarg ;; 1189 1190 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 1191 ac_prev=dvidir ;; 1192 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 1193 dvidir=$ac_optarg ;; 1194 1195 -enable-* | --enable-*) 1196 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 1197 # Reject names that are not valid shell variable names. 1198 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1199 as_fn_error $? "invalid feature name: $ac_useropt" 1200 ac_useropt_orig=$ac_useropt 1201 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1202 case $ac_user_opts in 1203 *" 1204 "enable_$ac_useropt" 1205 "*) ;; 1206 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 1207 ac_unrecognized_sep=', ';; 1208 esac 1209 eval enable_$ac_useropt=\$ac_optarg ;; 1210 1211 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 1212 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 1213 | --exec | --exe | --ex) 1214 ac_prev=exec_prefix ;; 1215 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 1216 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 1217 | --exec=* | --exe=* | --ex=*) 1218 exec_prefix=$ac_optarg ;; 1219 1220 -gas | --gas | --ga | --g) 1221 # Obsolete; use --with-gas. 1222 with_gas=yes ;; 1223 1224 -help | --help | --hel | --he | -h) 1225 ac_init_help=long ;; 1226 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1227 ac_init_help=recursive ;; 1228 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1229 ac_init_help=short ;; 1230 1231 -host | --host | --hos | --ho) 1232 ac_prev=host_alias ;; 1233 -host=* | --host=* | --hos=* | --ho=*) 1234 host_alias=$ac_optarg ;; 1235 1236 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1237 ac_prev=htmldir ;; 1238 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1239 | --ht=*) 1240 htmldir=$ac_optarg ;; 1241 1242 -includedir | --includedir | --includedi | --included | --include \ 1243 | --includ | --inclu | --incl | --inc) 1244 ac_prev=includedir ;; 1245 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1246 | --includ=* | --inclu=* | --incl=* | --inc=*) 1247 includedir=$ac_optarg ;; 1248 1249 -infodir | --infodir | --infodi | --infod | --info | --inf) 1250 ac_prev=infodir ;; 1251 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1252 infodir=$ac_optarg ;; 1253 1254 -libdir | --libdir | --libdi | --libd) 1255 ac_prev=libdir ;; 1256 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1257 libdir=$ac_optarg ;; 1258 1259 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1260 | --libexe | --libex | --libe) 1261 ac_prev=libexecdir ;; 1262 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1263 | --libexe=* | --libex=* | --libe=*) 1264 libexecdir=$ac_optarg ;; 1265 1266 -localedir | --localedir | --localedi | --localed | --locale) 1267 ac_prev=localedir ;; 1268 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1269 localedir=$ac_optarg ;; 1270 1271 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1272 | --localstate | --localstat | --localsta | --localst | --locals) 1273 ac_prev=localstatedir ;; 1274 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1275 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1276 localstatedir=$ac_optarg ;; 1277 1278 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1279 ac_prev=mandir ;; 1280 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1281 mandir=$ac_optarg ;; 1282 1283 -nfp | --nfp | --nf) 1284 # Obsolete; use --without-fp. 1285 with_fp=no ;; 1286 1287 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1288 | --no-cr | --no-c | -n) 1289 no_create=yes ;; 1290 1291 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1292 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1293 no_recursion=yes ;; 1294 1295 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1296 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1297 | --oldin | --oldi | --old | --ol | --o) 1298 ac_prev=oldincludedir ;; 1299 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1300 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1301 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1302 oldincludedir=$ac_optarg ;; 1303 1304 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1305 ac_prev=prefix ;; 1306 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1307 prefix=$ac_optarg ;; 1308 1309 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1310 | --program-pre | --program-pr | --program-p) 1311 ac_prev=program_prefix ;; 1312 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1313 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1314 program_prefix=$ac_optarg ;; 1315 1316 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1317 | --program-suf | --program-su | --program-s) 1318 ac_prev=program_suffix ;; 1319 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1320 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1321 program_suffix=$ac_optarg ;; 1322 1323 -program-transform-name | --program-transform-name \ 1324 | --program-transform-nam | --program-transform-na \ 1325 | --program-transform-n | --program-transform- \ 1326 | --program-transform | --program-transfor \ 1327 | --program-transfo | --program-transf \ 1328 | --program-trans | --program-tran \ 1329 | --progr-tra | --program-tr | --program-t) 1330 ac_prev=program_transform_name ;; 1331 -program-transform-name=* | --program-transform-name=* \ 1332 | --program-transform-nam=* | --program-transform-na=* \ 1333 | --program-transform-n=* | --program-transform-=* \ 1334 | --program-transform=* | --program-transfor=* \ 1335 | --program-transfo=* | --program-transf=* \ 1336 | --program-trans=* | --program-tran=* \ 1337 | --progr-tra=* | --program-tr=* | --program-t=*) 1338 program_transform_name=$ac_optarg ;; 1339 1340 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1341 ac_prev=pdfdir ;; 1342 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1343 pdfdir=$ac_optarg ;; 1344 1345 -psdir | --psdir | --psdi | --psd | --ps) 1346 ac_prev=psdir ;; 1347 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1348 psdir=$ac_optarg ;; 1349 1350 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1351 | -silent | --silent | --silen | --sile | --sil) 1352 silent=yes ;; 1353 1354 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1355 ac_prev=sbindir ;; 1356 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1357 | --sbi=* | --sb=*) 1358 sbindir=$ac_optarg ;; 1359 1360 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1361 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1362 | --sharedst | --shareds | --shared | --share | --shar \ 1363 | --sha | --sh) 1364 ac_prev=sharedstatedir ;; 1365 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1366 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1367 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1368 | --sha=* | --sh=*) 1369 sharedstatedir=$ac_optarg ;; 1370 1371 -site | --site | --sit) 1372 ac_prev=site ;; 1373 -site=* | --site=* | --sit=*) 1374 site=$ac_optarg ;; 1375 1376 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1377 ac_prev=srcdir ;; 1378 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1379 srcdir=$ac_optarg ;; 1380 1381 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1382 | --syscon | --sysco | --sysc | --sys | --sy) 1383 ac_prev=sysconfdir ;; 1384 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1385 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1386 sysconfdir=$ac_optarg ;; 1387 1388 -target | --target | --targe | --targ | --tar | --ta | --t) 1389 ac_prev=target_alias ;; 1390 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1391 target_alias=$ac_optarg ;; 1392 1393 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1394 verbose=yes ;; 1395 1396 -version | --version | --versio | --versi | --vers | -V) 1397 ac_init_version=: ;; 1398 1399 -with-* | --with-*) 1400 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1401 # Reject names that are not valid shell variable names. 1402 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1403 as_fn_error $? "invalid package name: $ac_useropt" 1404 ac_useropt_orig=$ac_useropt 1405 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1406 case $ac_user_opts in 1407 *" 1408 "with_$ac_useropt" 1409 "*) ;; 1410 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1411 ac_unrecognized_sep=', ';; 1412 esac 1413 eval with_$ac_useropt=\$ac_optarg ;; 1414 1415 -without-* | --without-*) 1416 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1417 # Reject names that are not valid shell variable names. 1418 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1419 as_fn_error $? "invalid package name: $ac_useropt" 1420 ac_useropt_orig=$ac_useropt 1421 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1422 case $ac_user_opts in 1423 *" 1424 "with_$ac_useropt" 1425 "*) ;; 1426 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1427 ac_unrecognized_sep=', ';; 1428 esac 1429 eval with_$ac_useropt=no ;; 1430 1431 --x) 1432 # Obsolete; use --with-x. 1433 with_x=yes ;; 1434 1435 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1436 | --x-incl | --x-inc | --x-in | --x-i) 1437 ac_prev=x_includes ;; 1438 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1439 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1440 x_includes=$ac_optarg ;; 1441 1442 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1443 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1444 ac_prev=x_libraries ;; 1445 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1446 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1447 x_libraries=$ac_optarg ;; 1448 1449 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1450 Try \`$0 --help' for more information" 1451 ;; 1452 1453 *=*) 1454 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1455 # Reject names that are not valid shell variable names. 1456 case $ac_envvar in #( 1457 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1458 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1459 esac 1460 eval $ac_envvar=\$ac_optarg 1461 export $ac_envvar ;; 1462 1463 *) 1464 # FIXME: should be removed in autoconf 3.0. 1465 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 1466 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1467 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1468 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1469 ;; 1470 1471 esac 1472 done 1473 1474 if test -n "$ac_prev"; then 1475 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1476 as_fn_error $? "missing argument to $ac_option" 1477 fi 1478 1479 if test -n "$ac_unrecognized_opts"; then 1480 case $enable_option_checking in 1481 no) ;; 1482 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1483 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1484 esac 1485 fi 1486 1487 # Check all directory arguments for consistency. 1488 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1489 datadir sysconfdir sharedstatedir localstatedir includedir \ 1490 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1491 libdir localedir mandir 1492 do 1493 eval ac_val=\$$ac_var 1494 # Remove trailing slashes. 1495 case $ac_val in 1496 */ ) 1497 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1498 eval $ac_var=\$ac_val;; 1499 esac 1500 # Be sure to have absolute directory names. 1501 case $ac_val in 1502 [\\/$]* | ?:[\\/]* ) continue;; 1503 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1504 esac 1505 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1506 done 1507 1508 # There might be people who depend on the old broken behavior: `$host' 1509 # used to hold the argument of --host etc. 1510 # FIXME: To remove some day. 1511 build=$build_alias 1512 host=$host_alias 1513 target=$target_alias 1514 1515 # FIXME: To remove some day. 1516 if test "x$host_alias" != x; then 1517 if test "x$build_alias" = x; then 1518 cross_compiling=maybe 1519 $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. 1520 If a cross compiler is detected then cross compile mode will be used" >&2 1521 elif test "x$build_alias" != "x$host_alias"; then 1522 cross_compiling=yes 1523 fi 1524 fi 1525 1526 ac_tool_prefix= 1527 test -n "$host_alias" && ac_tool_prefix=$host_alias- 1528 1529 test "$silent" = yes && exec 6>/dev/null 1530 1531 1532 ac_pwd=`pwd` && test -n "$ac_pwd" && 1533 ac_ls_di=`ls -di .` && 1534 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1535 as_fn_error $? "working directory cannot be determined" 1536 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1537 as_fn_error $? "pwd does not report name of working directory" 1538 1539 1540 # Find the source files, if location was not specified. 1541 if test -z "$srcdir"; then 1542 ac_srcdir_defaulted=yes 1543 # Try the directory containing this script, then the parent directory. 1544 ac_confdir=`$as_dirname -- "$as_myself" || 1545 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1546 X"$as_myself" : 'X\(//\)[^/]' \| \ 1547 X"$as_myself" : 'X\(//\)$' \| \ 1548 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1549 $as_echo X"$as_myself" | 1550 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1551 s//\1/ 1552 q 1553 } 1554 /^X\(\/\/\)[^/].*/{ 1555 s//\1/ 1556 q 1557 } 1558 /^X\(\/\/\)$/{ 1559 s//\1/ 1560 q 1561 } 1562 /^X\(\/\).*/{ 1563 s//\1/ 1564 q 1565 } 1566 s/.*/./; q'` 1567 srcdir=$ac_confdir 1568 if test ! -r "$srcdir/$ac_unique_file"; then 1569 srcdir=.. 1570 fi 1571 else 1572 ac_srcdir_defaulted=no 1573 fi 1574 if test ! -r "$srcdir/$ac_unique_file"; then 1575 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1576 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1577 fi 1578 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1579 ac_abs_confdir=`( 1580 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1581 pwd)` 1582 # When building in place, set srcdir=. 1583 if test "$ac_abs_confdir" = "$ac_pwd"; then 1584 srcdir=. 1585 fi 1586 # Remove unnecessary trailing slashes from srcdir. 1587 # Double slashes in file names in object file debugging info 1588 # mess up M-x gdb in Emacs. 1589 case $srcdir in 1590 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1591 esac 1592 for ac_var in $ac_precious_vars; do 1593 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1594 eval ac_env_${ac_var}_value=\$${ac_var} 1595 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1596 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1597 done 1598 1599 # 1600 # Report the --help message. 1601 # 1602 if test "$ac_init_help" = "long"; then 1603 # Omit some internal or obsolete options to make the list less imposing. 1604 # This message is too long to be a string in the A/UX 3.1 sh. 1605 cat <<_ACEOF 1606 \`configure' configures OpenJDK jdk8 to adapt to many kinds of systems. 1607 1608 Usage: $0 [OPTION]... [VAR=VALUE]... 1609 1610 To assign environment variables (e.g., CC, CFLAGS...), specify them as 1611 VAR=VALUE. See below for descriptions of some of the useful variables. 1612 1613 Defaults for the options are specified in brackets. 1614 1615 Configuration: 1616 -h, --help display this help and exit 1617 --help=short display options specific to this package 1618 --help=recursive display the short help of all the included packages 1619 -V, --version display version information and exit 1620 -q, --quiet, --silent do not print \`checking ...' messages 1621 --cache-file=FILE cache test results in FILE [disabled] 1622 -C, --config-cache alias for \`--cache-file=config.cache' 1623 -n, --no-create do not create output files 1624 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1625 1626 Installation directories: 1627 --prefix=PREFIX install architecture-independent files in PREFIX 1628 [$ac_default_prefix] 1629 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1630 [PREFIX] 1631 1632 By default, \`make install' will install all the files in 1633 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1634 an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1635 for instance \`--prefix=\$HOME'. 1636 1637 For better control, use the options below. 1638 1639 Fine tuning of the installation directories: 1640 --bindir=DIR user executables [EPREFIX/bin] 1641 --sbindir=DIR system admin executables [EPREFIX/sbin] 1642 --libexecdir=DIR program executables [EPREFIX/libexec] 1643 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1644 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1645 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1646 --libdir=DIR object code libraries [EPREFIX/lib] 1647 --includedir=DIR C header files [PREFIX/include] 1648 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1649 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1650 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1651 --infodir=DIR info documentation [DATAROOTDIR/info] 1652 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1653 --mandir=DIR man documentation [DATAROOTDIR/man] 1654 --docdir=DIR documentation root [DATAROOTDIR/doc/openjdk] 1655 --htmldir=DIR html documentation [DOCDIR] 1656 --dvidir=DIR dvi documentation [DOCDIR] 1657 --pdfdir=DIR pdf documentation [DOCDIR] 1658 --psdir=DIR ps documentation [DOCDIR] 1659 _ACEOF 1660 1661 cat <<\_ACEOF 1662 1663 X features: 1664 --x-includes=DIR X include files are in DIR 1665 --x-libraries=DIR X library files are in DIR 1666 1667 System types: 1668 --build=BUILD configure for building on BUILD [guessed] 1669 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1670 --target=TARGET configure for building compilers for TARGET [HOST] 1671 _ACEOF 1672 fi 1673 1674 if test -n "$ac_init_help"; then 1675 case $ac_init_help in 1676 short | recursive ) echo "Configuration of OpenJDK jdk8:";; 1677 esac 1678 cat <<\_ACEOF 1679 1680 Optional Features: 1681 --disable-option-checking ignore unrecognized --enable/--with options 1682 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1683 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1684 --enable-openjdk-only suppress building custom source even if present 1685 [disabled] 1686 --enable-debug set the debug level to fastdebug (shorthand for 1687 --with-debug-level=fastdebug) [disabled] 1688 --disable-headful disable building headful support (graphical UI 1689 support) [enabled] 1690 --enable-hotspot-test-in-build 1691 run the Queens test after Hotspot build [disabled] 1692 --enable-unlimited-crypto 1693 Enable unlimited crypto policy [disabled] 1694 --disable-debug-symbols disable generation of debug symbols [enabled] 1695 --disable-zip-debug-info 1696 disable zipping of debug-info files [enabled] 1697 --disable-macosx-runtime-support 1698 disable the use of MacOSX Java runtime support 1699 framework [enabled] 1700 --enable-sjavac use sjavac to do fast incremental compiles 1701 [disabled] 1702 --disable-precompiled-headers 1703 disable using precompiled headers when compiling C++ 1704 [enabled] 1705 --disable-ccache disable using ccache to speed up recompilations 1706 [enabled] 1707 1708 Optional Packages: 1709 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 1710 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 1711 --with-custom-make-dir use this directory for custom build/make files 1712 --with-target-bits build 32-bit or 64-bit binaries (for platforms that 1713 support it), e.g. --with-target-bits=32 [guessed] 1714 --with-sys-root pass this sys-root to the compilers and tools (for 1715 cross-compiling) 1716 --with-tools-dir search this directory for compilers and tools (for 1717 cross-compiling) 1718 --with-devkit use this directory as base for tools-dir and 1719 sys-root (for cross-compiling) 1720 --with-jdk-variant JDK variant to build (normal) [normal] 1721 --with-jvm-variants JVM variants (separated by commas) to build (server, 1722 client, minimal1, kernel, zero, zeroshark) [server] 1723 --with-debug-level set the debug level (release, fastdebug, slowdebug) 1724 [release] 1725 --with-conf-name use this as the name of the configuration [generated 1726 from important configuration options] 1727 --with-builddeps-conf use this configuration file for the builddeps 1728 --with-builddeps-server download and use build dependencies from this server 1729 url 1730 --with-builddeps-dir store downloaded build dependencies here 1731 [/localhome/builddeps] 1732 --with-builddeps-group chgrp the downloaded build dependencies to this 1733 group 1734 --with-cacerts-file specify alternative cacerts file 1735 --with-milestone Set milestone value for build [internal] 1736 --with-build-number Set build number value for build [b00] 1737 --with-user-release-suffix 1738 Add a custom string to the version string if build 1739 number isn't set.[username_builddateb00] 1740 --with-boot-jdk path to Boot JDK (used to bootstrap build) [probed] 1741 --with-boot-jdk-jvmargs specify JVM arguments to be passed to all 1742 invocations of the Boot JDK, overriding the default 1743 values, e.g --with-boot-jdk-jvmargs="-Xmx8G 1744 -enableassertions" 1745 --with-add-source-root for each and every source directory, look in this 1746 additional source root for the same directory; if it 1747 exists and have files in it, include it in the build 1748 --with-override-source-root 1749 for each and every source directory, look in this 1750 override source root for the same directory; if it 1751 exists, use that directory instead and ignore the 1752 directory in the original source root 1753 --with-adds-and-overrides 1754 use the subdirs 'adds' and 'overrides' in the 1755 specified directory as add-source-root and 1756 override-source-root 1757 --with-override-langtools 1758 use this langtools dir for the build 1759 --with-override-corba use this corba dir for the build 1760 --with-override-jaxp use this jaxp dir for the build 1761 --with-override-jaxws use this jaxws dir for the build 1762 --with-override-hotspot use this hotspot dir for the build 1763 --with-override-jdk use this jdk dir for the build 1764 --with-import-hotspot import hotspot binaries from this jdk image or 1765 hotspot build dist dir instead of building from 1766 source 1767 --with-msvcr-dll copy this msvcr100.dll into the built JDK (Windows 1768 only) [probed] 1769 --with-dxsdk the DirectX SDK (Windows only) [probed] 1770 --with-dxsdk-lib the DirectX SDK lib directory (Windows only) 1771 [probed] 1772 --with-dxsdk-include the DirectX SDK include directory (Windows only) 1773 [probed] 1774 --with-extra-cflags extra flags to be used when compiling jdk c-files 1775 --with-extra-cxxflags extra flags to be used when compiling jdk c++-files 1776 --with-extra-ldflags extra flags to be used when linking jdk 1777 --with-x use the X Window System 1778 --with-cups specify prefix directory for the cups package 1779 (expecting the headers under PATH/include) 1780 --with-cups-include specify directory for the cups include files 1781 --with-freetype specify prefix directory for the freetype2 package 1782 (expecting the libraries under PATH/lib and the 1783 headers under PATH/include) 1784 --with-alsa specify prefix directory for the alsa package 1785 (expecting the libraries under PATH/lib and the 1786 headers under PATH/include) 1787 --with-alsa-include specify directory for the alsa include files 1788 --with-alsa-lib specify directory for the alsa library 1789 --with-giflib use giflib from build system or OpenJDK source 1790 (system, bundled) [bundled] 1791 --with-zlib use zlib from build system or OpenJDK source 1792 (system, bundled) [bundled] 1793 --with-stdc++lib=<static>,<dynamic>,<default> 1794 force linking of the C++ runtime on Linux to either 1795 static or dynamic, default is static with dynamic as 1796 fallback 1797 --with-num-cores number of cores in the build system, e.g. 1798 --with-num-cores=8 [probed] 1799 --with-memory-size memory (in MB) available in the build system, e.g. 1800 --with-memory-size=1024 [probed] 1801 --with-jobs number of parallel jobs to let make run [calculated 1802 based on cores and memory] 1803 --with-sjavac-server-java 1804 use this java binary for running the sjavac 1805 background server [Boot JDK java] 1806 --with-sjavac-server-cores 1807 use at most this number of concurrent threads on the 1808 sjavac server [probed] 1809 --with-ccache-dir where to store ccache files [~/.ccache] 1810 1811 Some influential environment variables: 1812 CC C compiler command 1813 CFLAGS C compiler flags 1814 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 1815 nonstandard directory <lib dir> 1816 LIBS libraries to pass to the linker, e.g. -l<library> 1817 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 1818 you have headers in a nonstandard directory <include dir> 1819 PKG_CONFIG path to pkg-config utility 1820 CXX C++ compiler command 1821 CXXFLAGS C++ compiler flags 1822 OBJC Objective C compiler command 1823 OBJCFLAGS Objective C compiler flags 1824 CPP C preprocessor 1825 CXXCPP C++ preprocessor 1826 XMKMF Path to xmkmf, Makefile generator for X Window System 1827 FREETYPE2_CFLAGS 1828 C compiler flags for FREETYPE2, overriding pkg-config 1829 FREETYPE2_LIBS 1830 linker flags for FREETYPE2, overriding pkg-config 1831 ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config 1832 ALSA_LIBS linker flags for ALSA, overriding pkg-config 1833 LIBFFI_CFLAGS 1834 C compiler flags for LIBFFI, overriding pkg-config 1835 LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config 1836 1837 Use these variables to override the choices made by `configure' or to help 1838 it to find libraries and programs with nonstandard names/locations. 1839 1840 Report bugs to <build-dev@openjdk.java.net>. 1841 OpenJDK home page: <http://openjdk.java.net>. 1842 _ACEOF 1843 ac_status=$? 1844 fi 1845 1846 if test "$ac_init_help" = "recursive"; then 1847 # If there are subdirs, report their specific --help. 1848 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 1849 test -d "$ac_dir" || 1850 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 1851 continue 1852 ac_builddir=. 1853 1854 case "$ac_dir" in 1855 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 1856 *) 1857 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 1858 # A ".." for each directory in $ac_dir_suffix. 1859 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 1860 case $ac_top_builddir_sub in 1861 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 1862 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 1863 esac ;; 1864 esac 1865 ac_abs_top_builddir=$ac_pwd 1866 ac_abs_builddir=$ac_pwd$ac_dir_suffix 1867 # for backward compatibility: 1868 ac_top_builddir=$ac_top_build_prefix 1869 1870 case $srcdir in 1871 .) # We are building in place. 1872 ac_srcdir=. 1873 ac_top_srcdir=$ac_top_builddir_sub 1874 ac_abs_top_srcdir=$ac_pwd ;; 1875 [\\/]* | ?:[\\/]* ) # Absolute name. 1876 ac_srcdir=$srcdir$ac_dir_suffix; 1877 ac_top_srcdir=$srcdir 1878 ac_abs_top_srcdir=$srcdir ;; 1879 *) # Relative name. 1880 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 1881 ac_top_srcdir=$ac_top_build_prefix$srcdir 1882 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 1883 esac 1884 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 1885 1886 cd "$ac_dir" || { ac_status=$?; continue; } 1887 # Check for guested configure. 1888 if test -f "$ac_srcdir/configure.gnu"; then 1889 echo && 1890 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 1891 elif test -f "$ac_srcdir/configure"; then 1892 echo && 1893 $SHELL "$ac_srcdir/configure" --help=recursive 1894 else 1895 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 1896 fi || ac_status=$? 1897 cd "$ac_pwd" || { ac_status=$?; break; } 1898 done 1899 fi 1900 1901 test -n "$ac_init_help" && exit $ac_status 1902 if $ac_init_version; then 1903 cat <<\_ACEOF 1904 OpenJDK configure jdk8 1905 generated by GNU Autoconf 2.68 1906 1907 Copyright (C) 2010 Free Software Foundation, Inc. 1908 This configure script is free software; the Free Software Foundation 1909 gives unlimited permission to copy, distribute and modify it. 1910 _ACEOF 1911 exit 1912 fi 1913 1914 ## ------------------------ ## 1915 ## Autoconf initialization. ## 1916 ## ------------------------ ## 1917 1918 # ac_fn_c_try_compile LINENO 1919 # -------------------------- 1920 # Try to compile conftest.$ac_ext, and return whether this succeeded. 1921 ac_fn_c_try_compile () 1922 { 1923 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1924 rm -f conftest.$ac_objext 1925 if { { ac_try="$ac_compile" 1926 case "(($ac_try" in 1927 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1928 *) ac_try_echo=$ac_try;; 1929 esac 1930 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1931 $as_echo "$ac_try_echo"; } >&5 1932 (eval "$ac_compile") 2>conftest.err 1933 ac_status=$? 1934 if test -s conftest.err; then 1935 grep -v '^ *+' conftest.err >conftest.er1 1936 cat conftest.er1 >&5 1937 mv -f conftest.er1 conftest.err 1938 fi 1939 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1940 test $ac_status = 0; } && { 1941 test -z "$ac_c_werror_flag" || 1942 test ! -s conftest.err 1943 } && test -s conftest.$ac_objext; then : 1944 ac_retval=0 1945 else 1946 $as_echo "$as_me: failed program was:" >&5 1947 sed 's/^/| /' conftest.$ac_ext >&5 1948 1949 ac_retval=1 1950 fi 1951 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1952 as_fn_set_status $ac_retval 1953 1954 } # ac_fn_c_try_compile 1955 1956 # ac_fn_cxx_try_compile LINENO 1957 # ---------------------------- 1958 # Try to compile conftest.$ac_ext, and return whether this succeeded. 1959 ac_fn_cxx_try_compile () 1960 { 1961 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1962 rm -f conftest.$ac_objext 1963 if { { ac_try="$ac_compile" 1964 case "(($ac_try" in 1965 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1966 *) ac_try_echo=$ac_try;; 1967 esac 1968 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1969 $as_echo "$ac_try_echo"; } >&5 1970 (eval "$ac_compile") 2>conftest.err 1971 ac_status=$? 1972 if test -s conftest.err; then 1973 grep -v '^ *+' conftest.err >conftest.er1 1974 cat conftest.er1 >&5 1975 mv -f conftest.er1 conftest.err 1976 fi 1977 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1978 test $ac_status = 0; } && { 1979 test -z "$ac_cxx_werror_flag" || 1980 test ! -s conftest.err 1981 } && test -s conftest.$ac_objext; then : 1982 ac_retval=0 1983 else 1984 $as_echo "$as_me: failed program was:" >&5 1985 sed 's/^/| /' conftest.$ac_ext >&5 1986 1987 ac_retval=1 1988 fi 1989 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1990 as_fn_set_status $ac_retval 1991 1992 } # ac_fn_cxx_try_compile 1993 1994 # ac_fn_objc_try_compile LINENO 1995 # ----------------------------- 1996 # Try to compile conftest.$ac_ext, and return whether this succeeded. 1997 ac_fn_objc_try_compile () 1998 { 1999 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2000 rm -f conftest.$ac_objext 2001 if { { ac_try="$ac_compile" 2002 case "(($ac_try" in 2003 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2004 *) ac_try_echo=$ac_try;; 2005 esac 2006 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2007 $as_echo "$ac_try_echo"; } >&5 2008 (eval "$ac_compile") 2>conftest.err 2009 ac_status=$? 2010 if test -s conftest.err; then 2011 grep -v '^ *+' conftest.err >conftest.er1 2012 cat conftest.er1 >&5 2013 mv -f conftest.er1 conftest.err 2014 fi 2015 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2016 test $ac_status = 0; } && { 2017 test -z "$ac_objc_werror_flag" || 2018 test ! -s conftest.err 2019 } && test -s conftest.$ac_objext; then : 2020 ac_retval=0 2021 else 2022 $as_echo "$as_me: failed program was:" >&5 2023 sed 's/^/| /' conftest.$ac_ext >&5 2024 2025 ac_retval=1 2026 fi 2027 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2028 as_fn_set_status $ac_retval 2029 2030 } # ac_fn_objc_try_compile 2031 2032 # ac_fn_c_try_cpp LINENO 2033 # ---------------------- 2034 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2035 ac_fn_c_try_cpp () 2036 { 2037 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2038 if { { ac_try="$ac_cpp conftest.$ac_ext" 2039 case "(($ac_try" in 2040 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2041 *) ac_try_echo=$ac_try;; 2042 esac 2043 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2044 $as_echo "$ac_try_echo"; } >&5 2045 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2046 ac_status=$? 2047 if test -s conftest.err; then 2048 grep -v '^ *+' conftest.err >conftest.er1 2049 cat conftest.er1 >&5 2050 mv -f conftest.er1 conftest.err 2051 fi 2052 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2053 test $ac_status = 0; } > conftest.i && { 2054 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 2055 test ! -s conftest.err 2056 }; then : 2057 ac_retval=0 2058 else 2059 $as_echo "$as_me: failed program was:" >&5 2060 sed 's/^/| /' conftest.$ac_ext >&5 2061 2062 ac_retval=1 2063 fi 2064 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2065 as_fn_set_status $ac_retval 2066 2067 } # ac_fn_c_try_cpp 2068 2069 # ac_fn_cxx_try_cpp LINENO 2070 # ------------------------ 2071 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2072 ac_fn_cxx_try_cpp () 2073 { 2074 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2075 if { { ac_try="$ac_cpp conftest.$ac_ext" 2076 case "(($ac_try" in 2077 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2078 *) ac_try_echo=$ac_try;; 2079 esac 2080 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2081 $as_echo "$ac_try_echo"; } >&5 2082 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2083 ac_status=$? 2084 if test -s conftest.err; then 2085 grep -v '^ *+' conftest.err >conftest.er1 2086 cat conftest.er1 >&5 2087 mv -f conftest.er1 conftest.err 2088 fi 2089 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2090 test $ac_status = 0; } > conftest.i && { 2091 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || 2092 test ! -s conftest.err 2093 }; then : 2094 ac_retval=0 2095 else 2096 $as_echo "$as_me: failed program was:" >&5 2097 sed 's/^/| /' conftest.$ac_ext >&5 2098 2099 ac_retval=1 2100 fi 2101 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2102 as_fn_set_status $ac_retval 2103 2104 } # ac_fn_cxx_try_cpp 2105 2106 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES 2107 # --------------------------------------------------------- 2108 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 2109 # the include files in INCLUDES and setting the cache variable VAR 2110 # accordingly. 2111 ac_fn_cxx_check_header_mongrel () 2112 { 2113 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2114 if eval \${$3+:} false; then : 2115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2116 $as_echo_n "checking for $2... " >&6; } 2117 if eval \${$3+:} false; then : 2118 $as_echo_n "(cached) " >&6 2119 fi 2120 eval ac_res=\$$3 2121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2122 $as_echo "$ac_res" >&6; } 2123 else 2124 # Is the header compilable? 2125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 2126 $as_echo_n "checking $2 usability... " >&6; } 2127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2128 /* end confdefs.h. */ 2129 $4 2130 #include <$2> 2131 _ACEOF 2132 if ac_fn_cxx_try_compile "$LINENO"; then : 2133 ac_header_compiler=yes 2134 else 2135 ac_header_compiler=no 2136 fi 2137 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 2139 $as_echo "$ac_header_compiler" >&6; } 2140 2141 # Is the header present? 2142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 2143 $as_echo_n "checking $2 presence... " >&6; } 2144 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2145 /* end confdefs.h. */ 2146 #include <$2> 2147 _ACEOF 2148 if ac_fn_cxx_try_cpp "$LINENO"; then : 2149 ac_header_preproc=yes 2150 else 2151 ac_header_preproc=no 2152 fi 2153 rm -f conftest.err conftest.i conftest.$ac_ext 2154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 2155 $as_echo "$ac_header_preproc" >&6; } 2156 2157 # So? What about this header? 2158 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( 2159 yes:no: ) 2160 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 2161 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} 2162 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2163 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2164 ;; 2165 no:yes:* ) 2166 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 2167 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 2168 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 2169 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 2170 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 2171 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 2172 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 2173 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 2174 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2175 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2176 ( $as_echo "## ----------------------------------------- ## 2177 ## Report this to build-dev@openjdk.java.net ## 2178 ## ----------------------------------------- ##" 2179 ) | sed "s/^/$as_me: WARNING: /" >&2 2180 ;; 2181 esac 2182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2183 $as_echo_n "checking for $2... " >&6; } 2184 if eval \${$3+:} false; then : 2185 $as_echo_n "(cached) " >&6 2186 else 2187 eval "$3=\$ac_header_compiler" 2188 fi 2189 eval ac_res=\$$3 2190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2191 $as_echo "$ac_res" >&6; } 2192 fi 2193 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2194 2195 } # ac_fn_cxx_check_header_mongrel 2196 2197 # ac_fn_cxx_try_run LINENO 2198 # ------------------------ 2199 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 2200 # that executables *can* be run. 2201 ac_fn_cxx_try_run () 2202 { 2203 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2204 if { { ac_try="$ac_link" 2205 case "(($ac_try" in 2206 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2207 *) ac_try_echo=$ac_try;; 2208 esac 2209 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2210 $as_echo "$ac_try_echo"; } >&5 2211 (eval "$ac_link") 2>&5 2212 ac_status=$? 2213 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2214 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 2215 { { case "(($ac_try" in 2216 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2217 *) ac_try_echo=$ac_try;; 2218 esac 2219 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2220 $as_echo "$ac_try_echo"; } >&5 2221 (eval "$ac_try") 2>&5 2222 ac_status=$? 2223 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2224 test $ac_status = 0; }; }; then : 2225 ac_retval=0 2226 else 2227 $as_echo "$as_me: program exited with status $ac_status" >&5 2228 $as_echo "$as_me: failed program was:" >&5 2229 sed 's/^/| /' conftest.$ac_ext >&5 2230 2231 ac_retval=$ac_status 2232 fi 2233 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2234 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2235 as_fn_set_status $ac_retval 2236 2237 } # ac_fn_cxx_try_run 2238 2239 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES 2240 # --------------------------------------------------------- 2241 # Tests whether HEADER exists and can be compiled using the include files in 2242 # INCLUDES, setting the cache variable VAR accordingly. 2243 ac_fn_cxx_check_header_compile () 2244 { 2245 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2247 $as_echo_n "checking for $2... " >&6; } 2248 if eval \${$3+:} false; then : 2249 $as_echo_n "(cached) " >&6 2250 else 2251 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2252 /* end confdefs.h. */ 2253 $4 2254 #include <$2> 2255 _ACEOF 2256 if ac_fn_cxx_try_compile "$LINENO"; then : 2257 eval "$3=yes" 2258 else 2259 eval "$3=no" 2260 fi 2261 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2262 fi 2263 eval ac_res=\$$3 2264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2265 $as_echo "$ac_res" >&6; } 2266 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2267 2268 } # ac_fn_cxx_check_header_compile 2269 2270 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES 2271 # ---------------------------------------------- 2272 # Tries to find the compile-time value of EXPR in a program that includes 2273 # INCLUDES, setting VAR accordingly. Returns whether the value could be 2274 # computed 2275 ac_fn_cxx_compute_int () 2276 { 2277 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2278 if test "$cross_compiling" = yes; then 2279 # Depending upon the size, compute the lo and hi bounds. 2280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2281 /* end confdefs.h. */ 2282 $4 2283 int 2284 main () 2285 { 2286 static int test_array [1 - 2 * !(($2) >= 0)]; 2287 test_array [0] = 0 2288 2289 ; 2290 return 0; 2291 } 2292 _ACEOF 2293 if ac_fn_cxx_try_compile "$LINENO"; then : 2294 ac_lo=0 ac_mid=0 2295 while :; do 2296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2297 /* end confdefs.h. */ 2298 $4 2299 int 2300 main () 2301 { 2302 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2303 test_array [0] = 0 2304 2305 ; 2306 return 0; 2307 } 2308 _ACEOF 2309 if ac_fn_cxx_try_compile "$LINENO"; then : 2310 ac_hi=$ac_mid; break 2311 else 2312 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2313 if test $ac_lo -le $ac_mid; then 2314 ac_lo= ac_hi= 2315 break 2316 fi 2317 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2318 fi 2319 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2320 done 2321 else 2322 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2323 /* end confdefs.h. */ 2324 $4 2325 int 2326 main () 2327 { 2328 static int test_array [1 - 2 * !(($2) < 0)]; 2329 test_array [0] = 0 2330 2331 ; 2332 return 0; 2333 } 2334 _ACEOF 2335 if ac_fn_cxx_try_compile "$LINENO"; then : 2336 ac_hi=-1 ac_mid=-1 2337 while :; do 2338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2339 /* end confdefs.h. */ 2340 $4 2341 int 2342 main () 2343 { 2344 static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2345 test_array [0] = 0 2346 2347 ; 2348 return 0; 2349 } 2350 _ACEOF 2351 if ac_fn_cxx_try_compile "$LINENO"; then : 2352 ac_lo=$ac_mid; break 2353 else 2354 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2355 if test $ac_mid -le $ac_hi; then 2356 ac_lo= ac_hi= 2357 break 2358 fi 2359 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2360 fi 2361 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2362 done 2363 else 2364 ac_lo= ac_hi= 2365 fi 2366 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2367 fi 2368 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2369 # Binary search between lo and hi bounds. 2370 while test "x$ac_lo" != "x$ac_hi"; do 2371 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2372 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2373 /* end confdefs.h. */ 2374 $4 2375 int 2376 main () 2377 { 2378 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2379 test_array [0] = 0 2380 2381 ; 2382 return 0; 2383 } 2384 _ACEOF 2385 if ac_fn_cxx_try_compile "$LINENO"; then : 2386 ac_hi=$ac_mid 2387 else 2388 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2389 fi 2390 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2391 done 2392 case $ac_lo in #(( 2393 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2394 '') ac_retval=1 ;; 2395 esac 2396 else 2397 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2398 /* end confdefs.h. */ 2399 $4 2400 static long int longval () { return $2; } 2401 static unsigned long int ulongval () { return $2; } 2402 #include <stdio.h> 2403 #include <stdlib.h> 2404 int 2405 main () 2406 { 2407 2408 FILE *f = fopen ("conftest.val", "w"); 2409 if (! f) 2410 return 1; 2411 if (($2) < 0) 2412 { 2413 long int i = longval (); 2414 if (i != ($2)) 2415 return 1; 2416 fprintf (f, "%ld", i); 2417 } 2418 else 2419 { 2420 unsigned long int i = ulongval (); 2421 if (i != ($2)) 2422 return 1; 2423 fprintf (f, "%lu", i); 2424 } 2425 /* Do not output a trailing newline, as this causes \r\n confusion 2426 on some platforms. */ 2427 return ferror (f) || fclose (f) != 0; 2428 2429 ; 2430 return 0; 2431 } 2432 _ACEOF 2433 if ac_fn_cxx_try_run "$LINENO"; then : 2434 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2435 else 2436 ac_retval=1 2437 fi 2438 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2439 conftest.$ac_objext conftest.beam conftest.$ac_ext 2440 rm -f conftest.val 2441 2442 fi 2443 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2444 as_fn_set_status $ac_retval 2445 2446 } # ac_fn_cxx_compute_int 2447 2448 # ac_fn_cxx_try_link LINENO 2449 # ------------------------- 2450 # Try to link conftest.$ac_ext, and return whether this succeeded. 2451 ac_fn_cxx_try_link () 2452 { 2453 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2454 rm -f conftest.$ac_objext conftest$ac_exeext 2455 if { { ac_try="$ac_link" 2456 case "(($ac_try" in 2457 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2458 *) ac_try_echo=$ac_try;; 2459 esac 2460 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2461 $as_echo "$ac_try_echo"; } >&5 2462 (eval "$ac_link") 2>conftest.err 2463 ac_status=$? 2464 if test -s conftest.err; then 2465 grep -v '^ *+' conftest.err >conftest.er1 2466 cat conftest.er1 >&5 2467 mv -f conftest.er1 conftest.err 2468 fi 2469 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2470 test $ac_status = 0; } && { 2471 test -z "$ac_cxx_werror_flag" || 2472 test ! -s conftest.err 2473 } && test -s conftest$ac_exeext && { 2474 test "$cross_compiling" = yes || 2475 $as_test_x conftest$ac_exeext 2476 }; then : 2477 ac_retval=0 2478 else 2479 $as_echo "$as_me: failed program was:" >&5 2480 sed 's/^/| /' conftest.$ac_ext >&5 2481 2482 ac_retval=1 2483 fi 2484 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2485 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2486 # interfere with the next link command; also delete a directory that is 2487 # left behind by Apple's compiler. We do this before executing the actions. 2488 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2489 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2490 as_fn_set_status $ac_retval 2491 2492 } # ac_fn_cxx_try_link 2493 2494 # ac_fn_cxx_check_func LINENO FUNC VAR 2495 # ------------------------------------ 2496 # Tests whether FUNC exists, setting the cache variable VAR accordingly 2497 ac_fn_cxx_check_func () 2498 { 2499 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2501 $as_echo_n "checking for $2... " >&6; } 2502 if eval \${$3+:} false; then : 2503 $as_echo_n "(cached) " >&6 2504 else 2505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2506 /* end confdefs.h. */ 2507 /* Define $2 to an innocuous variant, in case <limits.h> declares $2. 2508 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 2509 #define $2 innocuous_$2 2510 2511 /* System header to define __stub macros and hopefully few prototypes, 2512 which can conflict with char $2 (); below. 2513 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 2514 <limits.h> exists even on freestanding compilers. */ 2515 2516 #ifdef __STDC__ 2517 # include <limits.h> 2518 #else 2519 # include <assert.h> 2520 #endif 2521 2522 #undef $2 2523 2524 /* Override any GCC internal prototype to avoid an error. 2525 Use char because int might match the return type of a GCC 2526 builtin and then its argument prototype would still apply. */ 2527 #ifdef __cplusplus 2528 extern "C" 2529 #endif 2530 char $2 (); 2531 /* The GNU C library defines this for functions which it implements 2532 to always fail with ENOSYS. Some functions are actually named 2533 something starting with __ and the normal name is an alias. */ 2534 #if defined __stub_$2 || defined __stub___$2 2535 choke me 2536 #endif 2537 2538 int 2539 main () 2540 { 2541 return $2 (); 2542 ; 2543 return 0; 2544 } 2545 _ACEOF 2546 if ac_fn_cxx_try_link "$LINENO"; then : 2547 eval "$3=yes" 2548 else 2549 eval "$3=no" 2550 fi 2551 rm -f core conftest.err conftest.$ac_objext \ 2552 conftest$ac_exeext conftest.$ac_ext 2553 fi 2554 eval ac_res=\$$3 2555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2556 $as_echo "$ac_res" >&6; } 2557 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2558 2559 } # ac_fn_cxx_check_func 2560 2561 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 2562 # ------------------------------------------------------- 2563 # Tests whether HEADER exists and can be compiled using the include files in 2564 # INCLUDES, setting the cache variable VAR accordingly. 2565 ac_fn_c_check_header_compile () 2566 { 2567 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2569 $as_echo_n "checking for $2... " >&6; } 2570 if eval \${$3+:} false; then : 2571 $as_echo_n "(cached) " >&6 2572 else 2573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2574 /* end confdefs.h. */ 2575 $4 2576 #include <$2> 2577 _ACEOF 2578 if ac_fn_c_try_compile "$LINENO"; then : 2579 eval "$3=yes" 2580 else 2581 eval "$3=no" 2582 fi 2583 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2584 fi 2585 eval ac_res=\$$3 2586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2587 $as_echo "$ac_res" >&6; } 2588 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2589 2590 } # ac_fn_c_check_header_compile 2591 cat >config.log <<_ACEOF 2592 This file contains any messages produced by compilers while 2593 running configure, to aid debugging if configure makes a mistake. 2594 2595 It was created by OpenJDK $as_me jdk8, which was 2596 generated by GNU Autoconf 2.68. Invocation command line was 2597 2598 $ $0 $@ 2599 2600 _ACEOF 2601 exec 5>>config.log 2602 { 2603 cat <<_ASUNAME 2604 ## --------- ## 2605 ## Platform. ## 2606 ## --------- ## 2607 2608 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 2609 uname -m = `(uname -m) 2>/dev/null || echo unknown` 2610 uname -r = `(uname -r) 2>/dev/null || echo unknown` 2611 uname -s = `(uname -s) 2>/dev/null || echo unknown` 2612 uname -v = `(uname -v) 2>/dev/null || echo unknown` 2613 2614 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 2615 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 2616 2617 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 2618 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 2619 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 2620 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 2621 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 2622 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 2623 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 2624 2625 _ASUNAME 2626 2627 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2628 for as_dir in $PATH 2629 do 2630 IFS=$as_save_IFS 2631 test -z "$as_dir" && as_dir=. 2632 $as_echo "PATH: $as_dir" 2633 done 2634 IFS=$as_save_IFS 2635 2636 } >&5 2637 2638 cat >&5 <<_ACEOF 2639 2640 2641 ## ----------- ## 2642 ## Core tests. ## 2643 ## ----------- ## 2644 2645 _ACEOF 2646 2647 2648 # Keep a trace of the command line. 2649 # Strip out --no-create and --no-recursion so they do not pile up. 2650 # Strip out --silent because we don't want to record it for future runs. 2651 # Also quote any args containing shell meta-characters. 2652 # Make two passes to allow for proper duplicate-argument suppression. 2653 ac_configure_args= 2654 ac_configure_args0= 2655 ac_configure_args1= 2656 ac_must_keep_next=false 2657 for ac_pass in 1 2 2658 do 2659 for ac_arg 2660 do 2661 case $ac_arg in 2662 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 2663 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 2664 | -silent | --silent | --silen | --sile | --sil) 2665 continue ;; 2666 *\'*) 2667 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 2668 esac 2669 case $ac_pass in 2670 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2671 2) 2672 as_fn_append ac_configure_args1 " '$ac_arg'" 2673 if test $ac_must_keep_next = true; then 2674 ac_must_keep_next=false # Got value, back to normal. 2675 else 2676 case $ac_arg in 2677 *=* | --config-cache | -C | -disable-* | --disable-* \ 2678 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 2679 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 2680 | -with-* | --with-* | -without-* | --without-* | --x) 2681 case "$ac_configure_args0 " in 2682 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 2683 esac 2684 ;; 2685 -* ) ac_must_keep_next=true ;; 2686 esac 2687 fi 2688 as_fn_append ac_configure_args " '$ac_arg'" 2689 ;; 2690 esac 2691 done 2692 done 2693 { ac_configure_args0=; unset ac_configure_args0;} 2694 { ac_configure_args1=; unset ac_configure_args1;} 2695 2696 # When interrupted or exit'd, cleanup temporary files, and complete 2697 # config.log. We remove comments because anyway the quotes in there 2698 # would cause problems or look ugly. 2699 # WARNING: Use '\'' to represent an apostrophe within the trap. 2700 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 2701 trap 'exit_status=$? 2702 # Save into config.log some information that might help in debugging. 2703 { 2704 echo 2705 2706 $as_echo "## ---------------- ## 2707 ## Cache variables. ## 2708 ## ---------------- ##" 2709 echo 2710 # The following way of writing the cache mishandles newlines in values, 2711 ( 2712 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 2713 eval ac_val=\$$ac_var 2714 case $ac_val in #( 2715 *${as_nl}*) 2716 case $ac_var in #( 2717 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 2718 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 2719 esac 2720 case $ac_var in #( 2721 _ | IFS | as_nl) ;; #( 2722 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 2723 *) { eval $ac_var=; unset $ac_var;} ;; 2724 esac ;; 2725 esac 2726 done 2727 (set) 2>&1 | 2728 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 2729 *${as_nl}ac_space=\ *) 2730 sed -n \ 2731 "s/'\''/'\''\\\\'\'''\''/g; 2732 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 2733 ;; #( 2734 *) 2735 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 2736 ;; 2737 esac | 2738 sort 2739 ) 2740 echo 2741 2742 $as_echo "## ----------------- ## 2743 ## Output variables. ## 2744 ## ----------------- ##" 2745 echo 2746 for ac_var in $ac_subst_vars 2747 do 2748 eval ac_val=\$$ac_var 2749 case $ac_val in 2750 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 2751 esac 2752 $as_echo "$ac_var='\''$ac_val'\''" 2753 done | sort 2754 echo 2755 2756 if test -n "$ac_subst_files"; then 2757 $as_echo "## ------------------- ## 2758 ## File substitutions. ## 2759 ## ------------------- ##" 2760 echo 2761 for ac_var in $ac_subst_files 2762 do 2763 eval ac_val=\$$ac_var 2764 case $ac_val in 2765 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 2766 esac 2767 $as_echo "$ac_var='\''$ac_val'\''" 2768 done | sort 2769 echo 2770 fi 2771 2772 if test -s confdefs.h; then 2773 $as_echo "## ----------- ## 2774 ## confdefs.h. ## 2775 ## ----------- ##" 2776 echo 2777 cat confdefs.h 2778 echo 2779 fi 2780 test "$ac_signal" != 0 && 2781 $as_echo "$as_me: caught signal $ac_signal" 2782 $as_echo "$as_me: exit $exit_status" 2783 } >&5 2784 rm -f core *.core core.conftest.* && 2785 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 2786 exit $exit_status 2787 ' 0 2788 for ac_signal in 1 2 13 15; do 2789 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 2790 done 2791 ac_signal=0 2792 2793 # confdefs.h avoids OS command line length limits that DEFS can exceed. 2794 rm -f -r conftest* confdefs.h 2795 2796 $as_echo "/* confdefs.h */" > confdefs.h 2797 2798 # Predefined preprocessor variables. 2799 2800 cat >>confdefs.h <<_ACEOF 2801 #define PACKAGE_NAME "$PACKAGE_NAME" 2802 _ACEOF 2803 2804 cat >>confdefs.h <<_ACEOF 2805 #define PACKAGE_TARNAME "$PACKAGE_TARNAME" 2806 _ACEOF 2807 2808 cat >>confdefs.h <<_ACEOF 2809 #define PACKAGE_VERSION "$PACKAGE_VERSION" 2810 _ACEOF 2811 2812 cat >>confdefs.h <<_ACEOF 2813 #define PACKAGE_STRING "$PACKAGE_STRING" 2814 _ACEOF 2815 2816 cat >>confdefs.h <<_ACEOF 2817 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" 2818 _ACEOF 2819 2820 cat >>confdefs.h <<_ACEOF 2821 #define PACKAGE_URL "$PACKAGE_URL" 2822 _ACEOF 2823 2824 2825 # Let the site file select an alternate cache file if it wants to. 2826 # Prefer an explicitly selected file to automatically selected ones. 2827 ac_site_file1=NONE 2828 ac_site_file2=NONE 2829 if test -n "$CONFIG_SITE"; then 2830 # We do not want a PATH search for config.site. 2831 case $CONFIG_SITE in #(( 2832 -*) ac_site_file1=./$CONFIG_SITE;; 2833 */*) ac_site_file1=$CONFIG_SITE;; 2834 *) ac_site_file1=./$CONFIG_SITE;; 2835 esac 2836 elif test "x$prefix" != xNONE; then 2837 ac_site_file1=$prefix/share/config.site 2838 ac_site_file2=$prefix/etc/config.site 2839 else 2840 ac_site_file1=$ac_default_prefix/share/config.site 2841 ac_site_file2=$ac_default_prefix/etc/config.site 2842 fi 2843 for ac_site_file in "$ac_site_file1" "$ac_site_file2" 2844 do 2845 test "x$ac_site_file" = xNONE && continue 2846 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then 2847 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 2848 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 2849 sed 's/^/| /' "$ac_site_file" >&5 2850 . "$ac_site_file" \ 2851 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 2852 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 2853 as_fn_error $? "failed to load site script $ac_site_file 2854 See \`config.log' for more details" "$LINENO" 5; } 2855 fi 2856 done 2857 2858 if test -r "$cache_file"; then 2859 # Some versions of bash will fail to source /dev/null (special files 2860 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 2861 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 2862 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 2863 $as_echo "$as_me: loading cache $cache_file" >&6;} 2864 case $cache_file in 2865 [\\/]* | ?:[\\/]* ) . "$cache_file";; 2866 *) . "./$cache_file";; 2867 esac 2868 fi 2869 else 2870 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 2871 $as_echo "$as_me: creating cache $cache_file" >&6;} 2872 >$cache_file 2873 fi 2874 2875 # Check that the precious variables saved in the cache have kept the same 2876 # value. 2877 ac_cache_corrupted=false 2878 for ac_var in $ac_precious_vars; do 2879 eval ac_old_set=\$ac_cv_env_${ac_var}_set 2880 eval ac_new_set=\$ac_env_${ac_var}_set 2881 eval ac_old_val=\$ac_cv_env_${ac_var}_value 2882 eval ac_new_val=\$ac_env_${ac_var}_value 2883 case $ac_old_set,$ac_new_set in 2884 set,) 2885 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 2886 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 2887 ac_cache_corrupted=: ;; 2888 ,set) 2889 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 2890 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 2891 ac_cache_corrupted=: ;; 2892 ,);; 2893 *) 2894 if test "x$ac_old_val" != "x$ac_new_val"; then 2895 # differences in whitespace do not lead to failure. 2896 ac_old_val_w=`echo x $ac_old_val` 2897 ac_new_val_w=`echo x $ac_new_val` 2898 if test "$ac_old_val_w" != "$ac_new_val_w"; then 2899 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 2900 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 2901 ac_cache_corrupted=: 2902 else 2903 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 2904 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 2905 eval $ac_var=\$ac_old_val 2906 fi 2907 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 2908 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} 2909 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 2910 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} 2911 fi;; 2912 esac 2913 # Pass precious variables to config.status. 2914 if test "$ac_new_set" = set; then 2915 case $ac_new_val in 2916 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 2917 *) ac_arg=$ac_var=$ac_new_val ;; 2918 esac 2919 case " $ac_configure_args " in 2920 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 2921 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 2922 esac 2923 fi 2924 done 2925 if $ac_cache_corrupted; then 2926 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 2927 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 2928 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 2929 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 2930 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 2931 fi 2932 ## -------------------- ## 2933 ## Main body of script. ## 2934 ## -------------------- ## 2935 2936 ac_ext=c 2937 ac_cpp='$CPP $CPPFLAGS' 2938 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 2939 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 2940 ac_compiler_gnu=$ac_cv_c_compiler_gnu 2941 2942 2943 2944 ac_aux_dir= 2945 for ac_dir in build-aux "$srcdir"/build-aux; do 2946 if test -f "$ac_dir/install-sh"; then 2947 ac_aux_dir=$ac_dir 2948 ac_install_sh="$ac_aux_dir/install-sh -c" 2949 break 2950 elif 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/shtool"; then 2955 ac_aux_dir=$ac_dir 2956 ac_install_sh="$ac_aux_dir/shtool install -c" 2957 break 2958 fi 2959 done 2960 if test -z "$ac_aux_dir"; then 2961 as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5 2962 fi 2963 2964 # These three variables are undocumented and unsupported, 2965 # and are intended to be withdrawn in a future Autoconf release. 2966 # They can cause serious problems if a builder's source tree is in a directory 2967 # whose full name contains unusual characters. 2968 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. 2969 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. 2970 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. 2971 2972 2973 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 2974 2975 # 2976 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. 2977 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 2978 # 2979 # This code is free software; you can redistribute it and/or modify it 2980 # under the terms of the GNU General Public License version 2 only, as 2981 # published by the Free Software Foundation. Oracle designates this 2982 # particular file as subject to the "Classpath" exception as provided 2983 # by Oracle in the LICENSE file that accompanied this code. 2984 # 2985 # This code is distributed in the hope that it will be useful, but WITHOUT 2986 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 2987 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 2988 # version 2 for more details (a copy is included in the LICENSE file that 2989 # accompanied this code). 2990 # 2991 # You should have received a copy of the GNU General Public License version 2992 # 2 along with this work; if not, write to the Free Software Foundation, 2993 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 2994 # 2995 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 2996 # or visit www.oracle.com if you need additional information or have any 2997 # questions. 2998 # 2999 3000 # 3001 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 3002 # 3003 # This program is free software; you can redistribute it and/or modify 3004 # it under the terms of the GNU General Public License as published by 3005 # the Free Software Foundation; either version 2 of the License, or 3006 # (at your option) any later version. 3007 # 3008 # This program is distributed in the hope that it will be useful, but 3009 # WITHOUT ANY WARRANTY; without even the implied warranty of 3010 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 3011 # General Public License for more details. 3012 # 3013 # You should have received a copy of the GNU General Public License 3014 # along with this program; if not, write to the Free Software 3015 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 3016 # 3017 # As a special exception to the GNU General Public License, if you 3018 # distribute this file as part of a program that contains a 3019 # configuration script generated by Autoconf, you may include it under 3020 # the same distribution terms that you use for the rest of that program. 3021 3022 # PKG_PROG_PKG_CONFIG([MIN-VERSION]) 3023 # ---------------------------------- 3024 # PKG_PROG_PKG_CONFIG 3025 3026 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 3027 # 3028 # Check to see whether a particular set of modules exists. Similar 3029 # to PKG_CHECK_MODULES(), but does not set variables or print errors. 3030 # 3031 # 3032 # Similar to PKG_CHECK_MODULES, make sure that the first instance of 3033 # this or PKG_CHECK_MODULES is called, or make sure to call 3034 # PKG_CHECK_EXISTS manually 3035 # -------------------------------------------------------------- 3036 3037 3038 3039 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 3040 # --------------------------------------------- 3041 # _PKG_CONFIG 3042 3043 # _PKG_SHORT_ERRORS_SUPPORTED 3044 # ----------------------------- 3045 # _PKG_SHORT_ERRORS_SUPPORTED 3046 3047 3048 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 3049 # [ACTION-IF-NOT-FOUND]) 3050 # 3051 # 3052 # Note that if there is a possibility the first call to 3053 # PKG_CHECK_MODULES might not happen, you should be sure to include an 3054 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 3055 # 3056 # 3057 # -------------------------------------------------------------- 3058 # PKG_CHECK_MODULES 3059 3060 3061 # Include these first... 3062 # 3063 # Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved. 3064 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3065 # 3066 # This code is free software; you can redistribute it and/or modify it 3067 # under the terms of the GNU General Public License version 2 only, as 3068 # published by the Free Software Foundation. Oracle designates this 3069 # particular file as subject to the "Classpath" exception as provided 3070 # by Oracle in the LICENSE file that accompanied this code. 3071 # 3072 # This code is distributed in the hope that it will be useful, but WITHOUT 3073 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3074 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3075 # version 2 for more details (a copy is included in the LICENSE file that 3076 # accompanied this code). 3077 # 3078 # You should have received a copy of the GNU General Public License version 3079 # 2 along with this work; if not, write to the Free Software Foundation, 3080 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3081 # 3082 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3083 # or visit www.oracle.com if you need additional information or have any 3084 # questions. 3085 # 3086 3087 3088 3089 # This will make sure the given variable points to a full and proper 3090 # path. This means: 3091 # 1) There will be no spaces in the path. On posix platforms, 3092 # spaces in the path will result in an error. On Windows, 3093 # the path will be rewritten using short-style to be space-free. 3094 # 2) The path will be absolute, and it will be in unix-style (on 3095 # cygwin). 3096 # $1: The name of the variable to fix 3097 3098 3099 # This will make sure the given variable points to a executable 3100 # with a full and proper 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 # Any arguments given to the executable is preserved. 3107 # If the input variable does not have a directory specification, then 3108 # it need to be in the PATH. 3109 # $1: The name of the variable to fix 3110 3111 3112 3113 3114 3115 3116 # Test that variable $1 denoting a program is not empty. If empty, exit with an error. 3117 # $1: variable to check 3118 # $2: executable name to print in warning (optional) 3119 3120 3121 # Does AC_PATH_PROG followed by BASIC_CHECK_NONEMPTY. 3122 # Arguments as AC_PATH_PROG: 3123 # $1: variable to set 3124 # $2: executable name to look for 3125 3126 3127 # Setup the most fundamental tools that relies on not much else to set up, 3128 # but is used by much of the early bootstrap code. 3129 3130 3131 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3132 3133 3134 3135 3136 3137 3138 3139 #%%% Simple tools %%% 3140 3141 # Check if we have found a usable version of make 3142 # $1: the path to a potential make binary (or empty) 3143 # $2: the description on how we found this 3144 3145 3146 # Goes looking for a usable version of GNU make. 3147 3148 3149 3150 3151 3152 3153 # Check if build directory is on local disk. If not possible to determine, 3154 # we prefer to claim it's local. 3155 # Argument 1: directory to test 3156 # Argument 2: what to do if it is on local disk 3157 # Argument 3: what to do otherwise (remote disk or failure) 3158 3159 3160 # Check that source files have basic read permissions set. This might 3161 # not be the case in cygwin in certain conditions. 3162 3163 3164 3165 3166 # 3167 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3168 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3169 # 3170 # This code is free software; you can redistribute it and/or modify it 3171 # under the terms of the GNU General Public License version 2 only, as 3172 # published by the Free Software Foundation. Oracle designates this 3173 # particular file as subject to the "Classpath" exception as provided 3174 # by Oracle in the LICENSE file that accompanied this code. 3175 # 3176 # This code is distributed in the hope that it will be useful, but WITHOUT 3177 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3178 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3179 # version 2 for more details (a copy is included in the LICENSE file that 3180 # accompanied this code). 3181 # 3182 # You should have received a copy of the GNU General Public License version 3183 # 2 along with this work; if not, write to the Free Software Foundation, 3184 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3185 # 3186 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3187 # or visit www.oracle.com if you need additional information or have any 3188 # questions. 3189 # 3190 3191 3192 3193 3194 3195 # Helper function which possibly converts a path using DOS-style short mode. 3196 # If so, the updated path is stored in $new_path. 3197 # $1: The path to check 3198 3199 3200 # Helper function which possibly converts a path using DOS-style short mode. 3201 # If so, the updated path is stored in $new_path. 3202 # $1: The path to check 3203 3204 3205 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted 3206 # and could probably be heavily simplified. However, all changes in this 3207 # area tend to need lot of testing in different scenarios, and in lack of 3208 # proper unit testing, cleaning this up has not been deemed worth the effort 3209 # at the moment. 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3220 3221 3222 3223 3224 # 3225 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3226 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3227 # 3228 # This code is free software; you can redistribute it and/or modify it 3229 # under the terms of the GNU General Public License version 2 only, as 3230 # published by the Free Software Foundation. Oracle designates this 3231 # particular file as subject to the "Classpath" exception as provided 3232 # by Oracle in the LICENSE file that accompanied this code. 3233 # 3234 # This code is distributed in the hope that it will be useful, but WITHOUT 3235 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3236 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3237 # version 2 for more details (a copy is included in the LICENSE file that 3238 # accompanied this code). 3239 # 3240 # You should have received a copy of the GNU General Public License version 3241 # 2 along with this work; if not, write to the Free Software Foundation, 3242 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3243 # 3244 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3245 # or visit www.oracle.com if you need additional information or have any 3246 # questions. 3247 # 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 # ... then the rest 3260 # 3261 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3262 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3263 # 3264 # This code is free software; you can redistribute it and/or modify it 3265 # under the terms of the GNU General Public License version 2 only, as 3266 # published by the Free Software Foundation. Oracle designates this 3267 # particular file as subject to the "Classpath" exception as provided 3268 # by Oracle in the LICENSE file that accompanied this code. 3269 # 3270 # This code is distributed in the hope that it will be useful, but WITHOUT 3271 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3272 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3273 # version 2 for more details (a copy is included in the LICENSE file that 3274 # accompanied this code). 3275 # 3276 # You should have received a copy of the GNU General Public License version 3277 # 2 along with this work; if not, write to the Free Software Foundation, 3278 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3279 # 3280 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3281 # or visit www.oracle.com if you need additional information or have any 3282 # questions. 3283 # 3284 3285 # Execute the check given as argument, and verify the result 3286 # If the Boot JDK was previously found, do nothing 3287 # $1 A command line (typically autoconf macro) to execute 3288 3289 3290 # Test: Is bootjdk explicitely set by command line arguments? 3291 3292 3293 # Test: Is bootjdk available from builddeps? 3294 3295 3296 # Test: Is $JAVA_HOME set? 3297 3298 3299 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 3300 3301 3302 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 3303 3304 3305 # Look for a jdk in the given path. If there are multiple, try to select the newest. 3306 # If found, set BOOT_JDK and BOOT_JDK_FOUND. 3307 # $1 = Path to directory containing jdk installations. 3308 # $2 = String to append to the found JDK directory to get the proper JDK home 3309 3310 3311 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given 3312 # environmental variable as base for where to look. 3313 # $1 Name of an environmal variable, assumed to point to the Program Files directory. 3314 3315 3316 # Test: Is there a JDK installed in default, well-known locations? 3317 3318 3319 # Check that a command-line tool in the Boot JDK is correct 3320 # $1 = name of variable to assign 3321 # $2 = name of binary 3322 3323 3324 ############################################################################### 3325 # 3326 # We need a Boot JDK to bootstrap the build. 3327 # 3328 3329 3330 3331 3332 3333 # 3334 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3335 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3336 # 3337 # This code is free software; you can redistribute it and/or modify it 3338 # under the terms of the GNU General Public License version 2 only, as 3339 # published by the Free Software Foundation. Oracle designates this 3340 # particular file as subject to the "Classpath" exception as provided 3341 # by Oracle in the LICENSE file that accompanied this code. 3342 # 3343 # This code is distributed in the hope that it will be useful, but WITHOUT 3344 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3345 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3346 # version 2 for more details (a copy is included in the LICENSE file that 3347 # accompanied this code). 3348 # 3349 # You should have received a copy of the GNU General Public License version 3350 # 2 along with this work; if not, write to the Free Software Foundation, 3351 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3352 # 3353 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3354 # or visit www.oracle.com if you need additional information or have any 3355 # questions. 3356 # 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 # 3378 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3379 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3380 # 3381 # This code is free software; you can redistribute it and/or modify it 3382 # under the terms of the GNU General Public License version 2 only, as 3383 # published by the Free Software Foundation. Oracle designates this 3384 # particular file as subject to the "Classpath" exception as provided 3385 # by Oracle in the LICENSE file that accompanied this code. 3386 # 3387 # This code is distributed in the hope that it will be useful, but WITHOUT 3388 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3389 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3390 # version 2 for more details (a copy is included in the LICENSE file that 3391 # accompanied this code). 3392 # 3393 # You should have received a copy of the GNU General Public License version 3394 # 2 along with this work; if not, write to the Free Software Foundation, 3395 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3396 # 3397 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3398 # or visit www.oracle.com if you need additional information or have any 3399 # questions. 3400 # 3401 3402 3403 3404 3405 3406 cygwin_help() { 3407 case $1 in 3408 unzip) 3409 PKGHANDLER_COMMAND="cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip" ;; 3410 zip) 3411 PKGHANDLER_COMMAND="cd <location of cygwin setup.exe> && cmd /c setup -q -P zip" ;; 3412 make) 3413 PKGHANDLER_COMMAND="cd <location of cygwin setup.exe> && cmd /c setup -q -P make" ;; 3414 * ) 3415 break ;; 3416 esac 3417 } 3418 3419 apt_help() { 3420 case $1 in 3421 devkit) 3422 PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;; 3423 openjdk) 3424 PKGHANDLER_COMMAND="sudo apt-get install openjdk-7-jdk" ;; 3425 alsa) 3426 PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;; 3427 cups) 3428 PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;; 3429 freetype2) 3430 PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;; 3431 pulse) 3432 PKGHANDLER_COMMAND="sudo apt-get install libpulse-dev" ;; 3433 x11) 3434 PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev" ;; 3435 ccache) 3436 PKGHANDLER_COMMAND="sudo apt-get install ccache" ;; 3437 * ) 3438 break ;; 3439 esac 3440 } 3441 3442 yum_help() { 3443 case $1 in 3444 devkit) 3445 PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;; 3446 openjdk) 3447 PKGHANDLER_COMMAND="sudo yum install java-1.7.0-openjdk" ;; 3448 alsa) 3449 PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;; 3450 cups) 3451 PKGHANDLER_COMMAND="sudo yum install cups-devel" ;; 3452 freetype2) 3453 PKGHANDLER_COMMAND="sudo yum install freetype2-devel" ;; 3454 pulse) 3455 PKGHANDLER_COMMAND="sudo yum install pulseaudio-libs-devel" ;; 3456 x11) 3457 PKGHANDLER_COMMAND="sudo yum install libXtst-devel" ;; 3458 ccache) 3459 PKGHANDLER_COMMAND="sudo yum install ccache" ;; 3460 * ) 3461 break ;; 3462 esac 3463 } 3464 3465 port_help() { 3466 PKGHANDLER_COMMAND="" 3467 } 3468 3469 pkgutil_help() { 3470 PKGHANDLER_COMMAND="" 3471 } 3472 3473 pkgadd_help() { 3474 PKGHANDLER_COMMAND="" 3475 } 3476 3477 3478 3479 # 3480 # Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved. 3481 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3482 # 3483 # This code is free software; you can redistribute it and/or modify it 3484 # under the terms of the GNU General Public License version 2 only, as 3485 # published by the Free Software Foundation. Oracle designates this 3486 # particular file as subject to the "Classpath" exception as provided 3487 # by Oracle in the LICENSE file that accompanied this code. 3488 # 3489 # This code is distributed in the hope that it will be useful, but WITHOUT 3490 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3491 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3492 # version 2 for more details (a copy is included in the LICENSE file that 3493 # accompanied this code). 3494 # 3495 # You should have received a copy of the GNU General Public License version 3496 # 2 along with this work; if not, write to the Free Software Foundation, 3497 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3498 # 3499 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3500 # or visit www.oracle.com if you need additional information or have any 3501 # questions. 3502 # 3503 3504 3505 3506 3507 3508 3509 3510 3511 ############################################################################### 3512 # 3513 # Should we build only OpenJDK even if closed sources are present? 3514 # 3515 3516 3517 3518 3519 ############################################################################### 3520 # 3521 # Setup version numbers 3522 # 3523 3524 3525 3526 3527 3528 3529 # Support for customization of the build process. Some build files 3530 # will include counterparts from this location, if they exist. This allows 3531 # for a degree of customization of the build targets and the rules/recipes 3532 # to create them 3533 3534 # Check whether --with-custom-make-dir was given. 3535 if test "${with_custom_make_dir+set}" = set; then : 3536 withval=$with_custom_make_dir; CUSTOM_MAKE_DIR=$with_custom_make_dir 3537 fi 3538 3539 3540 3541 # 3542 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3543 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3544 # 3545 # This code is free software; you can redistribute it and/or modify it 3546 # under the terms of the GNU General Public License version 2 only, as 3547 # published by the Free Software Foundation. Oracle designates this 3548 # particular file as subject to the "Classpath" exception as provided 3549 # by Oracle in the LICENSE file that accompanied this code. 3550 # 3551 # This code is distributed in the hope that it will be useful, but WITHOUT 3552 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3553 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3554 # version 2 for more details (a copy is included in the LICENSE file that 3555 # accompanied this code). 3556 # 3557 # You should have received a copy of the GNU General Public License version 3558 # 2 along with this work; if not, write to the Free Software Foundation, 3559 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3560 # 3561 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3562 # or visit www.oracle.com if you need additional information or have any 3563 # questions. 3564 # 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 # 3581 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3582 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3583 # 3584 # This code is free software; you can redistribute it and/or modify it 3585 # under the terms of the GNU General Public License version 2 only, as 3586 # published by the Free Software Foundation. Oracle designates this 3587 # particular file as subject to the "Classpath" exception as provided 3588 # by Oracle in the LICENSE file that accompanied this code. 3589 # 3590 # This code is distributed in the hope that it will be useful, but WITHOUT 3591 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3592 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3593 # version 2 for more details (a copy is included in the LICENSE file that 3594 # accompanied this code). 3595 # 3596 # You should have received a copy of the GNU General Public License version 3597 # 2 along with this work; if not, write to the Free Software Foundation, 3598 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3599 # 3600 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3601 # or visit www.oracle.com if you need additional information or have any 3602 # questions. 3603 # 3604 3605 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 3606 # Converts autoconf style CPU name to OpenJDK style, into 3607 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN. 3608 3609 3610 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 3611 # Converts autoconf style OS name to OpenJDK style, into 3612 # VAR_OS and VAR_OS_API. 3613 3614 3615 # Expects $host_os $host_cpu $build_os and $build_cpu 3616 # and $with_target_bits to have been setup! 3617 # 3618 # Translate the standard triplet(quadruplet) definition 3619 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU, 3620 # OPENJDK_BUILD_OS, etc. 3621 3622 3623 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour 3624 # accordingly. Must be done after setting up build and target system, but before 3625 # doing anything else with these values. 3626 3627 3628 # Setup the legacy variables, for controlling the old makefiles. 3629 # 3630 3631 3632 3633 3634 #%%% Build and target systems %%% 3635 3636 3637 3638 3639 # Check that the compiler supports an argument 3640 # $1: the compiler argumen to check 3641 # $2: action-if-true 3642 # $3: action-if-false 3643 3644 3645 # Check that the compiler supports -mX flags 3646 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 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 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3738 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3739 # 3740 # This code is free software; you can redistribute it and/or modify it 3741 # under the terms of the GNU General Public License version 2 only, as 3742 # published by the Free Software Foundation. Oracle designates this 3743 # particular file as subject to the "Classpath" exception as provided 3744 # by Oracle in the LICENSE file that accompanied this code. 3745 # 3746 # This code is distributed in the hope that it will be useful, but WITHOUT 3747 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3748 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3749 # version 2 for more details (a copy is included in the LICENSE file that 3750 # accompanied this code). 3751 # 3752 # You should have received a copy of the GNU General Public License version 3753 # 2 along with this work; if not, write to the Free Software Foundation, 3754 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3755 # 3756 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3757 # or visit www.oracle.com if you need additional information or have any 3758 # questions. 3759 # 3760 3761 3762 3763 3764 3765 3766 3767 # Check if the VS env variables were setup prior to running configure. 3768 # If not, then find vcvarsall.bat and run it automatically, and integrate 3769 # the set env variables into the spec file. 3770 3771 3772 3773 # Setup the DXSDK paths 3774 3775 3776 3777 3778 3779 3780 # This line needs to be here, verbatim, after all includes and the dummy hook 3781 # definitions. It is replaced with custom functionality when building 3782 # custom sources. 3783 #CUSTOM_AUTOCONF_INCLUDE 3784 3785 # Do not change or remove the following line, it is needed for consistency checks: 3786 DATE_WHEN_GENERATED=1366163151 3787 3788 ############################################################################### 3789 # 3790 # Initialization / Boot-strapping 3791 # 3792 # The bootstrapping process needs to solve the "chicken or the egg" problem, 3793 # thus it jumps back and forth, each time gaining something needed later on. 3794 # 3795 ############################################################################### 3796 3797 # Basic initialization that must happen first of all 3798 3799 # Save the original command line. This is passed to us by the wrapper configure script. 3800 3801 DATE_WHEN_CONFIGURED=`LANG=C date` 3802 3803 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5 3804 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;} 3805 { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5 3806 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;} 3807 3808 3809 3810 # Start with tools that do not need have cross compilation support 3811 # and can be expected to be found in the default PATH. These tools are 3812 # used by configure. Nor are these tools expected to be found in the 3813 # devkit from the builddeps server either, since they are 3814 # needed to download the devkit. 3815 3816 # First are all the simple required tools. 3817 3818 for ac_prog in basename 3819 do 3820 # Extract the first word of "$ac_prog", so it can be a program name with args. 3821 set dummy $ac_prog; ac_word=$2 3822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 3823 $as_echo_n "checking for $ac_word... " >&6; } 3824 if ${ac_cv_path_BASENAME+:} false; then : 3825 $as_echo_n "(cached) " >&6 3826 else 3827 case $BASENAME in 3828 [\\/]* | ?:[\\/]*) 3829 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 3830 ;; 3831 *) 3832 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3833 for as_dir in $PATH 3834 do 3835 IFS=$as_save_IFS 3836 test -z "$as_dir" && as_dir=. 3837 for ac_exec_ext in '' $ac_executable_extensions; do 3838 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 3839 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 3840 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 3841 break 2 3842 fi 3843 done 3844 done 3845 IFS=$as_save_IFS 3846 3847 ;; 3848 esac 3849 fi 3850 BASENAME=$ac_cv_path_BASENAME 3851 if test -n "$BASENAME"; then 3852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 3853 $as_echo "$BASENAME" >&6; } 3854 else 3855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 3856 $as_echo "no" >&6; } 3857 fi 3858 3859 3860 test -n "$BASENAME" && break 3861 done 3862 3863 3864 if test "x$BASENAME" = x; then 3865 if test "xbasename" = x; then 3866 PROG_NAME=basename 3867 else 3868 PROG_NAME=basename 3869 fi 3870 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 3871 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 3872 as_fn_error $? "Cannot continue" "$LINENO" 5 3873 fi 3874 3875 3876 3877 for ac_prog in bash 3878 do 3879 # Extract the first word of "$ac_prog", so it can be a program name with args. 3880 set dummy $ac_prog; ac_word=$2 3881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 3882 $as_echo_n "checking for $ac_word... " >&6; } 3883 if ${ac_cv_path_BASH+:} false; then : 3884 $as_echo_n "(cached) " >&6 3885 else 3886 case $BASH in 3887 [\\/]* | ?:[\\/]*) 3888 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 3889 ;; 3890 *) 3891 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3892 for as_dir in $PATH 3893 do 3894 IFS=$as_save_IFS 3895 test -z "$as_dir" && as_dir=. 3896 for ac_exec_ext in '' $ac_executable_extensions; do 3897 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 3898 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 3899 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 3900 break 2 3901 fi 3902 done 3903 done 3904 IFS=$as_save_IFS 3905 3906 ;; 3907 esac 3908 fi 3909 BASH=$ac_cv_path_BASH 3910 if test -n "$BASH"; then 3911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 3912 $as_echo "$BASH" >&6; } 3913 else 3914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 3915 $as_echo "no" >&6; } 3916 fi 3917 3918 3919 test -n "$BASH" && break 3920 done 3921 3922 3923 if test "x$BASH" = x; then 3924 if test "xbash" = x; then 3925 PROG_NAME=bash 3926 else 3927 PROG_NAME=bash 3928 fi 3929 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 3930 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 3931 as_fn_error $? "Cannot continue" "$LINENO" 5 3932 fi 3933 3934 3935 3936 for ac_prog in cat 3937 do 3938 # Extract the first word of "$ac_prog", so it can be a program name with args. 3939 set dummy $ac_prog; ac_word=$2 3940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 3941 $as_echo_n "checking for $ac_word... " >&6; } 3942 if ${ac_cv_path_CAT+:} false; then : 3943 $as_echo_n "(cached) " >&6 3944 else 3945 case $CAT in 3946 [\\/]* | ?:[\\/]*) 3947 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 3948 ;; 3949 *) 3950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3951 for as_dir in $PATH 3952 do 3953 IFS=$as_save_IFS 3954 test -z "$as_dir" && as_dir=. 3955 for ac_exec_ext in '' $ac_executable_extensions; do 3956 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 3957 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 3958 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 3959 break 2 3960 fi 3961 done 3962 done 3963 IFS=$as_save_IFS 3964 3965 ;; 3966 esac 3967 fi 3968 CAT=$ac_cv_path_CAT 3969 if test -n "$CAT"; then 3970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 3971 $as_echo "$CAT" >&6; } 3972 else 3973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 3974 $as_echo "no" >&6; } 3975 fi 3976 3977 3978 test -n "$CAT" && break 3979 done 3980 3981 3982 if test "x$CAT" = x; then 3983 if test "xcat" = x; then 3984 PROG_NAME=cat 3985 else 3986 PROG_NAME=cat 3987 fi 3988 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 3989 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 3990 as_fn_error $? "Cannot continue" "$LINENO" 5 3991 fi 3992 3993 3994 3995 for ac_prog in chmod 3996 do 3997 # Extract the first word of "$ac_prog", so it can be a program name with args. 3998 set dummy $ac_prog; ac_word=$2 3999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4000 $as_echo_n "checking for $ac_word... " >&6; } 4001 if ${ac_cv_path_CHMOD+:} false; then : 4002 $as_echo_n "(cached) " >&6 4003 else 4004 case $CHMOD in 4005 [\\/]* | ?:[\\/]*) 4006 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 4007 ;; 4008 *) 4009 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4010 for as_dir in $PATH 4011 do 4012 IFS=$as_save_IFS 4013 test -z "$as_dir" && as_dir=. 4014 for ac_exec_ext in '' $ac_executable_extensions; do 4015 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4016 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 4017 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4018 break 2 4019 fi 4020 done 4021 done 4022 IFS=$as_save_IFS 4023 4024 ;; 4025 esac 4026 fi 4027 CHMOD=$ac_cv_path_CHMOD 4028 if test -n "$CHMOD"; then 4029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 4030 $as_echo "$CHMOD" >&6; } 4031 else 4032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4033 $as_echo "no" >&6; } 4034 fi 4035 4036 4037 test -n "$CHMOD" && break 4038 done 4039 4040 4041 if test "x$CHMOD" = x; then 4042 if test "xchmod" = x; then 4043 PROG_NAME=chmod 4044 else 4045 PROG_NAME=chmod 4046 fi 4047 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4048 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4049 as_fn_error $? "Cannot continue" "$LINENO" 5 4050 fi 4051 4052 4053 4054 for ac_prog in cmp 4055 do 4056 # Extract the first word of "$ac_prog", so it can be a program name with args. 4057 set dummy $ac_prog; ac_word=$2 4058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4059 $as_echo_n "checking for $ac_word... " >&6; } 4060 if ${ac_cv_path_CMP+:} false; then : 4061 $as_echo_n "(cached) " >&6 4062 else 4063 case $CMP in 4064 [\\/]* | ?:[\\/]*) 4065 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 4066 ;; 4067 *) 4068 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4069 for as_dir in $PATH 4070 do 4071 IFS=$as_save_IFS 4072 test -z "$as_dir" && as_dir=. 4073 for ac_exec_ext in '' $ac_executable_extensions; do 4074 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4075 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 4076 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4077 break 2 4078 fi 4079 done 4080 done 4081 IFS=$as_save_IFS 4082 4083 ;; 4084 esac 4085 fi 4086 CMP=$ac_cv_path_CMP 4087 if test -n "$CMP"; then 4088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 4089 $as_echo "$CMP" >&6; } 4090 else 4091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4092 $as_echo "no" >&6; } 4093 fi 4094 4095 4096 test -n "$CMP" && break 4097 done 4098 4099 4100 if test "x$CMP" = x; then 4101 if test "xcmp" = x; then 4102 PROG_NAME=cmp 4103 else 4104 PROG_NAME=cmp 4105 fi 4106 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4107 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4108 as_fn_error $? "Cannot continue" "$LINENO" 5 4109 fi 4110 4111 4112 4113 for ac_prog in comm 4114 do 4115 # Extract the first word of "$ac_prog", so it can be a program name with args. 4116 set dummy $ac_prog; ac_word=$2 4117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4118 $as_echo_n "checking for $ac_word... " >&6; } 4119 if ${ac_cv_path_COMM+:} false; then : 4120 $as_echo_n "(cached) " >&6 4121 else 4122 case $COMM in 4123 [\\/]* | ?:[\\/]*) 4124 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 4125 ;; 4126 *) 4127 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4128 for as_dir in $PATH 4129 do 4130 IFS=$as_save_IFS 4131 test -z "$as_dir" && as_dir=. 4132 for ac_exec_ext in '' $ac_executable_extensions; do 4133 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4134 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 4135 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4136 break 2 4137 fi 4138 done 4139 done 4140 IFS=$as_save_IFS 4141 4142 ;; 4143 esac 4144 fi 4145 COMM=$ac_cv_path_COMM 4146 if test -n "$COMM"; then 4147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 4148 $as_echo "$COMM" >&6; } 4149 else 4150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4151 $as_echo "no" >&6; } 4152 fi 4153 4154 4155 test -n "$COMM" && break 4156 done 4157 4158 4159 if test "x$COMM" = x; then 4160 if test "xcomm" = x; then 4161 PROG_NAME=comm 4162 else 4163 PROG_NAME=comm 4164 fi 4165 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4166 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4167 as_fn_error $? "Cannot continue" "$LINENO" 5 4168 fi 4169 4170 4171 4172 for ac_prog in cp 4173 do 4174 # Extract the first word of "$ac_prog", so it can be a program name with args. 4175 set dummy $ac_prog; ac_word=$2 4176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4177 $as_echo_n "checking for $ac_word... " >&6; } 4178 if ${ac_cv_path_CP+:} false; then : 4179 $as_echo_n "(cached) " >&6 4180 else 4181 case $CP in 4182 [\\/]* | ?:[\\/]*) 4183 ac_cv_path_CP="$CP" # Let the user override the test with a path. 4184 ;; 4185 *) 4186 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4187 for as_dir in $PATH 4188 do 4189 IFS=$as_save_IFS 4190 test -z "$as_dir" && as_dir=. 4191 for ac_exec_ext in '' $ac_executable_extensions; do 4192 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4193 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 4194 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4195 break 2 4196 fi 4197 done 4198 done 4199 IFS=$as_save_IFS 4200 4201 ;; 4202 esac 4203 fi 4204 CP=$ac_cv_path_CP 4205 if test -n "$CP"; then 4206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 4207 $as_echo "$CP" >&6; } 4208 else 4209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4210 $as_echo "no" >&6; } 4211 fi 4212 4213 4214 test -n "$CP" && break 4215 done 4216 4217 4218 if test "x$CP" = x; then 4219 if test "xcp" = x; then 4220 PROG_NAME=cp 4221 else 4222 PROG_NAME=cp 4223 fi 4224 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4225 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4226 as_fn_error $? "Cannot continue" "$LINENO" 5 4227 fi 4228 4229 4230 4231 for ac_prog in cpio 4232 do 4233 # Extract the first word of "$ac_prog", so it can be a program name with args. 4234 set dummy $ac_prog; ac_word=$2 4235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4236 $as_echo_n "checking for $ac_word... " >&6; } 4237 if ${ac_cv_path_CPIO+:} false; then : 4238 $as_echo_n "(cached) " >&6 4239 else 4240 case $CPIO in 4241 [\\/]* | ?:[\\/]*) 4242 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 4243 ;; 4244 *) 4245 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4246 for as_dir in $PATH 4247 do 4248 IFS=$as_save_IFS 4249 test -z "$as_dir" && as_dir=. 4250 for ac_exec_ext in '' $ac_executable_extensions; do 4251 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4252 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 4253 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4254 break 2 4255 fi 4256 done 4257 done 4258 IFS=$as_save_IFS 4259 4260 ;; 4261 esac 4262 fi 4263 CPIO=$ac_cv_path_CPIO 4264 if test -n "$CPIO"; then 4265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 4266 $as_echo "$CPIO" >&6; } 4267 else 4268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4269 $as_echo "no" >&6; } 4270 fi 4271 4272 4273 test -n "$CPIO" && break 4274 done 4275 4276 4277 if test "x$CPIO" = x; then 4278 if test "xcpio" = x; then 4279 PROG_NAME=cpio 4280 else 4281 PROG_NAME=cpio 4282 fi 4283 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4284 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4285 as_fn_error $? "Cannot continue" "$LINENO" 5 4286 fi 4287 4288 4289 4290 for ac_prog in cut 4291 do 4292 # Extract the first word of "$ac_prog", so it can be a program name with args. 4293 set dummy $ac_prog; ac_word=$2 4294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4295 $as_echo_n "checking for $ac_word... " >&6; } 4296 if ${ac_cv_path_CUT+:} false; then : 4297 $as_echo_n "(cached) " >&6 4298 else 4299 case $CUT in 4300 [\\/]* | ?:[\\/]*) 4301 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 4302 ;; 4303 *) 4304 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4305 for as_dir in $PATH 4306 do 4307 IFS=$as_save_IFS 4308 test -z "$as_dir" && as_dir=. 4309 for ac_exec_ext in '' $ac_executable_extensions; do 4310 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4311 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 4312 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4313 break 2 4314 fi 4315 done 4316 done 4317 IFS=$as_save_IFS 4318 4319 ;; 4320 esac 4321 fi 4322 CUT=$ac_cv_path_CUT 4323 if test -n "$CUT"; then 4324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 4325 $as_echo "$CUT" >&6; } 4326 else 4327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4328 $as_echo "no" >&6; } 4329 fi 4330 4331 4332 test -n "$CUT" && break 4333 done 4334 4335 4336 if test "x$CUT" = x; then 4337 if test "xcut" = x; then 4338 PROG_NAME=cut 4339 else 4340 PROG_NAME=cut 4341 fi 4342 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4343 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4344 as_fn_error $? "Cannot continue" "$LINENO" 5 4345 fi 4346 4347 4348 4349 for ac_prog in date 4350 do 4351 # Extract the first word of "$ac_prog", so it can be a program name with args. 4352 set dummy $ac_prog; ac_word=$2 4353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4354 $as_echo_n "checking for $ac_word... " >&6; } 4355 if ${ac_cv_path_DATE+:} false; then : 4356 $as_echo_n "(cached) " >&6 4357 else 4358 case $DATE in 4359 [\\/]* | ?:[\\/]*) 4360 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 4361 ;; 4362 *) 4363 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4364 for as_dir in $PATH 4365 do 4366 IFS=$as_save_IFS 4367 test -z "$as_dir" && as_dir=. 4368 for ac_exec_ext in '' $ac_executable_extensions; do 4369 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4370 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 4371 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4372 break 2 4373 fi 4374 done 4375 done 4376 IFS=$as_save_IFS 4377 4378 ;; 4379 esac 4380 fi 4381 DATE=$ac_cv_path_DATE 4382 if test -n "$DATE"; then 4383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 4384 $as_echo "$DATE" >&6; } 4385 else 4386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4387 $as_echo "no" >&6; } 4388 fi 4389 4390 4391 test -n "$DATE" && break 4392 done 4393 4394 4395 if test "x$DATE" = x; then 4396 if test "xdate" = x; then 4397 PROG_NAME=date 4398 else 4399 PROG_NAME=date 4400 fi 4401 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4402 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4403 as_fn_error $? "Cannot continue" "$LINENO" 5 4404 fi 4405 4406 4407 4408 for ac_prog in gdiff diff 4409 do 4410 # Extract the first word of "$ac_prog", so it can be a program name with args. 4411 set dummy $ac_prog; ac_word=$2 4412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4413 $as_echo_n "checking for $ac_word... " >&6; } 4414 if ${ac_cv_path_DIFF+:} false; then : 4415 $as_echo_n "(cached) " >&6 4416 else 4417 case $DIFF in 4418 [\\/]* | ?:[\\/]*) 4419 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 4420 ;; 4421 *) 4422 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4423 for as_dir in $PATH 4424 do 4425 IFS=$as_save_IFS 4426 test -z "$as_dir" && as_dir=. 4427 for ac_exec_ext in '' $ac_executable_extensions; do 4428 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4429 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 4430 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4431 break 2 4432 fi 4433 done 4434 done 4435 IFS=$as_save_IFS 4436 4437 ;; 4438 esac 4439 fi 4440 DIFF=$ac_cv_path_DIFF 4441 if test -n "$DIFF"; then 4442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 4443 $as_echo "$DIFF" >&6; } 4444 else 4445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4446 $as_echo "no" >&6; } 4447 fi 4448 4449 4450 test -n "$DIFF" && break 4451 done 4452 4453 4454 if test "x$DIFF" = x; then 4455 if test "xgdiff diff" = x; then 4456 PROG_NAME=diff 4457 else 4458 PROG_NAME=gdiff diff 4459 fi 4460 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4461 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4462 as_fn_error $? "Cannot continue" "$LINENO" 5 4463 fi 4464 4465 4466 4467 for ac_prog in dirname 4468 do 4469 # Extract the first word of "$ac_prog", so it can be a program name with args. 4470 set dummy $ac_prog; ac_word=$2 4471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4472 $as_echo_n "checking for $ac_word... " >&6; } 4473 if ${ac_cv_path_DIRNAME+:} false; then : 4474 $as_echo_n "(cached) " >&6 4475 else 4476 case $DIRNAME in 4477 [\\/]* | ?:[\\/]*) 4478 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 4479 ;; 4480 *) 4481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4482 for as_dir in $PATH 4483 do 4484 IFS=$as_save_IFS 4485 test -z "$as_dir" && as_dir=. 4486 for ac_exec_ext in '' $ac_executable_extensions; do 4487 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4488 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 4489 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4490 break 2 4491 fi 4492 done 4493 done 4494 IFS=$as_save_IFS 4495 4496 ;; 4497 esac 4498 fi 4499 DIRNAME=$ac_cv_path_DIRNAME 4500 if test -n "$DIRNAME"; then 4501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 4502 $as_echo "$DIRNAME" >&6; } 4503 else 4504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4505 $as_echo "no" >&6; } 4506 fi 4507 4508 4509 test -n "$DIRNAME" && break 4510 done 4511 4512 4513 if test "x$DIRNAME" = x; then 4514 if test "xdirname" = x; then 4515 PROG_NAME=dirname 4516 else 4517 PROG_NAME=dirname 4518 fi 4519 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4520 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4521 as_fn_error $? "Cannot continue" "$LINENO" 5 4522 fi 4523 4524 4525 4526 for ac_prog in echo 4527 do 4528 # Extract the first word of "$ac_prog", so it can be a program name with args. 4529 set dummy $ac_prog; ac_word=$2 4530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4531 $as_echo_n "checking for $ac_word... " >&6; } 4532 if ${ac_cv_path_ECHO+:} false; then : 4533 $as_echo_n "(cached) " >&6 4534 else 4535 case $ECHO in 4536 [\\/]* | ?:[\\/]*) 4537 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 4538 ;; 4539 *) 4540 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4541 for as_dir in $PATH 4542 do 4543 IFS=$as_save_IFS 4544 test -z "$as_dir" && as_dir=. 4545 for ac_exec_ext in '' $ac_executable_extensions; do 4546 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4547 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 4548 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4549 break 2 4550 fi 4551 done 4552 done 4553 IFS=$as_save_IFS 4554 4555 ;; 4556 esac 4557 fi 4558 ECHO=$ac_cv_path_ECHO 4559 if test -n "$ECHO"; then 4560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 4561 $as_echo "$ECHO" >&6; } 4562 else 4563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4564 $as_echo "no" >&6; } 4565 fi 4566 4567 4568 test -n "$ECHO" && break 4569 done 4570 4571 4572 if test "x$ECHO" = x; then 4573 if test "xecho" = x; then 4574 PROG_NAME=echo 4575 else 4576 PROG_NAME=echo 4577 fi 4578 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4579 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4580 as_fn_error $? "Cannot continue" "$LINENO" 5 4581 fi 4582 4583 4584 4585 for ac_prog in expr 4586 do 4587 # Extract the first word of "$ac_prog", so it can be a program name with args. 4588 set dummy $ac_prog; ac_word=$2 4589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4590 $as_echo_n "checking for $ac_word... " >&6; } 4591 if ${ac_cv_path_EXPR+:} false; then : 4592 $as_echo_n "(cached) " >&6 4593 else 4594 case $EXPR in 4595 [\\/]* | ?:[\\/]*) 4596 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 4597 ;; 4598 *) 4599 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4600 for as_dir in $PATH 4601 do 4602 IFS=$as_save_IFS 4603 test -z "$as_dir" && as_dir=. 4604 for ac_exec_ext in '' $ac_executable_extensions; do 4605 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4606 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 4607 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4608 break 2 4609 fi 4610 done 4611 done 4612 IFS=$as_save_IFS 4613 4614 ;; 4615 esac 4616 fi 4617 EXPR=$ac_cv_path_EXPR 4618 if test -n "$EXPR"; then 4619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 4620 $as_echo "$EXPR" >&6; } 4621 else 4622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4623 $as_echo "no" >&6; } 4624 fi 4625 4626 4627 test -n "$EXPR" && break 4628 done 4629 4630 4631 if test "x$EXPR" = x; then 4632 if test "xexpr" = x; then 4633 PROG_NAME=expr 4634 else 4635 PROG_NAME=expr 4636 fi 4637 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4638 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4639 as_fn_error $? "Cannot continue" "$LINENO" 5 4640 fi 4641 4642 4643 4644 for ac_prog in file 4645 do 4646 # Extract the first word of "$ac_prog", so it can be a program name with args. 4647 set dummy $ac_prog; ac_word=$2 4648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4649 $as_echo_n "checking for $ac_word... " >&6; } 4650 if ${ac_cv_path_FILE+:} false; then : 4651 $as_echo_n "(cached) " >&6 4652 else 4653 case $FILE in 4654 [\\/]* | ?:[\\/]*) 4655 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 4656 ;; 4657 *) 4658 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4659 for as_dir in $PATH 4660 do 4661 IFS=$as_save_IFS 4662 test -z "$as_dir" && as_dir=. 4663 for ac_exec_ext in '' $ac_executable_extensions; do 4664 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4665 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 4666 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4667 break 2 4668 fi 4669 done 4670 done 4671 IFS=$as_save_IFS 4672 4673 ;; 4674 esac 4675 fi 4676 FILE=$ac_cv_path_FILE 4677 if test -n "$FILE"; then 4678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 4679 $as_echo "$FILE" >&6; } 4680 else 4681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4682 $as_echo "no" >&6; } 4683 fi 4684 4685 4686 test -n "$FILE" && break 4687 done 4688 4689 4690 if test "x$FILE" = x; then 4691 if test "xfile" = x; then 4692 PROG_NAME=file 4693 else 4694 PROG_NAME=file 4695 fi 4696 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4697 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4698 as_fn_error $? "Cannot continue" "$LINENO" 5 4699 fi 4700 4701 4702 4703 for ac_prog in find 4704 do 4705 # Extract the first word of "$ac_prog", so it can be a program name with args. 4706 set dummy $ac_prog; ac_word=$2 4707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4708 $as_echo_n "checking for $ac_word... " >&6; } 4709 if ${ac_cv_path_FIND+:} false; then : 4710 $as_echo_n "(cached) " >&6 4711 else 4712 case $FIND in 4713 [\\/]* | ?:[\\/]*) 4714 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 4715 ;; 4716 *) 4717 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4718 for as_dir in $PATH 4719 do 4720 IFS=$as_save_IFS 4721 test -z "$as_dir" && as_dir=. 4722 for ac_exec_ext in '' $ac_executable_extensions; do 4723 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4724 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 4725 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4726 break 2 4727 fi 4728 done 4729 done 4730 IFS=$as_save_IFS 4731 4732 ;; 4733 esac 4734 fi 4735 FIND=$ac_cv_path_FIND 4736 if test -n "$FIND"; then 4737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 4738 $as_echo "$FIND" >&6; } 4739 else 4740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4741 $as_echo "no" >&6; } 4742 fi 4743 4744 4745 test -n "$FIND" && break 4746 done 4747 4748 4749 if test "x$FIND" = x; then 4750 if test "xfind" = x; then 4751 PROG_NAME=find 4752 else 4753 PROG_NAME=find 4754 fi 4755 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4756 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4757 as_fn_error $? "Cannot continue" "$LINENO" 5 4758 fi 4759 4760 4761 4762 for ac_prog in head 4763 do 4764 # Extract the first word of "$ac_prog", so it can be a program name with args. 4765 set dummy $ac_prog; ac_word=$2 4766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4767 $as_echo_n "checking for $ac_word... " >&6; } 4768 if ${ac_cv_path_HEAD+:} false; then : 4769 $as_echo_n "(cached) " >&6 4770 else 4771 case $HEAD in 4772 [\\/]* | ?:[\\/]*) 4773 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 4774 ;; 4775 *) 4776 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4777 for as_dir in $PATH 4778 do 4779 IFS=$as_save_IFS 4780 test -z "$as_dir" && as_dir=. 4781 for ac_exec_ext in '' $ac_executable_extensions; do 4782 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4783 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 4784 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4785 break 2 4786 fi 4787 done 4788 done 4789 IFS=$as_save_IFS 4790 4791 ;; 4792 esac 4793 fi 4794 HEAD=$ac_cv_path_HEAD 4795 if test -n "$HEAD"; then 4796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 4797 $as_echo "$HEAD" >&6; } 4798 else 4799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4800 $as_echo "no" >&6; } 4801 fi 4802 4803 4804 test -n "$HEAD" && break 4805 done 4806 4807 4808 if test "x$HEAD" = x; then 4809 if test "xhead" = x; then 4810 PROG_NAME=head 4811 else 4812 PROG_NAME=head 4813 fi 4814 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4815 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4816 as_fn_error $? "Cannot continue" "$LINENO" 5 4817 fi 4818 4819 4820 4821 for ac_prog in ln 4822 do 4823 # Extract the first word of "$ac_prog", so it can be a program name with args. 4824 set dummy $ac_prog; ac_word=$2 4825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4826 $as_echo_n "checking for $ac_word... " >&6; } 4827 if ${ac_cv_path_LN+:} false; then : 4828 $as_echo_n "(cached) " >&6 4829 else 4830 case $LN in 4831 [\\/]* | ?:[\\/]*) 4832 ac_cv_path_LN="$LN" # Let the user override the test with a path. 4833 ;; 4834 *) 4835 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4836 for as_dir in $PATH 4837 do 4838 IFS=$as_save_IFS 4839 test -z "$as_dir" && as_dir=. 4840 for ac_exec_ext in '' $ac_executable_extensions; do 4841 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4842 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 4843 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4844 break 2 4845 fi 4846 done 4847 done 4848 IFS=$as_save_IFS 4849 4850 ;; 4851 esac 4852 fi 4853 LN=$ac_cv_path_LN 4854 if test -n "$LN"; then 4855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 4856 $as_echo "$LN" >&6; } 4857 else 4858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4859 $as_echo "no" >&6; } 4860 fi 4861 4862 4863 test -n "$LN" && break 4864 done 4865 4866 4867 if test "x$LN" = x; then 4868 if test "xln" = x; then 4869 PROG_NAME=ln 4870 else 4871 PROG_NAME=ln 4872 fi 4873 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4874 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4875 as_fn_error $? "Cannot continue" "$LINENO" 5 4876 fi 4877 4878 4879 4880 for ac_prog in ls 4881 do 4882 # Extract the first word of "$ac_prog", so it can be a program name with args. 4883 set dummy $ac_prog; ac_word=$2 4884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4885 $as_echo_n "checking for $ac_word... " >&6; } 4886 if ${ac_cv_path_LS+:} false; then : 4887 $as_echo_n "(cached) " >&6 4888 else 4889 case $LS in 4890 [\\/]* | ?:[\\/]*) 4891 ac_cv_path_LS="$LS" # Let the user override the test with a path. 4892 ;; 4893 *) 4894 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4895 for as_dir in $PATH 4896 do 4897 IFS=$as_save_IFS 4898 test -z "$as_dir" && as_dir=. 4899 for ac_exec_ext in '' $ac_executable_extensions; do 4900 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4901 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 4902 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4903 break 2 4904 fi 4905 done 4906 done 4907 IFS=$as_save_IFS 4908 4909 ;; 4910 esac 4911 fi 4912 LS=$ac_cv_path_LS 4913 if test -n "$LS"; then 4914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 4915 $as_echo "$LS" >&6; } 4916 else 4917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4918 $as_echo "no" >&6; } 4919 fi 4920 4921 4922 test -n "$LS" && break 4923 done 4924 4925 4926 if test "x$LS" = x; then 4927 if test "xls" = x; then 4928 PROG_NAME=ls 4929 else 4930 PROG_NAME=ls 4931 fi 4932 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4933 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4934 as_fn_error $? "Cannot continue" "$LINENO" 5 4935 fi 4936 4937 4938 4939 for ac_prog in mkdir 4940 do 4941 # Extract the first word of "$ac_prog", so it can be a program name with args. 4942 set dummy $ac_prog; ac_word=$2 4943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4944 $as_echo_n "checking for $ac_word... " >&6; } 4945 if ${ac_cv_path_MKDIR+:} false; then : 4946 $as_echo_n "(cached) " >&6 4947 else 4948 case $MKDIR in 4949 [\\/]* | ?:[\\/]*) 4950 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 4951 ;; 4952 *) 4953 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4954 for as_dir in $PATH 4955 do 4956 IFS=$as_save_IFS 4957 test -z "$as_dir" && as_dir=. 4958 for ac_exec_ext in '' $ac_executable_extensions; do 4959 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4960 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 4961 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4962 break 2 4963 fi 4964 done 4965 done 4966 IFS=$as_save_IFS 4967 4968 ;; 4969 esac 4970 fi 4971 MKDIR=$ac_cv_path_MKDIR 4972 if test -n "$MKDIR"; then 4973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 4974 $as_echo "$MKDIR" >&6; } 4975 else 4976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4977 $as_echo "no" >&6; } 4978 fi 4979 4980 4981 test -n "$MKDIR" && break 4982 done 4983 4984 4985 if test "x$MKDIR" = x; then 4986 if test "xmkdir" = x; then 4987 PROG_NAME=mkdir 4988 else 4989 PROG_NAME=mkdir 4990 fi 4991 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4992 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4993 as_fn_error $? "Cannot continue" "$LINENO" 5 4994 fi 4995 4996 4997 4998 for ac_prog in mktemp 4999 do 5000 # Extract the first word of "$ac_prog", so it can be a program name with args. 5001 set dummy $ac_prog; ac_word=$2 5002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5003 $as_echo_n "checking for $ac_word... " >&6; } 5004 if ${ac_cv_path_MKTEMP+:} false; then : 5005 $as_echo_n "(cached) " >&6 5006 else 5007 case $MKTEMP in 5008 [\\/]* | ?:[\\/]*) 5009 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 5010 ;; 5011 *) 5012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5013 for as_dir in $PATH 5014 do 5015 IFS=$as_save_IFS 5016 test -z "$as_dir" && as_dir=. 5017 for ac_exec_ext in '' $ac_executable_extensions; do 5018 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5019 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 5020 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5021 break 2 5022 fi 5023 done 5024 done 5025 IFS=$as_save_IFS 5026 5027 ;; 5028 esac 5029 fi 5030 MKTEMP=$ac_cv_path_MKTEMP 5031 if test -n "$MKTEMP"; then 5032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 5033 $as_echo "$MKTEMP" >&6; } 5034 else 5035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5036 $as_echo "no" >&6; } 5037 fi 5038 5039 5040 test -n "$MKTEMP" && break 5041 done 5042 5043 5044 if test "x$MKTEMP" = x; then 5045 if test "xmktemp" = x; then 5046 PROG_NAME=mktemp 5047 else 5048 PROG_NAME=mktemp 5049 fi 5050 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5051 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5052 as_fn_error $? "Cannot continue" "$LINENO" 5 5053 fi 5054 5055 5056 5057 for ac_prog in mv 5058 do 5059 # Extract the first word of "$ac_prog", so it can be a program name with args. 5060 set dummy $ac_prog; ac_word=$2 5061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5062 $as_echo_n "checking for $ac_word... " >&6; } 5063 if ${ac_cv_path_MV+:} false; then : 5064 $as_echo_n "(cached) " >&6 5065 else 5066 case $MV in 5067 [\\/]* | ?:[\\/]*) 5068 ac_cv_path_MV="$MV" # Let the user override the test with a path. 5069 ;; 5070 *) 5071 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5072 for as_dir in $PATH 5073 do 5074 IFS=$as_save_IFS 5075 test -z "$as_dir" && as_dir=. 5076 for ac_exec_ext in '' $ac_executable_extensions; do 5077 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5078 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 5079 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5080 break 2 5081 fi 5082 done 5083 done 5084 IFS=$as_save_IFS 5085 5086 ;; 5087 esac 5088 fi 5089 MV=$ac_cv_path_MV 5090 if test -n "$MV"; then 5091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 5092 $as_echo "$MV" >&6; } 5093 else 5094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5095 $as_echo "no" >&6; } 5096 fi 5097 5098 5099 test -n "$MV" && break 5100 done 5101 5102 5103 if test "x$MV" = x; then 5104 if test "xmv" = x; then 5105 PROG_NAME=mv 5106 else 5107 PROG_NAME=mv 5108 fi 5109 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5110 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5111 as_fn_error $? "Cannot continue" "$LINENO" 5 5112 fi 5113 5114 5115 5116 for ac_prog in printf 5117 do 5118 # Extract the first word of "$ac_prog", so it can be a program name with args. 5119 set dummy $ac_prog; ac_word=$2 5120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5121 $as_echo_n "checking for $ac_word... " >&6; } 5122 if ${ac_cv_path_PRINTF+:} false; then : 5123 $as_echo_n "(cached) " >&6 5124 else 5125 case $PRINTF in 5126 [\\/]* | ?:[\\/]*) 5127 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 5128 ;; 5129 *) 5130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5131 for as_dir in $PATH 5132 do 5133 IFS=$as_save_IFS 5134 test -z "$as_dir" && as_dir=. 5135 for ac_exec_ext in '' $ac_executable_extensions; do 5136 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5137 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 5138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5139 break 2 5140 fi 5141 done 5142 done 5143 IFS=$as_save_IFS 5144 5145 ;; 5146 esac 5147 fi 5148 PRINTF=$ac_cv_path_PRINTF 5149 if test -n "$PRINTF"; then 5150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 5151 $as_echo "$PRINTF" >&6; } 5152 else 5153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5154 $as_echo "no" >&6; } 5155 fi 5156 5157 5158 test -n "$PRINTF" && break 5159 done 5160 5161 5162 if test "x$PRINTF" = x; then 5163 if test "xprintf" = x; then 5164 PROG_NAME=printf 5165 else 5166 PROG_NAME=printf 5167 fi 5168 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5169 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5170 as_fn_error $? "Cannot continue" "$LINENO" 5 5171 fi 5172 5173 5174 5175 for ac_prog in pwd 5176 do 5177 # Extract the first word of "$ac_prog", so it can be a program name with args. 5178 set dummy $ac_prog; ac_word=$2 5179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5180 $as_echo_n "checking for $ac_word... " >&6; } 5181 if ${ac_cv_path_THEPWDCMD+:} false; then : 5182 $as_echo_n "(cached) " >&6 5183 else 5184 case $THEPWDCMD in 5185 [\\/]* | ?:[\\/]*) 5186 ac_cv_path_THEPWDCMD="$THEPWDCMD" # Let the user override the test with a path. 5187 ;; 5188 *) 5189 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5190 for as_dir in $PATH 5191 do 5192 IFS=$as_save_IFS 5193 test -z "$as_dir" && as_dir=. 5194 for ac_exec_ext in '' $ac_executable_extensions; do 5195 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5196 ac_cv_path_THEPWDCMD="$as_dir/$ac_word$ac_exec_ext" 5197 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5198 break 2 5199 fi 5200 done 5201 done 5202 IFS=$as_save_IFS 5203 5204 ;; 5205 esac 5206 fi 5207 THEPWDCMD=$ac_cv_path_THEPWDCMD 5208 if test -n "$THEPWDCMD"; then 5209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $THEPWDCMD" >&5 5210 $as_echo "$THEPWDCMD" >&6; } 5211 else 5212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5213 $as_echo "no" >&6; } 5214 fi 5215 5216 5217 test -n "$THEPWDCMD" && break 5218 done 5219 5220 5221 if test "x$THEPWDCMD" = x; then 5222 if test "xpwd" = x; then 5223 PROG_NAME=thepwdcmd 5224 else 5225 PROG_NAME=pwd 5226 fi 5227 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5228 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5229 as_fn_error $? "Cannot continue" "$LINENO" 5 5230 fi 5231 5232 5233 5234 for ac_prog in rm 5235 do 5236 # Extract the first word of "$ac_prog", so it can be a program name with args. 5237 set dummy $ac_prog; ac_word=$2 5238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5239 $as_echo_n "checking for $ac_word... " >&6; } 5240 if ${ac_cv_path_RM+:} false; then : 5241 $as_echo_n "(cached) " >&6 5242 else 5243 case $RM in 5244 [\\/]* | ?:[\\/]*) 5245 ac_cv_path_RM="$RM" # Let the user override the test with a path. 5246 ;; 5247 *) 5248 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5249 for as_dir in $PATH 5250 do 5251 IFS=$as_save_IFS 5252 test -z "$as_dir" && as_dir=. 5253 for ac_exec_ext in '' $ac_executable_extensions; do 5254 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5255 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 5256 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5257 break 2 5258 fi 5259 done 5260 done 5261 IFS=$as_save_IFS 5262 5263 ;; 5264 esac 5265 fi 5266 RM=$ac_cv_path_RM 5267 if test -n "$RM"; then 5268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 5269 $as_echo "$RM" >&6; } 5270 else 5271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5272 $as_echo "no" >&6; } 5273 fi 5274 5275 5276 test -n "$RM" && break 5277 done 5278 5279 5280 if test "x$RM" = x; then 5281 if test "xrm" = x; then 5282 PROG_NAME=rm 5283 else 5284 PROG_NAME=rm 5285 fi 5286 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5287 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5288 as_fn_error $? "Cannot continue" "$LINENO" 5 5289 fi 5290 5291 5292 5293 for ac_prog in sh 5294 do 5295 # Extract the first word of "$ac_prog", so it can be a program name with args. 5296 set dummy $ac_prog; ac_word=$2 5297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5298 $as_echo_n "checking for $ac_word... " >&6; } 5299 if ${ac_cv_path_SH+:} false; then : 5300 $as_echo_n "(cached) " >&6 5301 else 5302 case $SH in 5303 [\\/]* | ?:[\\/]*) 5304 ac_cv_path_SH="$SH" # Let the user override the test with a path. 5305 ;; 5306 *) 5307 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5308 for as_dir in $PATH 5309 do 5310 IFS=$as_save_IFS 5311 test -z "$as_dir" && as_dir=. 5312 for ac_exec_ext in '' $ac_executable_extensions; do 5313 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5314 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 5315 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5316 break 2 5317 fi 5318 done 5319 done 5320 IFS=$as_save_IFS 5321 5322 ;; 5323 esac 5324 fi 5325 SH=$ac_cv_path_SH 5326 if test -n "$SH"; then 5327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 5328 $as_echo "$SH" >&6; } 5329 else 5330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5331 $as_echo "no" >&6; } 5332 fi 5333 5334 5335 test -n "$SH" && break 5336 done 5337 5338 5339 if test "x$SH" = x; then 5340 if test "xsh" = x; then 5341 PROG_NAME=sh 5342 else 5343 PROG_NAME=sh 5344 fi 5345 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5346 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5347 as_fn_error $? "Cannot continue" "$LINENO" 5 5348 fi 5349 5350 5351 5352 for ac_prog in sort 5353 do 5354 # Extract the first word of "$ac_prog", so it can be a program name with args. 5355 set dummy $ac_prog; ac_word=$2 5356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5357 $as_echo_n "checking for $ac_word... " >&6; } 5358 if ${ac_cv_path_SORT+:} false; then : 5359 $as_echo_n "(cached) " >&6 5360 else 5361 case $SORT in 5362 [\\/]* | ?:[\\/]*) 5363 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 5364 ;; 5365 *) 5366 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5367 for as_dir in $PATH 5368 do 5369 IFS=$as_save_IFS 5370 test -z "$as_dir" && as_dir=. 5371 for ac_exec_ext in '' $ac_executable_extensions; do 5372 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5373 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 5374 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5375 break 2 5376 fi 5377 done 5378 done 5379 IFS=$as_save_IFS 5380 5381 ;; 5382 esac 5383 fi 5384 SORT=$ac_cv_path_SORT 5385 if test -n "$SORT"; then 5386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 5387 $as_echo "$SORT" >&6; } 5388 else 5389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5390 $as_echo "no" >&6; } 5391 fi 5392 5393 5394 test -n "$SORT" && break 5395 done 5396 5397 5398 if test "x$SORT" = x; then 5399 if test "xsort" = x; then 5400 PROG_NAME=sort 5401 else 5402 PROG_NAME=sort 5403 fi 5404 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5405 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5406 as_fn_error $? "Cannot continue" "$LINENO" 5 5407 fi 5408 5409 5410 5411 for ac_prog in tail 5412 do 5413 # Extract the first word of "$ac_prog", so it can be a program name with args. 5414 set dummy $ac_prog; ac_word=$2 5415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5416 $as_echo_n "checking for $ac_word... " >&6; } 5417 if ${ac_cv_path_TAIL+:} false; then : 5418 $as_echo_n "(cached) " >&6 5419 else 5420 case $TAIL in 5421 [\\/]* | ?:[\\/]*) 5422 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 5423 ;; 5424 *) 5425 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5426 for as_dir in $PATH 5427 do 5428 IFS=$as_save_IFS 5429 test -z "$as_dir" && as_dir=. 5430 for ac_exec_ext in '' $ac_executable_extensions; do 5431 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5432 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 5433 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5434 break 2 5435 fi 5436 done 5437 done 5438 IFS=$as_save_IFS 5439 5440 ;; 5441 esac 5442 fi 5443 TAIL=$ac_cv_path_TAIL 5444 if test -n "$TAIL"; then 5445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 5446 $as_echo "$TAIL" >&6; } 5447 else 5448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5449 $as_echo "no" >&6; } 5450 fi 5451 5452 5453 test -n "$TAIL" && break 5454 done 5455 5456 5457 if test "x$TAIL" = x; then 5458 if test "xtail" = x; then 5459 PROG_NAME=tail 5460 else 5461 PROG_NAME=tail 5462 fi 5463 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5464 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5465 as_fn_error $? "Cannot continue" "$LINENO" 5 5466 fi 5467 5468 5469 5470 for ac_prog in tar 5471 do 5472 # Extract the first word of "$ac_prog", so it can be a program name with args. 5473 set dummy $ac_prog; ac_word=$2 5474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5475 $as_echo_n "checking for $ac_word... " >&6; } 5476 if ${ac_cv_path_TAR+:} false; then : 5477 $as_echo_n "(cached) " >&6 5478 else 5479 case $TAR in 5480 [\\/]* | ?:[\\/]*) 5481 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 5482 ;; 5483 *) 5484 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5485 for as_dir in $PATH 5486 do 5487 IFS=$as_save_IFS 5488 test -z "$as_dir" && as_dir=. 5489 for ac_exec_ext in '' $ac_executable_extensions; do 5490 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5491 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 5492 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5493 break 2 5494 fi 5495 done 5496 done 5497 IFS=$as_save_IFS 5498 5499 ;; 5500 esac 5501 fi 5502 TAR=$ac_cv_path_TAR 5503 if test -n "$TAR"; then 5504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 5505 $as_echo "$TAR" >&6; } 5506 else 5507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5508 $as_echo "no" >&6; } 5509 fi 5510 5511 5512 test -n "$TAR" && break 5513 done 5514 5515 5516 if test "x$TAR" = x; then 5517 if test "xtar" = x; then 5518 PROG_NAME=tar 5519 else 5520 PROG_NAME=tar 5521 fi 5522 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5523 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5524 as_fn_error $? "Cannot continue" "$LINENO" 5 5525 fi 5526 5527 5528 5529 for ac_prog in tee 5530 do 5531 # Extract the first word of "$ac_prog", so it can be a program name with args. 5532 set dummy $ac_prog; ac_word=$2 5533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5534 $as_echo_n "checking for $ac_word... " >&6; } 5535 if ${ac_cv_path_TEE+:} false; then : 5536 $as_echo_n "(cached) " >&6 5537 else 5538 case $TEE in 5539 [\\/]* | ?:[\\/]*) 5540 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 5541 ;; 5542 *) 5543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5544 for as_dir in $PATH 5545 do 5546 IFS=$as_save_IFS 5547 test -z "$as_dir" && as_dir=. 5548 for ac_exec_ext in '' $ac_executable_extensions; do 5549 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5550 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 5551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5552 break 2 5553 fi 5554 done 5555 done 5556 IFS=$as_save_IFS 5557 5558 ;; 5559 esac 5560 fi 5561 TEE=$ac_cv_path_TEE 5562 if test -n "$TEE"; then 5563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 5564 $as_echo "$TEE" >&6; } 5565 else 5566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5567 $as_echo "no" >&6; } 5568 fi 5569 5570 5571 test -n "$TEE" && break 5572 done 5573 5574 5575 if test "x$TEE" = x; then 5576 if test "xtee" = x; then 5577 PROG_NAME=tee 5578 else 5579 PROG_NAME=tee 5580 fi 5581 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5582 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5583 as_fn_error $? "Cannot continue" "$LINENO" 5 5584 fi 5585 5586 5587 5588 for ac_prog in touch 5589 do 5590 # Extract the first word of "$ac_prog", so it can be a program name with args. 5591 set dummy $ac_prog; ac_word=$2 5592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5593 $as_echo_n "checking for $ac_word... " >&6; } 5594 if ${ac_cv_path_TOUCH+:} false; then : 5595 $as_echo_n "(cached) " >&6 5596 else 5597 case $TOUCH in 5598 [\\/]* | ?:[\\/]*) 5599 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 5600 ;; 5601 *) 5602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5603 for as_dir in $PATH 5604 do 5605 IFS=$as_save_IFS 5606 test -z "$as_dir" && as_dir=. 5607 for ac_exec_ext in '' $ac_executable_extensions; do 5608 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5609 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 5610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5611 break 2 5612 fi 5613 done 5614 done 5615 IFS=$as_save_IFS 5616 5617 ;; 5618 esac 5619 fi 5620 TOUCH=$ac_cv_path_TOUCH 5621 if test -n "$TOUCH"; then 5622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 5623 $as_echo "$TOUCH" >&6; } 5624 else 5625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5626 $as_echo "no" >&6; } 5627 fi 5628 5629 5630 test -n "$TOUCH" && break 5631 done 5632 5633 5634 if test "x$TOUCH" = x; then 5635 if test "xtouch" = x; then 5636 PROG_NAME=touch 5637 else 5638 PROG_NAME=touch 5639 fi 5640 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5641 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5642 as_fn_error $? "Cannot continue" "$LINENO" 5 5643 fi 5644 5645 5646 5647 for ac_prog in tr 5648 do 5649 # Extract the first word of "$ac_prog", so it can be a program name with args. 5650 set dummy $ac_prog; ac_word=$2 5651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5652 $as_echo_n "checking for $ac_word... " >&6; } 5653 if ${ac_cv_path_TR+:} false; then : 5654 $as_echo_n "(cached) " >&6 5655 else 5656 case $TR in 5657 [\\/]* | ?:[\\/]*) 5658 ac_cv_path_TR="$TR" # Let the user override the test with a path. 5659 ;; 5660 *) 5661 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5662 for as_dir in $PATH 5663 do 5664 IFS=$as_save_IFS 5665 test -z "$as_dir" && as_dir=. 5666 for ac_exec_ext in '' $ac_executable_extensions; do 5667 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5668 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 5669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5670 break 2 5671 fi 5672 done 5673 done 5674 IFS=$as_save_IFS 5675 5676 ;; 5677 esac 5678 fi 5679 TR=$ac_cv_path_TR 5680 if test -n "$TR"; then 5681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 5682 $as_echo "$TR" >&6; } 5683 else 5684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5685 $as_echo "no" >&6; } 5686 fi 5687 5688 5689 test -n "$TR" && break 5690 done 5691 5692 5693 if test "x$TR" = x; then 5694 if test "xtr" = x; then 5695 PROG_NAME=tr 5696 else 5697 PROG_NAME=tr 5698 fi 5699 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5700 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5701 as_fn_error $? "Cannot continue" "$LINENO" 5 5702 fi 5703 5704 5705 5706 for ac_prog in uname 5707 do 5708 # Extract the first word of "$ac_prog", so it can be a program name with args. 5709 set dummy $ac_prog; ac_word=$2 5710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5711 $as_echo_n "checking for $ac_word... " >&6; } 5712 if ${ac_cv_path_UNAME+:} false; then : 5713 $as_echo_n "(cached) " >&6 5714 else 5715 case $UNAME in 5716 [\\/]* | ?:[\\/]*) 5717 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 5718 ;; 5719 *) 5720 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5721 for as_dir in $PATH 5722 do 5723 IFS=$as_save_IFS 5724 test -z "$as_dir" && as_dir=. 5725 for ac_exec_ext in '' $ac_executable_extensions; do 5726 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5727 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 5728 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5729 break 2 5730 fi 5731 done 5732 done 5733 IFS=$as_save_IFS 5734 5735 ;; 5736 esac 5737 fi 5738 UNAME=$ac_cv_path_UNAME 5739 if test -n "$UNAME"; then 5740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 5741 $as_echo "$UNAME" >&6; } 5742 else 5743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5744 $as_echo "no" >&6; } 5745 fi 5746 5747 5748 test -n "$UNAME" && break 5749 done 5750 5751 5752 if test "x$UNAME" = x; then 5753 if test "xuname" = x; then 5754 PROG_NAME=uname 5755 else 5756 PROG_NAME=uname 5757 fi 5758 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5759 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5760 as_fn_error $? "Cannot continue" "$LINENO" 5 5761 fi 5762 5763 5764 5765 for ac_prog in uniq 5766 do 5767 # Extract the first word of "$ac_prog", so it can be a program name with args. 5768 set dummy $ac_prog; ac_word=$2 5769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5770 $as_echo_n "checking for $ac_word... " >&6; } 5771 if ${ac_cv_path_UNIQ+:} false; then : 5772 $as_echo_n "(cached) " >&6 5773 else 5774 case $UNIQ in 5775 [\\/]* | ?:[\\/]*) 5776 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 5777 ;; 5778 *) 5779 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5780 for as_dir in $PATH 5781 do 5782 IFS=$as_save_IFS 5783 test -z "$as_dir" && as_dir=. 5784 for ac_exec_ext in '' $ac_executable_extensions; do 5785 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5786 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 5787 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5788 break 2 5789 fi 5790 done 5791 done 5792 IFS=$as_save_IFS 5793 5794 ;; 5795 esac 5796 fi 5797 UNIQ=$ac_cv_path_UNIQ 5798 if test -n "$UNIQ"; then 5799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 5800 $as_echo "$UNIQ" >&6; } 5801 else 5802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5803 $as_echo "no" >&6; } 5804 fi 5805 5806 5807 test -n "$UNIQ" && break 5808 done 5809 5810 5811 if test "x$UNIQ" = x; then 5812 if test "xuniq" = x; then 5813 PROG_NAME=uniq 5814 else 5815 PROG_NAME=uniq 5816 fi 5817 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5818 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5819 as_fn_error $? "Cannot continue" "$LINENO" 5 5820 fi 5821 5822 5823 5824 for ac_prog in wc 5825 do 5826 # Extract the first word of "$ac_prog", so it can be a program name with args. 5827 set dummy $ac_prog; ac_word=$2 5828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5829 $as_echo_n "checking for $ac_word... " >&6; } 5830 if ${ac_cv_path_WC+:} false; then : 5831 $as_echo_n "(cached) " >&6 5832 else 5833 case $WC in 5834 [\\/]* | ?:[\\/]*) 5835 ac_cv_path_WC="$WC" # Let the user override the test with a path. 5836 ;; 5837 *) 5838 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5839 for as_dir in $PATH 5840 do 5841 IFS=$as_save_IFS 5842 test -z "$as_dir" && as_dir=. 5843 for ac_exec_ext in '' $ac_executable_extensions; do 5844 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5845 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 5846 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5847 break 2 5848 fi 5849 done 5850 done 5851 IFS=$as_save_IFS 5852 5853 ;; 5854 esac 5855 fi 5856 WC=$ac_cv_path_WC 5857 if test -n "$WC"; then 5858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 5859 $as_echo "$WC" >&6; } 5860 else 5861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5862 $as_echo "no" >&6; } 5863 fi 5864 5865 5866 test -n "$WC" && break 5867 done 5868 5869 5870 if test "x$WC" = x; then 5871 if test "xwc" = x; then 5872 PROG_NAME=wc 5873 else 5874 PROG_NAME=wc 5875 fi 5876 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5877 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5878 as_fn_error $? "Cannot continue" "$LINENO" 5 5879 fi 5880 5881 5882 5883 for ac_prog in which 5884 do 5885 # Extract the first word of "$ac_prog", so it can be a program name with args. 5886 set dummy $ac_prog; ac_word=$2 5887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5888 $as_echo_n "checking for $ac_word... " >&6; } 5889 if ${ac_cv_path_WHICH+:} false; then : 5890 $as_echo_n "(cached) " >&6 5891 else 5892 case $WHICH in 5893 [\\/]* | ?:[\\/]*) 5894 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 5895 ;; 5896 *) 5897 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5898 for as_dir in $PATH 5899 do 5900 IFS=$as_save_IFS 5901 test -z "$as_dir" && as_dir=. 5902 for ac_exec_ext in '' $ac_executable_extensions; do 5903 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5904 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 5905 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5906 break 2 5907 fi 5908 done 5909 done 5910 IFS=$as_save_IFS 5911 5912 ;; 5913 esac 5914 fi 5915 WHICH=$ac_cv_path_WHICH 5916 if test -n "$WHICH"; then 5917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 5918 $as_echo "$WHICH" >&6; } 5919 else 5920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5921 $as_echo "no" >&6; } 5922 fi 5923 5924 5925 test -n "$WHICH" && break 5926 done 5927 5928 5929 if test "x$WHICH" = x; then 5930 if test "xwhich" = x; then 5931 PROG_NAME=which 5932 else 5933 PROG_NAME=which 5934 fi 5935 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5936 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5937 as_fn_error $? "Cannot continue" "$LINENO" 5 5938 fi 5939 5940 5941 5942 for ac_prog in xargs 5943 do 5944 # Extract the first word of "$ac_prog", so it can be a program name with args. 5945 set dummy $ac_prog; ac_word=$2 5946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5947 $as_echo_n "checking for $ac_word... " >&6; } 5948 if ${ac_cv_path_XARGS+:} false; then : 5949 $as_echo_n "(cached) " >&6 5950 else 5951 case $XARGS in 5952 [\\/]* | ?:[\\/]*) 5953 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 5954 ;; 5955 *) 5956 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5957 for as_dir in $PATH 5958 do 5959 IFS=$as_save_IFS 5960 test -z "$as_dir" && as_dir=. 5961 for ac_exec_ext in '' $ac_executable_extensions; do 5962 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5963 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 5964 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5965 break 2 5966 fi 5967 done 5968 done 5969 IFS=$as_save_IFS 5970 5971 ;; 5972 esac 5973 fi 5974 XARGS=$ac_cv_path_XARGS 5975 if test -n "$XARGS"; then 5976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 5977 $as_echo "$XARGS" >&6; } 5978 else 5979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5980 $as_echo "no" >&6; } 5981 fi 5982 5983 5984 test -n "$XARGS" && break 5985 done 5986 5987 5988 if test "x$XARGS" = x; then 5989 if test "xxargs" = x; then 5990 PROG_NAME=xargs 5991 else 5992 PROG_NAME=xargs 5993 fi 5994 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5995 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5996 as_fn_error $? "Cannot continue" "$LINENO" 5 5997 fi 5998 5999 6000 6001 # Then required tools that require some special treatment. 6002 for ac_prog in gawk mawk nawk awk 6003 do 6004 # Extract the first word of "$ac_prog", so it can be a program name with args. 6005 set dummy $ac_prog; ac_word=$2 6006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6007 $as_echo_n "checking for $ac_word... " >&6; } 6008 if ${ac_cv_prog_AWK+:} false; then : 6009 $as_echo_n "(cached) " >&6 6010 else 6011 if test -n "$AWK"; then 6012 ac_cv_prog_AWK="$AWK" # Let the user override the test. 6013 else 6014 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6015 for as_dir in $PATH 6016 do 6017 IFS=$as_save_IFS 6018 test -z "$as_dir" && as_dir=. 6019 for ac_exec_ext in '' $ac_executable_extensions; do 6020 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6021 ac_cv_prog_AWK="$ac_prog" 6022 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6023 break 2 6024 fi 6025 done 6026 done 6027 IFS=$as_save_IFS 6028 6029 fi 6030 fi 6031 AWK=$ac_cv_prog_AWK 6032 if test -n "$AWK"; then 6033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 6034 $as_echo "$AWK" >&6; } 6035 else 6036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6037 $as_echo "no" >&6; } 6038 fi 6039 6040 6041 test -n "$AWK" && break 6042 done 6043 6044 6045 if test "x$AWK" = x; then 6046 if test "x" = x; then 6047 PROG_NAME=awk 6048 else 6049 PROG_NAME= 6050 fi 6051 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6052 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6053 as_fn_error $? "Cannot continue" "$LINENO" 5 6054 fi 6055 6056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 6057 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 6058 if ${ac_cv_path_GREP+:} false; then : 6059 $as_echo_n "(cached) " >&6 6060 else 6061 if test -z "$GREP"; then 6062 ac_path_GREP_found=false 6063 # Loop through the user's path and test for each of PROGNAME-LIST 6064 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6065 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 6066 do 6067 IFS=$as_save_IFS 6068 test -z "$as_dir" && as_dir=. 6069 for ac_prog in grep ggrep; do 6070 for ac_exec_ext in '' $ac_executable_extensions; do 6071 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 6072 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue 6073 # Check for GNU ac_path_GREP and select it if it is found. 6074 # Check for GNU $ac_path_GREP 6075 case `"$ac_path_GREP" --version 2>&1` in 6076 *GNU*) 6077 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 6078 *) 6079 ac_count=0 6080 $as_echo_n 0123456789 >"conftest.in" 6081 while : 6082 do 6083 cat "conftest.in" "conftest.in" >"conftest.tmp" 6084 mv "conftest.tmp" "conftest.in" 6085 cp "conftest.in" "conftest.nl" 6086 $as_echo 'GREP' >> "conftest.nl" 6087 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 6088 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 6089 as_fn_arith $ac_count + 1 && ac_count=$as_val 6090 if test $ac_count -gt ${ac_path_GREP_max-0}; then 6091 # Best one so far, save it but keep looking for a better one 6092 ac_cv_path_GREP="$ac_path_GREP" 6093 ac_path_GREP_max=$ac_count 6094 fi 6095 # 10*(2^10) chars as input seems more than enough 6096 test $ac_count -gt 10 && break 6097 done 6098 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 6099 esac 6100 6101 $ac_path_GREP_found && break 3 6102 done 6103 done 6104 done 6105 IFS=$as_save_IFS 6106 if test -z "$ac_cv_path_GREP"; then 6107 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 6108 fi 6109 else 6110 ac_cv_path_GREP=$GREP 6111 fi 6112 6113 fi 6114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 6115 $as_echo "$ac_cv_path_GREP" >&6; } 6116 GREP="$ac_cv_path_GREP" 6117 6118 6119 6120 if test "x$GREP" = x; then 6121 if test "x" = x; then 6122 PROG_NAME=grep 6123 else 6124 PROG_NAME= 6125 fi 6126 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6127 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6128 as_fn_error $? "Cannot continue" "$LINENO" 5 6129 fi 6130 6131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 6132 $as_echo_n "checking for egrep... " >&6; } 6133 if ${ac_cv_path_EGREP+:} false; then : 6134 $as_echo_n "(cached) " >&6 6135 else 6136 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 6137 then ac_cv_path_EGREP="$GREP -E" 6138 else 6139 if test -z "$EGREP"; then 6140 ac_path_EGREP_found=false 6141 # Loop through the user's path and test for each of PROGNAME-LIST 6142 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6143 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 6144 do 6145 IFS=$as_save_IFS 6146 test -z "$as_dir" && as_dir=. 6147 for ac_prog in egrep; do 6148 for ac_exec_ext in '' $ac_executable_extensions; do 6149 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 6150 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue 6151 # Check for GNU ac_path_EGREP and select it if it is found. 6152 # Check for GNU $ac_path_EGREP 6153 case `"$ac_path_EGREP" --version 2>&1` in 6154 *GNU*) 6155 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 6156 *) 6157 ac_count=0 6158 $as_echo_n 0123456789 >"conftest.in" 6159 while : 6160 do 6161 cat "conftest.in" "conftest.in" >"conftest.tmp" 6162 mv "conftest.tmp" "conftest.in" 6163 cp "conftest.in" "conftest.nl" 6164 $as_echo 'EGREP' >> "conftest.nl" 6165 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 6166 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 6167 as_fn_arith $ac_count + 1 && ac_count=$as_val 6168 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 6169 # Best one so far, save it but keep looking for a better one 6170 ac_cv_path_EGREP="$ac_path_EGREP" 6171 ac_path_EGREP_max=$ac_count 6172 fi 6173 # 10*(2^10) chars as input seems more than enough 6174 test $ac_count -gt 10 && break 6175 done 6176 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 6177 esac 6178 6179 $ac_path_EGREP_found && break 3 6180 done 6181 done 6182 done 6183 IFS=$as_save_IFS 6184 if test -z "$ac_cv_path_EGREP"; then 6185 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 6186 fi 6187 else 6188 ac_cv_path_EGREP=$EGREP 6189 fi 6190 6191 fi 6192 fi 6193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 6194 $as_echo "$ac_cv_path_EGREP" >&6; } 6195 EGREP="$ac_cv_path_EGREP" 6196 6197 6198 6199 if test "x$EGREP" = x; then 6200 if test "x" = x; then 6201 PROG_NAME=egrep 6202 else 6203 PROG_NAME= 6204 fi 6205 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6206 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6207 as_fn_error $? "Cannot continue" "$LINENO" 5 6208 fi 6209 6210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 6211 $as_echo_n "checking for fgrep... " >&6; } 6212 if ${ac_cv_path_FGREP+:} false; then : 6213 $as_echo_n "(cached) " >&6 6214 else 6215 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 6216 then ac_cv_path_FGREP="$GREP -F" 6217 else 6218 if test -z "$FGREP"; then 6219 ac_path_FGREP_found=false 6220 # Loop through the user's path and test for each of PROGNAME-LIST 6221 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6222 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 6223 do 6224 IFS=$as_save_IFS 6225 test -z "$as_dir" && as_dir=. 6226 for ac_prog in fgrep; do 6227 for ac_exec_ext in '' $ac_executable_extensions; do 6228 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 6229 { test -f "$ac_path_FGREP" && $as_test_x "$ac_path_FGREP"; } || continue 6230 # Check for GNU ac_path_FGREP and select it if it is found. 6231 # Check for GNU $ac_path_FGREP 6232 case `"$ac_path_FGREP" --version 2>&1` in 6233 *GNU*) 6234 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 6235 *) 6236 ac_count=0 6237 $as_echo_n 0123456789 >"conftest.in" 6238 while : 6239 do 6240 cat "conftest.in" "conftest.in" >"conftest.tmp" 6241 mv "conftest.tmp" "conftest.in" 6242 cp "conftest.in" "conftest.nl" 6243 $as_echo 'FGREP' >> "conftest.nl" 6244 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 6245 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 6246 as_fn_arith $ac_count + 1 && ac_count=$as_val 6247 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 6248 # Best one so far, save it but keep looking for a better one 6249 ac_cv_path_FGREP="$ac_path_FGREP" 6250 ac_path_FGREP_max=$ac_count 6251 fi 6252 # 10*(2^10) chars as input seems more than enough 6253 test $ac_count -gt 10 && break 6254 done 6255 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 6256 esac 6257 6258 $ac_path_FGREP_found && break 3 6259 done 6260 done 6261 done 6262 IFS=$as_save_IFS 6263 if test -z "$ac_cv_path_FGREP"; then 6264 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 6265 fi 6266 else 6267 ac_cv_path_FGREP=$FGREP 6268 fi 6269 6270 fi 6271 fi 6272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 6273 $as_echo "$ac_cv_path_FGREP" >&6; } 6274 FGREP="$ac_cv_path_FGREP" 6275 6276 6277 6278 if test "x$FGREP" = x; then 6279 if test "x" = x; then 6280 PROG_NAME=fgrep 6281 else 6282 PROG_NAME= 6283 fi 6284 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6285 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6286 as_fn_error $? "Cannot continue" "$LINENO" 5 6287 fi 6288 6289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 6290 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 6291 if ${ac_cv_path_SED+:} false; then : 6292 $as_echo_n "(cached) " >&6 6293 else 6294 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 6295 for ac_i in 1 2 3 4 5 6 7; do 6296 ac_script="$ac_script$as_nl$ac_script" 6297 done 6298 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 6299 { ac_script=; unset ac_script;} 6300 if test -z "$SED"; then 6301 ac_path_SED_found=false 6302 # Loop through the user's path and test for each of PROGNAME-LIST 6303 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6304 for as_dir in $PATH 6305 do 6306 IFS=$as_save_IFS 6307 test -z "$as_dir" && as_dir=. 6308 for ac_prog in sed gsed; do 6309 for ac_exec_ext in '' $ac_executable_extensions; do 6310 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 6311 { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue 6312 # Check for GNU ac_path_SED and select it if it is found. 6313 # Check for GNU $ac_path_SED 6314 case `"$ac_path_SED" --version 2>&1` in 6315 *GNU*) 6316 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 6317 *) 6318 ac_count=0 6319 $as_echo_n 0123456789 >"conftest.in" 6320 while : 6321 do 6322 cat "conftest.in" "conftest.in" >"conftest.tmp" 6323 mv "conftest.tmp" "conftest.in" 6324 cp "conftest.in" "conftest.nl" 6325 $as_echo '' >> "conftest.nl" 6326 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 6327 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 6328 as_fn_arith $ac_count + 1 && ac_count=$as_val 6329 if test $ac_count -gt ${ac_path_SED_max-0}; then 6330 # Best one so far, save it but keep looking for a better one 6331 ac_cv_path_SED="$ac_path_SED" 6332 ac_path_SED_max=$ac_count 6333 fi 6334 # 10*(2^10) chars as input seems more than enough 6335 test $ac_count -gt 10 && break 6336 done 6337 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 6338 esac 6339 6340 $ac_path_SED_found && break 3 6341 done 6342 done 6343 done 6344 IFS=$as_save_IFS 6345 if test -z "$ac_cv_path_SED"; then 6346 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 6347 fi 6348 else 6349 ac_cv_path_SED=$SED 6350 fi 6351 6352 fi 6353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 6354 $as_echo "$ac_cv_path_SED" >&6; } 6355 SED="$ac_cv_path_SED" 6356 rm -f conftest.sed 6357 6358 6359 if test "x$SED" = x; then 6360 if test "x" = x; then 6361 PROG_NAME=sed 6362 else 6363 PROG_NAME= 6364 fi 6365 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6366 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6367 as_fn_error $? "Cannot continue" "$LINENO" 5 6368 fi 6369 6370 6371 for ac_prog in nawk gawk awk 6372 do 6373 # Extract the first word of "$ac_prog", so it can be a program name with args. 6374 set dummy $ac_prog; ac_word=$2 6375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6376 $as_echo_n "checking for $ac_word... " >&6; } 6377 if ${ac_cv_path_NAWK+:} false; then : 6378 $as_echo_n "(cached) " >&6 6379 else 6380 case $NAWK in 6381 [\\/]* | ?:[\\/]*) 6382 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 6383 ;; 6384 *) 6385 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6386 for as_dir in $PATH 6387 do 6388 IFS=$as_save_IFS 6389 test -z "$as_dir" && as_dir=. 6390 for ac_exec_ext in '' $ac_executable_extensions; do 6391 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6392 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 6393 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6394 break 2 6395 fi 6396 done 6397 done 6398 IFS=$as_save_IFS 6399 6400 ;; 6401 esac 6402 fi 6403 NAWK=$ac_cv_path_NAWK 6404 if test -n "$NAWK"; then 6405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 6406 $as_echo "$NAWK" >&6; } 6407 else 6408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6409 $as_echo "no" >&6; } 6410 fi 6411 6412 6413 test -n "$NAWK" && break 6414 done 6415 6416 6417 if test "x$NAWK" = x; then 6418 if test "x" = x; then 6419 PROG_NAME=nawk 6420 else 6421 PROG_NAME= 6422 fi 6423 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6424 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6425 as_fn_error $? "Cannot continue" "$LINENO" 5 6426 fi 6427 6428 6429 # Always force rm. 6430 RM="$RM -f" 6431 6432 # These are not required on all platforms 6433 # Extract the first word of "cygpath", so it can be a program name with args. 6434 set dummy cygpath; ac_word=$2 6435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6436 $as_echo_n "checking for $ac_word... " >&6; } 6437 if ${ac_cv_path_CYGPATH+:} false; then : 6438 $as_echo_n "(cached) " >&6 6439 else 6440 case $CYGPATH in 6441 [\\/]* | ?:[\\/]*) 6442 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 6443 ;; 6444 *) 6445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6446 for as_dir in $PATH 6447 do 6448 IFS=$as_save_IFS 6449 test -z "$as_dir" && as_dir=. 6450 for ac_exec_ext in '' $ac_executable_extensions; do 6451 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6452 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 6453 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6454 break 2 6455 fi 6456 done 6457 done 6458 IFS=$as_save_IFS 6459 6460 ;; 6461 esac 6462 fi 6463 CYGPATH=$ac_cv_path_CYGPATH 6464 if test -n "$CYGPATH"; then 6465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 6466 $as_echo "$CYGPATH" >&6; } 6467 else 6468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6469 $as_echo "no" >&6; } 6470 fi 6471 6472 6473 # Extract the first word of "readlink", so it can be a program name with args. 6474 set dummy readlink; ac_word=$2 6475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6476 $as_echo_n "checking for $ac_word... " >&6; } 6477 if ${ac_cv_path_READLINK+:} false; then : 6478 $as_echo_n "(cached) " >&6 6479 else 6480 case $READLINK in 6481 [\\/]* | ?:[\\/]*) 6482 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 6483 ;; 6484 *) 6485 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6486 for as_dir in $PATH 6487 do 6488 IFS=$as_save_IFS 6489 test -z "$as_dir" && as_dir=. 6490 for ac_exec_ext in '' $ac_executable_extensions; do 6491 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6492 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 6493 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6494 break 2 6495 fi 6496 done 6497 done 6498 IFS=$as_save_IFS 6499 6500 ;; 6501 esac 6502 fi 6503 READLINK=$ac_cv_path_READLINK 6504 if test -n "$READLINK"; then 6505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 6506 $as_echo "$READLINK" >&6; } 6507 else 6508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6509 $as_echo "no" >&6; } 6510 fi 6511 6512 6513 # Extract the first word of "df", so it can be a program name with args. 6514 set dummy df; ac_word=$2 6515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6516 $as_echo_n "checking for $ac_word... " >&6; } 6517 if ${ac_cv_path_DF+:} false; then : 6518 $as_echo_n "(cached) " >&6 6519 else 6520 case $DF in 6521 [\\/]* | ?:[\\/]*) 6522 ac_cv_path_DF="$DF" # Let the user override the test with a path. 6523 ;; 6524 *) 6525 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6526 for as_dir in $PATH 6527 do 6528 IFS=$as_save_IFS 6529 test -z "$as_dir" && as_dir=. 6530 for ac_exec_ext in '' $ac_executable_extensions; do 6531 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6532 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 6533 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6534 break 2 6535 fi 6536 done 6537 done 6538 IFS=$as_save_IFS 6539 6540 ;; 6541 esac 6542 fi 6543 DF=$ac_cv_path_DF 6544 if test -n "$DF"; then 6545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 6546 $as_echo "$DF" >&6; } 6547 else 6548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6549 $as_echo "no" >&6; } 6550 fi 6551 6552 6553 # Extract the first word of "SetFile", so it can be a program name with args. 6554 set dummy SetFile; ac_word=$2 6555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6556 $as_echo_n "checking for $ac_word... " >&6; } 6557 if ${ac_cv_path_SETFILE+:} false; then : 6558 $as_echo_n "(cached) " >&6 6559 else 6560 case $SETFILE in 6561 [\\/]* | ?:[\\/]*) 6562 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 6563 ;; 6564 *) 6565 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6566 for as_dir in $PATH 6567 do 6568 IFS=$as_save_IFS 6569 test -z "$as_dir" && as_dir=. 6570 for ac_exec_ext in '' $ac_executable_extensions; do 6571 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6572 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 6573 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6574 break 2 6575 fi 6576 done 6577 done 6578 IFS=$as_save_IFS 6579 6580 ;; 6581 esac 6582 fi 6583 SETFILE=$ac_cv_path_SETFILE 6584 if test -n "$SETFILE"; then 6585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 6586 $as_echo "$SETFILE" >&6; } 6587 else 6588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6589 $as_echo "no" >&6; } 6590 fi 6591 6592 6593 6594 6595 # Now we can determine OpenJDK build and target platforms. This is required to 6596 # have early on. 6597 # Make sure we can run config.sub. 6598 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 6599 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 6600 6601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 6602 $as_echo_n "checking build system type... " >&6; } 6603 if ${ac_cv_build+:} false; then : 6604 $as_echo_n "(cached) " >&6 6605 else 6606 ac_build_alias=$build_alias 6607 test "x$ac_build_alias" = x && 6608 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 6609 test "x$ac_build_alias" = x && 6610 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 6611 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 6612 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 6613 6614 fi 6615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 6616 $as_echo "$ac_cv_build" >&6; } 6617 case $ac_cv_build in 6618 *-*-*) ;; 6619 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 6620 esac 6621 build=$ac_cv_build 6622 ac_save_IFS=$IFS; IFS='-' 6623 set x $ac_cv_build 6624 shift 6625 build_cpu=$1 6626 build_vendor=$2 6627 shift; shift 6628 # Remember, the first character of IFS is used to create $*, 6629 # except with old shells: 6630 build_os=$* 6631 IFS=$ac_save_IFS 6632 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 6633 6634 6635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 6636 $as_echo_n "checking host system type... " >&6; } 6637 if ${ac_cv_host+:} false; then : 6638 $as_echo_n "(cached) " >&6 6639 else 6640 if test "x$host_alias" = x; then 6641 ac_cv_host=$ac_cv_build 6642 else 6643 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 6644 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 6645 fi 6646 6647 fi 6648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 6649 $as_echo "$ac_cv_host" >&6; } 6650 case $ac_cv_host in 6651 *-*-*) ;; 6652 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 6653 esac 6654 host=$ac_cv_host 6655 ac_save_IFS=$IFS; IFS='-' 6656 set x $ac_cv_host 6657 shift 6658 host_cpu=$1 6659 host_vendor=$2 6660 shift; shift 6661 # Remember, the first character of IFS is used to create $*, 6662 # except with old shells: 6663 host_os=$* 6664 IFS=$ac_save_IFS 6665 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 6666 6667 6668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 6669 $as_echo_n "checking target system type... " >&6; } 6670 if ${ac_cv_target+:} false; then : 6671 $as_echo_n "(cached) " >&6 6672 else 6673 if test "x$target_alias" = x; then 6674 ac_cv_target=$ac_cv_host 6675 else 6676 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 6677 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 6678 fi 6679 6680 fi 6681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 6682 $as_echo "$ac_cv_target" >&6; } 6683 case $ac_cv_target in 6684 *-*-*) ;; 6685 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 6686 esac 6687 target=$ac_cv_target 6688 ac_save_IFS=$IFS; IFS='-' 6689 set x $ac_cv_target 6690 shift 6691 target_cpu=$1 6692 target_vendor=$2 6693 shift; shift 6694 # Remember, the first character of IFS is used to create $*, 6695 # except with old shells: 6696 target_os=$* 6697 IFS=$ac_save_IFS 6698 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac 6699 6700 6701 # The aliases save the names the user supplied, while $host etc. 6702 # will get canonicalized. 6703 test -n "$target_alias" && 6704 test "$program_prefix$program_suffix$program_transform_name" = \ 6705 NONENONEs,x,x, && 6706 program_prefix=${target_alias}- 6707 ac_ext=c 6708 ac_cpp='$CPP $CPPFLAGS' 6709 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 6710 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 6711 ac_compiler_gnu=$ac_cv_c_compiler_gnu 6712 if test -n "$ac_tool_prefix"; then 6713 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. 6714 set dummy ${ac_tool_prefix}gcc; ac_word=$2 6715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6716 $as_echo_n "checking for $ac_word... " >&6; } 6717 if ${ac_cv_prog_CC+:} false; then : 6718 $as_echo_n "(cached) " >&6 6719 else 6720 if test -n "$CC"; then 6721 ac_cv_prog_CC="$CC" # Let the user override the test. 6722 else 6723 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6724 for as_dir in $PATH 6725 do 6726 IFS=$as_save_IFS 6727 test -z "$as_dir" && as_dir=. 6728 for ac_exec_ext in '' $ac_executable_extensions; do 6729 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6730 ac_cv_prog_CC="${ac_tool_prefix}gcc" 6731 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6732 break 2 6733 fi 6734 done 6735 done 6736 IFS=$as_save_IFS 6737 6738 fi 6739 fi 6740 CC=$ac_cv_prog_CC 6741 if test -n "$CC"; then 6742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 6743 $as_echo "$CC" >&6; } 6744 else 6745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6746 $as_echo "no" >&6; } 6747 fi 6748 6749 6750 fi 6751 if test -z "$ac_cv_prog_CC"; then 6752 ac_ct_CC=$CC 6753 # Extract the first word of "gcc", so it can be a program name with args. 6754 set dummy gcc; ac_word=$2 6755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6756 $as_echo_n "checking for $ac_word... " >&6; } 6757 if ${ac_cv_prog_ac_ct_CC+:} false; then : 6758 $as_echo_n "(cached) " >&6 6759 else 6760 if test -n "$ac_ct_CC"; then 6761 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 6762 else 6763 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6764 for as_dir in $PATH 6765 do 6766 IFS=$as_save_IFS 6767 test -z "$as_dir" && as_dir=. 6768 for ac_exec_ext in '' $ac_executable_extensions; do 6769 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6770 ac_cv_prog_ac_ct_CC="gcc" 6771 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6772 break 2 6773 fi 6774 done 6775 done 6776 IFS=$as_save_IFS 6777 6778 fi 6779 fi 6780 ac_ct_CC=$ac_cv_prog_ac_ct_CC 6781 if test -n "$ac_ct_CC"; then 6782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 6783 $as_echo "$ac_ct_CC" >&6; } 6784 else 6785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6786 $as_echo "no" >&6; } 6787 fi 6788 6789 if test "x$ac_ct_CC" = x; then 6790 CC="" 6791 else 6792 case $cross_compiling:$ac_tool_warned in 6793 yes:) 6794 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 6795 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 6796 ac_tool_warned=yes ;; 6797 esac 6798 CC=$ac_ct_CC 6799 fi 6800 else 6801 CC="$ac_cv_prog_CC" 6802 fi 6803 6804 if test -z "$CC"; then 6805 if test -n "$ac_tool_prefix"; then 6806 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. 6807 set dummy ${ac_tool_prefix}cc; ac_word=$2 6808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6809 $as_echo_n "checking for $ac_word... " >&6; } 6810 if ${ac_cv_prog_CC+:} false; then : 6811 $as_echo_n "(cached) " >&6 6812 else 6813 if test -n "$CC"; then 6814 ac_cv_prog_CC="$CC" # Let the user override the test. 6815 else 6816 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6817 for as_dir in $PATH 6818 do 6819 IFS=$as_save_IFS 6820 test -z "$as_dir" && as_dir=. 6821 for ac_exec_ext in '' $ac_executable_extensions; do 6822 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6823 ac_cv_prog_CC="${ac_tool_prefix}cc" 6824 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6825 break 2 6826 fi 6827 done 6828 done 6829 IFS=$as_save_IFS 6830 6831 fi 6832 fi 6833 CC=$ac_cv_prog_CC 6834 if test -n "$CC"; then 6835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 6836 $as_echo "$CC" >&6; } 6837 else 6838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6839 $as_echo "no" >&6; } 6840 fi 6841 6842 6843 fi 6844 fi 6845 if test -z "$CC"; then 6846 # Extract the first word of "cc", so it can be a program name with args. 6847 set dummy cc; ac_word=$2 6848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6849 $as_echo_n "checking for $ac_word... " >&6; } 6850 if ${ac_cv_prog_CC+:} false; then : 6851 $as_echo_n "(cached) " >&6 6852 else 6853 if test -n "$CC"; then 6854 ac_cv_prog_CC="$CC" # Let the user override the test. 6855 else 6856 ac_prog_rejected=no 6857 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6858 for as_dir in $PATH 6859 do 6860 IFS=$as_save_IFS 6861 test -z "$as_dir" && as_dir=. 6862 for ac_exec_ext in '' $ac_executable_extensions; do 6863 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6864 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then 6865 ac_prog_rejected=yes 6866 continue 6867 fi 6868 ac_cv_prog_CC="cc" 6869 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6870 break 2 6871 fi 6872 done 6873 done 6874 IFS=$as_save_IFS 6875 6876 if test $ac_prog_rejected = yes; then 6877 # We found a bogon in the path, so make sure we never use it. 6878 set dummy $ac_cv_prog_CC 6879 shift 6880 if test $# != 0; then 6881 # We chose a different compiler from the bogus one. 6882 # However, it has the same basename, so the bogon will be chosen 6883 # first if we set CC to just the basename; use the full file name. 6884 shift 6885 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" 6886 fi 6887 fi 6888 fi 6889 fi 6890 CC=$ac_cv_prog_CC 6891 if test -n "$CC"; then 6892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 6893 $as_echo "$CC" >&6; } 6894 else 6895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6896 $as_echo "no" >&6; } 6897 fi 6898 6899 6900 fi 6901 if test -z "$CC"; then 6902 if test -n "$ac_tool_prefix"; then 6903 for ac_prog in cl.exe 6904 do 6905 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 6906 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 6907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6908 $as_echo_n "checking for $ac_word... " >&6; } 6909 if ${ac_cv_prog_CC+:} false; then : 6910 $as_echo_n "(cached) " >&6 6911 else 6912 if test -n "$CC"; then 6913 ac_cv_prog_CC="$CC" # Let the user override the test. 6914 else 6915 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6916 for as_dir in $PATH 6917 do 6918 IFS=$as_save_IFS 6919 test -z "$as_dir" && as_dir=. 6920 for ac_exec_ext in '' $ac_executable_extensions; do 6921 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6922 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 6923 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6924 break 2 6925 fi 6926 done 6927 done 6928 IFS=$as_save_IFS 6929 6930 fi 6931 fi 6932 CC=$ac_cv_prog_CC 6933 if test -n "$CC"; then 6934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 6935 $as_echo "$CC" >&6; } 6936 else 6937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6938 $as_echo "no" >&6; } 6939 fi 6940 6941 6942 test -n "$CC" && break 6943 done 6944 fi 6945 if test -z "$CC"; then 6946 ac_ct_CC=$CC 6947 for ac_prog in cl.exe 6948 do 6949 # Extract the first word of "$ac_prog", so it can be a program name with args. 6950 set dummy $ac_prog; ac_word=$2 6951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6952 $as_echo_n "checking for $ac_word... " >&6; } 6953 if ${ac_cv_prog_ac_ct_CC+:} false; then : 6954 $as_echo_n "(cached) " >&6 6955 else 6956 if test -n "$ac_ct_CC"; then 6957 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 6958 else 6959 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6960 for as_dir in $PATH 6961 do 6962 IFS=$as_save_IFS 6963 test -z "$as_dir" && as_dir=. 6964 for ac_exec_ext in '' $ac_executable_extensions; do 6965 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6966 ac_cv_prog_ac_ct_CC="$ac_prog" 6967 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6968 break 2 6969 fi 6970 done 6971 done 6972 IFS=$as_save_IFS 6973 6974 fi 6975 fi 6976 ac_ct_CC=$ac_cv_prog_ac_ct_CC 6977 if test -n "$ac_ct_CC"; then 6978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 6979 $as_echo "$ac_ct_CC" >&6; } 6980 else 6981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6982 $as_echo "no" >&6; } 6983 fi 6984 6985 6986 test -n "$ac_ct_CC" && break 6987 done 6988 6989 if test "x$ac_ct_CC" = x; then 6990 CC="" 6991 else 6992 case $cross_compiling:$ac_tool_warned in 6993 yes:) 6994 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 6995 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 6996 ac_tool_warned=yes ;; 6997 esac 6998 CC=$ac_ct_CC 6999 fi 7000 fi 7001 7002 fi 7003 7004 7005 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 7006 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 7007 as_fn_error $? "no acceptable C compiler found in \$PATH 7008 See \`config.log' for more details" "$LINENO" 5; } 7009 7010 # Provide some information about the compiler. 7011 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 7012 set X $ac_compile 7013 ac_compiler=$2 7014 for ac_option in --version -v -V -qversion; do 7015 { { ac_try="$ac_compiler $ac_option >&5" 7016 case "(($ac_try" in 7017 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 7018 *) ac_try_echo=$ac_try;; 7019 esac 7020 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 7021 $as_echo "$ac_try_echo"; } >&5 7022 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 7023 ac_status=$? 7024 if test -s conftest.err; then 7025 sed '10a\ 7026 ... rest of stderr output deleted ... 7027 10q' conftest.err >conftest.er1 7028 cat conftest.er1 >&5 7029 fi 7030 rm -f conftest.er1 conftest.err 7031 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 7032 test $ac_status = 0; } 7033 done 7034 7035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7036 /* end confdefs.h. */ 7037 7038 int 7039 main () 7040 { 7041 7042 ; 7043 return 0; 7044 } 7045 _ACEOF 7046 ac_clean_files_save=$ac_clean_files 7047 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 7048 # Try to create an executable without -o first, disregard a.out. 7049 # It will help us diagnose broken compilers, and finding out an intuition 7050 # of exeext. 7051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 7052 $as_echo_n "checking whether the C compiler works... " >&6; } 7053 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 7054 7055 # The possible output files: 7056 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 7057 7058 ac_rmfiles= 7059 for ac_file in $ac_files 7060 do 7061 case $ac_file in 7062 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 7063 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 7064 esac 7065 done 7066 rm -f $ac_rmfiles 7067 7068 if { { ac_try="$ac_link_default" 7069 case "(($ac_try" in 7070 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 7071 *) ac_try_echo=$ac_try;; 7072 esac 7073 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 7074 $as_echo "$ac_try_echo"; } >&5 7075 (eval "$ac_link_default") 2>&5 7076 ac_status=$? 7077 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 7078 test $ac_status = 0; }; then : 7079 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 7080 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 7081 # in a Makefile. We should not override ac_cv_exeext if it was cached, 7082 # so that the user can short-circuit this test for compilers unknown to 7083 # Autoconf. 7084 for ac_file in $ac_files '' 7085 do 7086 test -f "$ac_file" || continue 7087 case $ac_file in 7088 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 7089 ;; 7090 [ab].out ) 7091 # We found the default executable, but exeext='' is most 7092 # certainly right. 7093 break;; 7094 *.* ) 7095 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 7096 then :; else 7097 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 7098 fi 7099 # We set ac_cv_exeext here because the later test for it is not 7100 # safe: cross compilers may not add the suffix if given an `-o' 7101 # argument, so we may need to know it at that point already. 7102 # Even if this section looks crufty: it has the advantage of 7103 # actually working. 7104 break;; 7105 * ) 7106 break;; 7107 esac 7108 done 7109 test "$ac_cv_exeext" = no && ac_cv_exeext= 7110 7111 else 7112 ac_file='' 7113 fi 7114 if test -z "$ac_file"; then : 7115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7116 $as_echo "no" >&6; } 7117 $as_echo "$as_me: failed program was:" >&5 7118 sed 's/^/| /' conftest.$ac_ext >&5 7119 7120 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 7121 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 7122 as_fn_error 77 "C compiler cannot create executables 7123 See \`config.log' for more details" "$LINENO" 5; } 7124 else 7125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7126 $as_echo "yes" >&6; } 7127 fi 7128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 7129 $as_echo_n "checking for C compiler default output file name... " >&6; } 7130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 7131 $as_echo "$ac_file" >&6; } 7132 ac_exeext=$ac_cv_exeext 7133 7134 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 7135 ac_clean_files=$ac_clean_files_save 7136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 7137 $as_echo_n "checking for suffix of executables... " >&6; } 7138 if { { ac_try="$ac_link" 7139 case "(($ac_try" in 7140 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 7141 *) ac_try_echo=$ac_try;; 7142 esac 7143 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 7144 $as_echo "$ac_try_echo"; } >&5 7145 (eval "$ac_link") 2>&5 7146 ac_status=$? 7147 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 7148 test $ac_status = 0; }; then : 7149 # If both `conftest.exe' and `conftest' are `present' (well, observable) 7150 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 7151 # work properly (i.e., refer to `conftest.exe'), while it won't with 7152 # `rm'. 7153 for ac_file in conftest.exe conftest conftest.*; do 7154 test -f "$ac_file" || continue 7155 case $ac_file in 7156 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 7157 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 7158 break;; 7159 * ) break;; 7160 esac 7161 done 7162 else 7163 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 7164 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 7165 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 7166 See \`config.log' for more details" "$LINENO" 5; } 7167 fi 7168 rm -f conftest conftest$ac_cv_exeext 7169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 7170 $as_echo "$ac_cv_exeext" >&6; } 7171 7172 rm -f conftest.$ac_ext 7173 EXEEXT=$ac_cv_exeext 7174 ac_exeext=$EXEEXT 7175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7176 /* end confdefs.h. */ 7177 #include <stdio.h> 7178 int 7179 main () 7180 { 7181 FILE *f = fopen ("conftest.out", "w"); 7182 return ferror (f) || fclose (f) != 0; 7183 7184 ; 7185 return 0; 7186 } 7187 _ACEOF 7188 ac_clean_files="$ac_clean_files conftest.out" 7189 # Check that the compiler produces executables we can run. If not, either 7190 # the compiler is broken, or we cross compile. 7191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 7192 $as_echo_n "checking whether we are cross compiling... " >&6; } 7193 if test "$cross_compiling" != yes; then 7194 { { ac_try="$ac_link" 7195 case "(($ac_try" in 7196 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 7197 *) ac_try_echo=$ac_try;; 7198 esac 7199 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 7200 $as_echo "$ac_try_echo"; } >&5 7201 (eval "$ac_link") 2>&5 7202 ac_status=$? 7203 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 7204 test $ac_status = 0; } 7205 if { ac_try='./conftest$ac_cv_exeext' 7206 { { case "(($ac_try" in 7207 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 7208 *) ac_try_echo=$ac_try;; 7209 esac 7210 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 7211 $as_echo "$ac_try_echo"; } >&5 7212 (eval "$ac_try") 2>&5 7213 ac_status=$? 7214 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 7215 test $ac_status = 0; }; }; then 7216 cross_compiling=no 7217 else 7218 if test "$cross_compiling" = maybe; then 7219 cross_compiling=yes 7220 else 7221 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 7222 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 7223 as_fn_error $? "cannot run C compiled programs. 7224 If you meant to cross compile, use \`--host'. 7225 See \`config.log' for more details" "$LINENO" 5; } 7226 fi 7227 fi 7228 fi 7229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 7230 $as_echo "$cross_compiling" >&6; } 7231 7232 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 7233 ac_clean_files=$ac_clean_files_save 7234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 7235 $as_echo_n "checking for suffix of object files... " >&6; } 7236 if ${ac_cv_objext+:} false; then : 7237 $as_echo_n "(cached) " >&6 7238 else 7239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7240 /* end confdefs.h. */ 7241 7242 int 7243 main () 7244 { 7245 7246 ; 7247 return 0; 7248 } 7249 _ACEOF 7250 rm -f conftest.o conftest.obj 7251 if { { ac_try="$ac_compile" 7252 case "(($ac_try" in 7253 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 7254 *) ac_try_echo=$ac_try;; 7255 esac 7256 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 7257 $as_echo "$ac_try_echo"; } >&5 7258 (eval "$ac_compile") 2>&5 7259 ac_status=$? 7260 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 7261 test $ac_status = 0; }; then : 7262 for ac_file in conftest.o conftest.obj conftest.*; do 7263 test -f "$ac_file" || continue; 7264 case $ac_file in 7265 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 7266 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 7267 break;; 7268 esac 7269 done 7270 else 7271 $as_echo "$as_me: failed program was:" >&5 7272 sed 's/^/| /' conftest.$ac_ext >&5 7273 7274 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 7275 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 7276 as_fn_error $? "cannot compute suffix of object files: cannot compile 7277 See \`config.log' for more details" "$LINENO" 5; } 7278 fi 7279 rm -f conftest.$ac_cv_objext conftest.$ac_ext 7280 fi 7281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 7282 $as_echo "$ac_cv_objext" >&6; } 7283 OBJEXT=$ac_cv_objext 7284 ac_objext=$OBJEXT 7285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 7286 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 7287 if ${ac_cv_c_compiler_gnu+:} false; then : 7288 $as_echo_n "(cached) " >&6 7289 else 7290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7291 /* end confdefs.h. */ 7292 7293 int 7294 main () 7295 { 7296 #ifndef __GNUC__ 7297 choke me 7298 #endif 7299 7300 ; 7301 return 0; 7302 } 7303 _ACEOF 7304 if ac_fn_c_try_compile "$LINENO"; then : 7305 ac_compiler_gnu=yes 7306 else 7307 ac_compiler_gnu=no 7308 fi 7309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 7310 ac_cv_c_compiler_gnu=$ac_compiler_gnu 7311 7312 fi 7313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 7314 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 7315 if test $ac_compiler_gnu = yes; then 7316 GCC=yes 7317 else 7318 GCC= 7319 fi 7320 ac_test_CFLAGS=${CFLAGS+set} 7321 ac_save_CFLAGS=$CFLAGS 7322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 7323 $as_echo_n "checking whether $CC accepts -g... " >&6; } 7324 if ${ac_cv_prog_cc_g+:} false; then : 7325 $as_echo_n "(cached) " >&6 7326 else 7327 ac_save_c_werror_flag=$ac_c_werror_flag 7328 ac_c_werror_flag=yes 7329 ac_cv_prog_cc_g=no 7330 CFLAGS="-g" 7331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7332 /* end confdefs.h. */ 7333 7334 int 7335 main () 7336 { 7337 7338 ; 7339 return 0; 7340 } 7341 _ACEOF 7342 if ac_fn_c_try_compile "$LINENO"; then : 7343 ac_cv_prog_cc_g=yes 7344 else 7345 CFLAGS="" 7346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7347 /* end confdefs.h. */ 7348 7349 int 7350 main () 7351 { 7352 7353 ; 7354 return 0; 7355 } 7356 _ACEOF 7357 if ac_fn_c_try_compile "$LINENO"; then : 7358 7359 else 7360 ac_c_werror_flag=$ac_save_c_werror_flag 7361 CFLAGS="-g" 7362 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7363 /* end confdefs.h. */ 7364 7365 int 7366 main () 7367 { 7368 7369 ; 7370 return 0; 7371 } 7372 _ACEOF 7373 if ac_fn_c_try_compile "$LINENO"; then : 7374 ac_cv_prog_cc_g=yes 7375 fi 7376 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 7377 fi 7378 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 7379 fi 7380 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 7381 ac_c_werror_flag=$ac_save_c_werror_flag 7382 fi 7383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 7384 $as_echo "$ac_cv_prog_cc_g" >&6; } 7385 if test "$ac_test_CFLAGS" = set; then 7386 CFLAGS=$ac_save_CFLAGS 7387 elif test $ac_cv_prog_cc_g = yes; then 7388 if test "$GCC" = yes; then 7389 CFLAGS="-g -O2" 7390 else 7391 CFLAGS="-g" 7392 fi 7393 else 7394 if test "$GCC" = yes; then 7395 CFLAGS="-O2" 7396 else 7397 CFLAGS= 7398 fi 7399 fi 7400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 7401 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 7402 if ${ac_cv_prog_cc_c89+:} false; then : 7403 $as_echo_n "(cached) " >&6 7404 else 7405 ac_cv_prog_cc_c89=no 7406 ac_save_CC=$CC 7407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7408 /* end confdefs.h. */ 7409 #include <stdarg.h> 7410 #include <stdio.h> 7411 #include <sys/types.h> 7412 #include <sys/stat.h> 7413 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 7414 struct buf { int x; }; 7415 FILE * (*rcsopen) (struct buf *, struct stat *, int); 7416 static char *e (p, i) 7417 char **p; 7418 int i; 7419 { 7420 return p[i]; 7421 } 7422 static char *f (char * (*g) (char **, int), char **p, ...) 7423 { 7424 char *s; 7425 va_list v; 7426 va_start (v,p); 7427 s = g (p, va_arg (v,int)); 7428 va_end (v); 7429 return s; 7430 } 7431 7432 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 7433 function prototypes and stuff, but not '\xHH' hex character constants. 7434 These don't provoke an error unfortunately, instead are silently treated 7435 as 'x'. The following induces an error, until -std is added to get 7436 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 7437 array size at least. It's necessary to write '\x00'==0 to get something 7438 that's true only with -std. */ 7439 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 7440 7441 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 7442 inside strings and character constants. */ 7443 #define FOO(x) 'x' 7444 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 7445 7446 int test (int i, double x); 7447 struct s1 {int (*f) (int a);}; 7448 struct s2 {int (*f) (double a);}; 7449 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 7450 int argc; 7451 char **argv; 7452 int 7453 main () 7454 { 7455 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 7456 ; 7457 return 0; 7458 } 7459 _ACEOF 7460 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 7461 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 7462 do 7463 CC="$ac_save_CC $ac_arg" 7464 if ac_fn_c_try_compile "$LINENO"; then : 7465 ac_cv_prog_cc_c89=$ac_arg 7466 fi 7467 rm -f core conftest.err conftest.$ac_objext 7468 test "x$ac_cv_prog_cc_c89" != "xno" && break 7469 done 7470 rm -f conftest.$ac_ext 7471 CC=$ac_save_CC 7472 7473 fi 7474 # AC_CACHE_VAL 7475 case "x$ac_cv_prog_cc_c89" in 7476 x) 7477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 7478 $as_echo "none needed" >&6; } ;; 7479 xno) 7480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 7481 $as_echo "unsupported" >&6; } ;; 7482 *) 7483 CC="$CC $ac_cv_prog_cc_c89" 7484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 7485 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 7486 esac 7487 if test "x$ac_cv_prog_cc_c89" != xno; then : 7488 7489 fi 7490 7491 ac_ext=c 7492 ac_cpp='$CPP $CPPFLAGS' 7493 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 7494 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 7495 ac_compiler_gnu=$ac_cv_c_compiler_gnu 7496 7497 7498 7499 # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target" 7500 # is confusing; it assumes you are cross-compiling a cross-compiler (!) and "target" is thus the target of the 7501 # product you're building. The target of this build is called "host". Since this is confusing to most people, we 7502 # have not adopted that system, but use "target" as the platform we are building for. In some places though we need 7503 # to use the configure naming style. 7504 7505 7506 7507 7508 7509 # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME 7510 # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME 7511 # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build, 7512 # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME. 7513 OPENJDK_TARGET_AUTOCONF_NAME="$host" 7514 OPENJDK_BUILD_AUTOCONF_NAME="$build" 7515 7516 7517 7518 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 7519 7520 case "$build_os" in 7521 *linux*) 7522 VAR_OS=linux 7523 VAR_OS_API=posix 7524 VAR_OS_ENV=linux 7525 ;; 7526 *solaris*) 7527 VAR_OS=solaris 7528 VAR_OS_API=posix 7529 VAR_OS_ENV=solaris 7530 ;; 7531 *darwin*) 7532 VAR_OS=macosx 7533 VAR_OS_API=posix 7534 VAR_OS_ENV=macosx 7535 ;; 7536 *bsd*) 7537 VAR_OS=bsd 7538 VAR_OS_API=posix 7539 VAR_OS_ENV=bsd 7540 ;; 7541 *cygwin*) 7542 VAR_OS=windows 7543 VAR_OS_API=winapi 7544 VAR_OS_ENV=windows.cygwin 7545 ;; 7546 *mingw*) 7547 VAR_OS=windows 7548 VAR_OS_API=winapi 7549 VAR_OS_ENV=windows.msys 7550 ;; 7551 *) 7552 as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5 7553 ;; 7554 esac 7555 7556 7557 # First argument is the cpu name from the trip/quad 7558 case "$build_cpu" in 7559 x86_64) 7560 VAR_CPU=x86_64 7561 VAR_CPU_ARCH=x86 7562 VAR_CPU_BITS=64 7563 VAR_CPU_ENDIAN=little 7564 ;; 7565 i?86) 7566 VAR_CPU=x86 7567 VAR_CPU_ARCH=x86 7568 VAR_CPU_BITS=32 7569 VAR_CPU_ENDIAN=little 7570 ;; 7571 arm*) 7572 VAR_CPU=arm 7573 VAR_CPU_ARCH=arm 7574 VAR_CPU_BITS=32 7575 VAR_CPU_ENDIAN=little 7576 ;; 7577 powerpc) 7578 VAR_CPU=ppc 7579 VAR_CPU_ARCH=ppc 7580 VAR_CPU_BITS=32 7581 VAR_CPU_ENDIAN=big 7582 ;; 7583 powerpc64) 7584 VAR_CPU=ppc64 7585 VAR_CPU_ARCH=ppc 7586 VAR_CPU_BITS=64 7587 VAR_CPU_ENDIAN=big 7588 ;; 7589 sparc) 7590 VAR_CPU=sparc 7591 VAR_CPU_ARCH=sparc 7592 VAR_CPU_BITS=32 7593 VAR_CPU_ENDIAN=big 7594 ;; 7595 sparcv9) 7596 VAR_CPU=sparcv9 7597 VAR_CPU_ARCH=sparc 7598 VAR_CPU_BITS=64 7599 VAR_CPU_ENDIAN=big 7600 ;; 7601 *) 7602 as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5 7603 ;; 7604 esac 7605 7606 # ..and setup our own variables. (Do this explicitely to facilitate searching) 7607 OPENJDK_BUILD_OS="$VAR_OS" 7608 OPENJDK_BUILD_OS_API="$VAR_OS_API" 7609 OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV" 7610 OPENJDK_BUILD_CPU="$VAR_CPU" 7611 OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH" 7612 OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS" 7613 OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN" 7614 7615 7616 7617 7618 7619 7620 7621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5 7622 $as_echo_n "checking openjdk-build os-cpu... " >&6; } 7623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5 7624 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; } 7625 7626 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 7627 7628 case "$host_os" in 7629 *linux*) 7630 VAR_OS=linux 7631 VAR_OS_API=posix 7632 VAR_OS_ENV=linux 7633 ;; 7634 *solaris*) 7635 VAR_OS=solaris 7636 VAR_OS_API=posix 7637 VAR_OS_ENV=solaris 7638 ;; 7639 *darwin*) 7640 VAR_OS=macosx 7641 VAR_OS_API=posix 7642 VAR_OS_ENV=macosx 7643 ;; 7644 *bsd*) 7645 VAR_OS=bsd 7646 VAR_OS_API=posix 7647 VAR_OS_ENV=bsd 7648 ;; 7649 *cygwin*) 7650 VAR_OS=windows 7651 VAR_OS_API=winapi 7652 VAR_OS_ENV=windows.cygwin 7653 ;; 7654 *mingw*) 7655 VAR_OS=windows 7656 VAR_OS_API=winapi 7657 VAR_OS_ENV=windows.msys 7658 ;; 7659 *) 7660 as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5 7661 ;; 7662 esac 7663 7664 7665 # First argument is the cpu name from the trip/quad 7666 case "$host_cpu" in 7667 x86_64) 7668 VAR_CPU=x86_64 7669 VAR_CPU_ARCH=x86 7670 VAR_CPU_BITS=64 7671 VAR_CPU_ENDIAN=little 7672 ;; 7673 i?86) 7674 VAR_CPU=x86 7675 VAR_CPU_ARCH=x86 7676 VAR_CPU_BITS=32 7677 VAR_CPU_ENDIAN=little 7678 ;; 7679 arm*) 7680 VAR_CPU=arm 7681 VAR_CPU_ARCH=arm 7682 VAR_CPU_BITS=32 7683 VAR_CPU_ENDIAN=little 7684 ;; 7685 powerpc) 7686 VAR_CPU=ppc 7687 VAR_CPU_ARCH=ppc 7688 VAR_CPU_BITS=32 7689 VAR_CPU_ENDIAN=big 7690 ;; 7691 powerpc64) 7692 VAR_CPU=ppc64 7693 VAR_CPU_ARCH=ppc 7694 VAR_CPU_BITS=64 7695 VAR_CPU_ENDIAN=big 7696 ;; 7697 sparc) 7698 VAR_CPU=sparc 7699 VAR_CPU_ARCH=sparc 7700 VAR_CPU_BITS=32 7701 VAR_CPU_ENDIAN=big 7702 ;; 7703 sparcv9) 7704 VAR_CPU=sparcv9 7705 VAR_CPU_ARCH=sparc 7706 VAR_CPU_BITS=64 7707 VAR_CPU_ENDIAN=big 7708 ;; 7709 *) 7710 as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5 7711 ;; 7712 esac 7713 7714 # ... and setup our own variables. (Do this explicitely to facilitate searching) 7715 OPENJDK_TARGET_OS="$VAR_OS" 7716 OPENJDK_TARGET_OS_API="$VAR_OS_API" 7717 OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV" 7718 OPENJDK_TARGET_CPU="$VAR_CPU" 7719 OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH" 7720 OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS" 7721 OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN" 7722 7723 7724 7725 7726 7727 7728 7729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5 7730 $as_echo_n "checking openjdk-target os-cpu... " >&6; } 7731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5 7732 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; } 7733 7734 7735 7736 # Check whether --with-target-bits was given. 7737 if test "${with_target_bits+set}" = set; then : 7738 withval=$with_target_bits; 7739 fi 7740 7741 7742 # We have three types of compiles: 7743 # native == normal compilation, target system == build system 7744 # cross == traditional cross compilation, target system != build system; special toolchain needed 7745 # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines 7746 # 7747 if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then 7748 # We're doing a proper cross-compilation 7749 COMPILE_TYPE="cross" 7750 else 7751 COMPILE_TYPE="native" 7752 fi 7753 7754 if test "x$with_target_bits" != x; then 7755 if test "x$COMPILE_TYPE" = "xcross"; then 7756 as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5 7757 fi 7758 7759 if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 7760 # A reduced build is requested 7761 COMPILE_TYPE="reduced" 7762 OPENJDK_TARGET_CPU_BITS=32 7763 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 7764 OPENJDK_TARGET_CPU=x86 7765 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 7766 OPENJDK_TARGET_CPU=sparc 7767 else 7768 as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5 7769 fi 7770 elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 7771 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 7772 elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then 7773 { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5 7774 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;} 7775 else 7776 as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5 7777 fi 7778 fi 7779 7780 7781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5 7782 $as_echo_n "checking compilation type... " >&6; } 7783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5 7784 $as_echo "$COMPILE_TYPE" >&6; } 7785 7786 7787 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 7788 REQUIRED_OS_NAME=SunOS 7789 REQUIRED_OS_VERSION=5.10 7790 fi 7791 if test "x$OPENJDK_TARGET_OS" = "xlinux"; then 7792 REQUIRED_OS_NAME=Linux 7793 REQUIRED_OS_VERSION=2.6 7794 fi 7795 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 7796 REQUIRED_OS_NAME=Windows 7797 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 7798 REQUIRED_OS_VERSION=5.2 7799 else 7800 REQUIRED_OS_VERSION=5.1 7801 fi 7802 fi 7803 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 7804 REQUIRED_OS_NAME=Darwin 7805 REQUIRED_OS_VERSION=11.2 7806 fi 7807 7808 7809 7810 7811 7812 # Also store the legacy naming of the cpu. 7813 # Ie i586 and amd64 instead of x86 and x86_64 7814 OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU" 7815 if test "x$OPENJDK_TARGET_CPU" = xx86; then 7816 OPENJDK_TARGET_CPU_LEGACY="i586" 7817 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 7818 # On all platforms except MacOSX replace x86_64 with amd64. 7819 OPENJDK_TARGET_CPU_LEGACY="amd64" 7820 fi 7821 7822 7823 # And the second legacy naming of the cpu. 7824 # Ie i386 and amd64 instead of x86 and x86_64. 7825 OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU" 7826 if test "x$OPENJDK_TARGET_CPU" = xx86; then 7827 OPENJDK_TARGET_CPU_LEGACY_LIB="i386" 7828 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 7829 OPENJDK_TARGET_CPU_LEGACY_LIB="amd64" 7830 fi 7831 7832 7833 # This is the name of the cpu (but using i386 and amd64 instead of 7834 # x86 and x86_64, respectively), preceeded by a /, to be used when 7835 # locating libraries. On macosx, it's empty, though. 7836 OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB" 7837 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 7838 OPENJDK_TARGET_CPU_LIBDIR="" 7839 fi 7840 7841 7842 # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 7843 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 7844 # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so 7845 OPENJDK_TARGET_CPU_ISADIR="" 7846 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 7847 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 7848 OPENJDK_TARGET_CPU_ISADIR="/amd64" 7849 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 7850 OPENJDK_TARGET_CPU_ISADIR="/sparcv9" 7851 fi 7852 fi 7853 7854 7855 # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property 7856 OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU" 7857 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then 7858 # On linux only, we replace x86 with i386. 7859 OPENJDK_TARGET_CPU_OSARCH="i386" 7860 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 7861 # On all platforms except macosx, we replace x86_64 with amd64. 7862 OPENJDK_TARGET_CPU_OSARCH="amd64" 7863 fi 7864 7865 7866 OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU" 7867 if test "x$OPENJDK_TARGET_CPU" = xx86; then 7868 OPENJDK_TARGET_CPU_JLI="i386" 7869 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 7870 # On all platforms except macosx, we replace x86_64 with amd64. 7871 OPENJDK_TARGET_CPU_JLI="amd64" 7872 fi 7873 # Now setup the -D flags for building libjli. 7874 OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'" 7875 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 7876 if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then 7877 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'" 7878 elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 7879 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'" 7880 fi 7881 fi 7882 7883 7884 # Setup OPENJDK_TARGET_OS_API_DIR, used in source paths. 7885 if test "x$OPENJDK_TARGET_OS_API" = xposix; then 7886 OPENJDK_TARGET_OS_API_DIR="solaris" 7887 fi 7888 if test "x$OPENJDK_TARGET_OS_API" = xwinapi; then 7889 OPENJDK_TARGET_OS_API_DIR="windows" 7890 fi 7891 7892 7893 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 7894 A_LP64="LP64:=" 7895 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 7896 # unpack200.exe 7897 if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then 7898 ADD_LP64="-D_LP64=1" 7899 fi 7900 fi 7901 LP64=$A_LP64 7902 7903 7904 if test "x$COMPILE_TYPE" = "xcross"; then 7905 # FIXME: ... or should this include reduced builds..? 7906 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY" 7907 else 7908 DEFINE_CROSS_COMPILE_ARCH="" 7909 fi 7910 7911 7912 # Some Zero and Shark settings. 7913 # ZERO_ARCHFLAG tells the compiler which mode to build for 7914 case "${OPENJDK_TARGET_CPU}" in 7915 s390) 7916 ZERO_ARCHFLAG="-m31" 7917 ;; 7918 *) 7919 ZERO_ARCHFLAG="-m${OPENJDK_TARGET_CPU_BITS}" 7920 esac 7921 7922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$ZERO_ARCHFLAG\"" >&5 7923 $as_echo_n "checking if compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 7924 saved_cflags="$CFLAGS" 7925 CFLAGS="$ZERO_ARCHFLAG" 7926 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7927 /* end confdefs.h. */ 7928 7929 7930 int main() { return 0; } 7931 7932 7933 _ACEOF 7934 if ac_fn_c_try_compile "$LINENO"; then : 7935 supports=yes 7936 else 7937 supports=no 7938 fi 7939 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 7940 CFLAGS="$saved_cflags" 7941 if "x$supports" = "xyes" ; then 7942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 7943 $as_echo "$supports" >&6; } 7944 7945 else 7946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 7947 $as_echo "$supports" >&6; } 7948 ZERO_ARCHFLAG="" 7949 fi 7950 7951 7952 7953 # ZERO_ARCHDEF is used to enable architecture-specific code 7954 case "${OPENJDK_TARGET_CPU}" in 7955 ppc*) ZERO_ARCHDEF=PPC ;; 7956 s390*) ZERO_ARCHDEF=S390 ;; 7957 sparc*) ZERO_ARCHDEF=SPARC ;; 7958 x86_64*) ZERO_ARCHDEF=AMD64 ;; 7959 x86) ZERO_ARCHDEF=IA32 ;; 7960 *) ZERO_ARCHDEF=$(echo "${OPENJDK_TARGET_CPU_LEGACY_LIB}" | tr a-z A-Z) 7961 esac 7962 7963 7964 7965 7966 7967 # Continue setting up basic stuff. Most remaining code require fundamental tools. 7968 7969 # Locate the directory of this script. 7970 SCRIPT="$0" 7971 7972 if test "x$OPENJDK_BUILD_OS" != xwindows; then 7973 # Follow a chain of symbolic links. Use readlink 7974 # where it exists, else fall back to horribly 7975 # complicated shell code. 7976 if test "x$READLINK_TESTED" != yes; then 7977 # On MacOSX there is a readlink tool with a different 7978 # purpose than the GNU readlink tool. Check the found readlink. 7979 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 7980 if test "x$ISGNU" = x; then 7981 # A readlink that we do not know how to use. 7982 # Are there other non-GNU readlinks out there? 7983 READLINK_TESTED=yes 7984 READLINK= 7985 fi 7986 fi 7987 7988 if test "x$READLINK" != x; then 7989 SCRIPT=`$READLINK -f $SCRIPT` 7990 else 7991 # Save the current directory for restoring afterwards 7992 STARTDIR=$PWD 7993 COUNTER=0 7994 sym_link_dir=`$DIRNAME $SCRIPT` 7995 sym_link_file=`$BASENAME $SCRIPT` 7996 # Use the system pwd and not the shell builtin to resolve directory symlinks 7997 cd $sym_link_dir 7998 cd `$THEPWDCMD` 7999 sym_link_dir=`$THEPWDCMD` 8000 # Resolve file symlinks 8001 while test $COUNTER -lt 20; do 8002 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 8003 if test "x$ISLINK" == x; then 8004 # This is not a symbolic link! We are done! 8005 break 8006 fi 8007 # Again resolve directory symlinks since the target of the just found 8008 # link could be in a different directory 8009 cd `$DIRNAME $ISLINK` 8010 sym_link_dir=`$THEPWDCMD` 8011 sym_link_file=`$BASENAME $ISLINK` 8012 let COUNTER=COUNTER+1 8013 done 8014 cd $STARTDIR 8015 SCRIPT=$sym_link_dir/$sym_link_file 8016 fi 8017 fi 8018 8019 AUTOCONF_DIR=`cd \`$DIRNAME $SCRIPT\`; $THEPWDCMD` 8020 8021 # Where is the source? It is located two levels above the configure script. 8022 CURDIR="$PWD" 8023 cd "$AUTOCONF_DIR/../.." 8024 SRC_ROOT="`$THEPWDCMD`" 8025 8026 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 8027 PATH_SEP=";" 8028 8029 SRC_ROOT_LENGTH=`$THEPWDCMD|$WC -m` 8030 if test $SRC_ROOT_LENGTH -gt 100; then 8031 as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5 8032 fi 8033 8034 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5 8036 $as_echo_n "checking cygwin release... " >&6; } 8037 CYGWIN_VERSION=`$UNAME -r` 8038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5 8039 $as_echo "$CYGWIN_VERSION" >&6; } 8040 WINDOWS_ENV_VENDOR='cygwin' 8041 WINDOWS_ENV_VERSION="$CYGWIN_VERSION" 8042 8043 CYGWIN_VERSION_OK=`$ECHO $CYGWIN_VERSION | $GREP ^1.7.` 8044 if test "x$CYGWIN_VERSION_OK" = x; then 8045 { $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 8046 $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;} 8047 as_fn_error $? "Cannot continue" "$LINENO" 5 8048 fi 8049 if test "x$CYGPATH" = x; then 8050 as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5 8051 fi 8052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 8053 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } 8054 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 8055 cygwin_winpath_root=`cd / ; cmd /c cd | grep ".*"` 8056 # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. 8057 CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` 8058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 8059 $as_echo "$CYGWIN_ROOT_PATH" >&6; } 8060 WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH" 8061 test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/` 8062 if test "x$test_cygdrive_prefix" = x; then 8063 as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5 8064 fi 8065 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5 8067 $as_echo_n "checking msys release... " >&6; } 8068 MSYS_VERSION=`$UNAME -r` 8069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5 8070 $as_echo "$MSYS_VERSION" >&6; } 8071 8072 WINDOWS_ENV_VENDOR='msys' 8073 WINDOWS_ENV_VERSION="$MSYS_VERSION" 8074 8075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5 8076 $as_echo_n "checking msys root directory as unix-style path... " >&6; } 8077 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 8078 MSYS_ROOT_PATH=`cd / ; cmd /c cd | grep ".*"` 8079 8080 windows_path="$MSYS_ROOT_PATH" 8081 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8082 unix_path=`$CYGPATH -u "$windows_path"` 8083 MSYS_ROOT_PATH="$unix_path" 8084 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8085 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8086 MSYS_ROOT_PATH="$unix_path" 8087 fi 8088 8089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5 8090 $as_echo "$MSYS_ROOT_PATH" >&6; } 8091 WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH" 8092 else 8093 as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5 8094 fi 8095 8096 # Test if windows or unix (cygwin/msys) find is first in path. 8097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5 8098 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; } 8099 FIND_BINARY_OUTPUT=`find --version 2>&1` 8100 if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then 8101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5 8102 $as_echo "unix style" >&6; } 8103 elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then 8104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5 8105 $as_echo "Windows" >&6; } 8106 { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5 8107 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;} 8108 { $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 8109 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;} 8110 as_fn_error $? "Cannot continue" "$LINENO" 5 8111 else 8112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 8113 $as_echo "unknown" >&6; } 8114 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5 8115 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;} 8116 fi 8117 8118 else 8119 PATH_SEP=":" 8120 fi 8121 8122 8123 8124 cd "$CURDIR" 8125 8126 8127 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8128 8129 # Input might be given as Windows format, start by converting to 8130 # unix format. 8131 path="$SRC_ROOT" 8132 new_path=`$CYGPATH -u "$path"` 8133 8134 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 8135 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 8136 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 8137 # "foo.exe" is OK but "foo" is an error. 8138 # 8139 # This test is therefore slightly more accurate than "test -f" to check for file precense. 8140 # It is also a way to make sure we got the proper file name for the real test later on. 8141 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 8142 if test "x$test_shortpath" = x; then 8143 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of SRC_ROOT, which resolves as \"$path\", is invalid." >&5 8144 $as_echo "$as_me: The path of SRC_ROOT, which resolves as \"$path\", is invalid." >&6;} 8145 as_fn_error $? "Cannot locate the the path of SRC_ROOT" "$LINENO" 5 8146 fi 8147 8148 # Call helper function which possibly converts this using DOS-style short mode. 8149 # If so, the updated path is stored in $new_path. 8150 8151 input_path="$new_path" 8152 # Check if we need to convert this using DOS-style short mode. If the path 8153 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8154 # take no chances and rewrite it. 8155 # Note: m4 eats our [], so we need to use [ and ] instead. 8156 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 8157 if test "x$has_forbidden_chars" != x; then 8158 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8159 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 8160 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 8161 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 8162 # Going to short mode and back again did indeed matter. Since short mode is 8163 # case insensitive, let's make it lowercase to improve readability. 8164 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8165 # Now convert it back to Unix-stile (cygpath) 8166 input_path=`$CYGPATH -u "$shortmode_path"` 8167 new_path="$input_path" 8168 fi 8169 fi 8170 8171 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 8172 if test "x$test_cygdrive_prefix" = x; then 8173 # As a simple fix, exclude /usr/bin since it's not a real path. 8174 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 8175 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 8176 # a path prefixed by /cygdrive for fixpath to work. 8177 new_path="$CYGWIN_ROOT_PATH$input_path" 8178 fi 8179 fi 8180 8181 8182 if test "x$path" != "x$new_path"; then 8183 SRC_ROOT="$new_path" 8184 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting SRC_ROOT to \"$new_path\"" >&5 8185 $as_echo "$as_me: Rewriting SRC_ROOT to \"$new_path\"" >&6;} 8186 fi 8187 8188 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8189 8190 path="$SRC_ROOT" 8191 has_colon=`$ECHO $path | $GREP ^.:` 8192 new_path="$path" 8193 if test "x$has_colon" = x; then 8194 # Not in mixed or Windows style, start by that. 8195 new_path=`cmd //c echo $path` 8196 fi 8197 8198 8199 input_path="$new_path" 8200 # Check if we need to convert this using DOS-style short mode. If the path 8201 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8202 # take no chances and rewrite it. 8203 # Note: m4 eats our [], so we need to use [ and ] instead. 8204 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 8205 if test "x$has_forbidden_chars" != x; then 8206 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8207 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8208 fi 8209 8210 8211 windows_path="$new_path" 8212 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8213 unix_path=`$CYGPATH -u "$windows_path"` 8214 new_path="$unix_path" 8215 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8216 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8217 new_path="$unix_path" 8218 fi 8219 8220 if test "x$path" != "x$new_path"; then 8221 SRC_ROOT="$new_path" 8222 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting SRC_ROOT to \"$new_path\"" >&5 8223 $as_echo "$as_me: Rewriting SRC_ROOT to \"$new_path\"" >&6;} 8224 fi 8225 8226 # Save the first 10 bytes of this path to the storage, so fixpath can work. 8227 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 8228 8229 else 8230 # We're on a posix platform. Hooray! :) 8231 path="$SRC_ROOT" 8232 8233 if test ! -f "$path" && test ! -d "$path"; then 8234 as_fn_error $? "The path of SRC_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5 8235 fi 8236 8237 has_space=`$ECHO "$path" | $GREP " "` 8238 if test "x$has_space" != x; then 8239 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of SRC_ROOT, which resolves as \"$path\", is invalid." >&5 8240 $as_echo "$as_me: The path of SRC_ROOT, which resolves as \"$path\", is invalid." >&6;} 8241 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 8242 fi 8243 fi 8244 8245 8246 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8247 8248 # Input might be given as Windows format, start by converting to 8249 # unix format. 8250 path="$CURDIR" 8251 new_path=`$CYGPATH -u "$path"` 8252 8253 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 8254 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 8255 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 8256 # "foo.exe" is OK but "foo" is an error. 8257 # 8258 # This test is therefore slightly more accurate than "test -f" to check for file precense. 8259 # It is also a way to make sure we got the proper file name for the real test later on. 8260 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 8261 if test "x$test_shortpath" = x; then 8262 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 8263 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 8264 as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5 8265 fi 8266 8267 # Call helper function which possibly converts this using DOS-style short mode. 8268 # If so, the updated path is stored in $new_path. 8269 8270 input_path="$new_path" 8271 # Check if we need to convert this using DOS-style short mode. If the path 8272 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8273 # take no chances and rewrite it. 8274 # Note: m4 eats our [], so we need to use [ and ] instead. 8275 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 8276 if test "x$has_forbidden_chars" != x; then 8277 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8278 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 8279 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 8280 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 8281 # Going to short mode and back again did indeed matter. Since short mode is 8282 # case insensitive, let's make it lowercase to improve readability. 8283 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8284 # Now convert it back to Unix-stile (cygpath) 8285 input_path=`$CYGPATH -u "$shortmode_path"` 8286 new_path="$input_path" 8287 fi 8288 fi 8289 8290 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 8291 if test "x$test_cygdrive_prefix" = x; then 8292 # As a simple fix, exclude /usr/bin since it's not a real path. 8293 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 8294 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 8295 # a path prefixed by /cygdrive for fixpath to work. 8296 new_path="$CYGWIN_ROOT_PATH$input_path" 8297 fi 8298 fi 8299 8300 8301 if test "x$path" != "x$new_path"; then 8302 CURDIR="$new_path" 8303 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 8304 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 8305 fi 8306 8307 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8308 8309 path="$CURDIR" 8310 has_colon=`$ECHO $path | $GREP ^.:` 8311 new_path="$path" 8312 if test "x$has_colon" = x; then 8313 # Not in mixed or Windows style, start by that. 8314 new_path=`cmd //c echo $path` 8315 fi 8316 8317 8318 input_path="$new_path" 8319 # Check if we need to convert this using DOS-style short mode. If the path 8320 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8321 # take no chances and rewrite it. 8322 # Note: m4 eats our [], so we need to use [ and ] instead. 8323 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 8324 if test "x$has_forbidden_chars" != x; then 8325 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8326 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8327 fi 8328 8329 8330 windows_path="$new_path" 8331 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8332 unix_path=`$CYGPATH -u "$windows_path"` 8333 new_path="$unix_path" 8334 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8335 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8336 new_path="$unix_path" 8337 fi 8338 8339 if test "x$path" != "x$new_path"; then 8340 CURDIR="$new_path" 8341 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 8342 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 8343 fi 8344 8345 # Save the first 10 bytes of this path to the storage, so fixpath can work. 8346 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 8347 8348 else 8349 # We're on a posix platform. Hooray! :) 8350 path="$CURDIR" 8351 8352 if test ! -f "$path" && test ! -d "$path"; then 8353 as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5 8354 fi 8355 8356 has_space=`$ECHO "$path" | $GREP " "` 8357 if test "x$has_space" != x; then 8358 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 8359 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 8360 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 8361 fi 8362 fi 8363 8364 8365 if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 8366 # Add extra search paths on solaris for utilities like ar and as etc... 8367 PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin" 8368 fi 8369 8370 # You can force the sys-root if the sys-root encoded into the cross compiler tools 8371 # is not correct. 8372 8373 # Check whether --with-sys-root was given. 8374 if test "${with_sys_root+set}" = set; then : 8375 withval=$with_sys_root; 8376 fi 8377 8378 8379 if test "x$with_sys_root" != x; then 8380 SYS_ROOT=$with_sys_root 8381 else 8382 SYS_ROOT=/ 8383 fi 8384 8385 8386 8387 # Check whether --with-tools-dir was given. 8388 if test "${with_tools_dir+set}" = set; then : 8389 withval=$with_tools_dir; TOOLS_DIR=$with_tools_dir 8390 fi 8391 8392 8393 8394 # Check whether --with-devkit was given. 8395 if test "${with_devkit+set}" = set; then : 8396 withval=$with_devkit; 8397 if test "x$with_sys_root" != x; then 8398 as_fn_error $? "Cannot specify both --with-devkit and --with-sys-root at the same time" "$LINENO" 5 8399 fi 8400 if test "x$with_tools_dir" != x; then 8401 as_fn_error $? "Cannot specify both --with-devkit and --with-tools-dir at the same time" "$LINENO" 5 8402 fi 8403 TOOLS_DIR=$with_devkit/bin 8404 SYS_ROOT=$with_devkit/$host_alias/libc 8405 8406 fi 8407 8408 8409 8410 8411 # Setup default logging of stdout and stderr to build.log in the output root. 8412 BUILD_LOG='$(OUTPUT_ROOT)/build.log' 8413 BUILD_LOG_PREVIOUS='$(OUTPUT_ROOT)/build.log.old' 8414 BUILD_LOG_WRAPPER='$(BASH) $(SRC_ROOT)/common/bin/logger.sh $(BUILD_LOG)' 8415 8416 8417 8418 8419 8420 # Check if it's a pure open build or if custom sources are to be used. 8421 8422 # Check whether --enable-openjdk-only was given. 8423 if test "${enable_openjdk_only+set}" = set; then : 8424 enableval=$enable_openjdk_only; 8425 else 8426 enable_openjdk_only="no" 8427 fi 8428 8429 8430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of closed sources" >&5 8431 $as_echo_n "checking for presence of closed sources... " >&6; } 8432 if test -d "$SRC_ROOT/jdk/src/closed"; then 8433 CLOSED_SOURCE_PRESENT=yes 8434 else 8435 CLOSED_SOURCE_PRESENT=no 8436 fi 8437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLOSED_SOURCE_PRESENT" >&5 8438 $as_echo "$CLOSED_SOURCE_PRESENT" >&6; } 8439 8440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closed source is suppressed (openjdk-only)" >&5 8441 $as_echo_n "checking if closed source is suppressed (openjdk-only)... " >&6; } 8442 SUPPRESS_CLOSED_SOURCE="$enable_openjdk_only" 8443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SUPPRESS_CLOSED_SOURCE" >&5 8444 $as_echo "$SUPPRESS_CLOSED_SOURCE" >&6; } 8445 8446 if test "x$CLOSED_SOURCE_PRESENT" = xno; then 8447 OPENJDK=true 8448 if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then 8449 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&5 8450 $as_echo "$as_me: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&2;} 8451 fi 8452 else 8453 if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then 8454 OPENJDK=true 8455 else 8456 OPENJDK=false 8457 fi 8458 fi 8459 8460 if test "x$OPENJDK" = "xtrue"; then 8461 SET_OPENJDK="OPENJDK=true" 8462 fi 8463 8464 8465 8466 8467 # These are needed to be able to create a configuration name (and thus the output directory) 8468 8469 ############################################################################### 8470 # 8471 # Check which variant of the JDK that we want to build. 8472 # Currently we have: 8473 # normal: standard edition 8474 # but the custom make system may add other variants 8475 # 8476 # Effectively the JDK variant gives a name to a specific set of 8477 # modules to compile into the JDK. In the future, these modules 8478 # might even be Jigsaw modules. 8479 # 8480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5 8481 $as_echo_n "checking which variant of the JDK to build... " >&6; } 8482 8483 # Check whether --with-jdk-variant was given. 8484 if test "${with_jdk_variant+set}" = set; then : 8485 withval=$with_jdk_variant; 8486 fi 8487 8488 8489 if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then 8490 JDK_VARIANT="normal" 8491 else 8492 as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5 8493 fi 8494 8495 8496 8497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5 8498 $as_echo "$JDK_VARIANT" >&6; } 8499 8500 8501 8502 ############################################################################### 8503 # 8504 # Check which variants of the JVM that we want to build. 8505 # Currently we have: 8506 # server: normal interpreter and a tiered C1/C2 compiler 8507 # client: normal interpreter and C1 (no C2 compiler) (only 32-bit platforms) 8508 # minimal1: reduced form of client with optional VM services and features stripped out 8509 # kernel: kernel footprint JVM that passes the TCK without major performance problems, 8510 # ie normal interpreter and C1, only the serial GC, kernel jvmti etc 8511 # zero: no machine code interpreter, no compiler 8512 # zeroshark: zero interpreter and shark/llvm compiler backend 8513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5 8514 $as_echo_n "checking which variants of the JVM to build... " >&6; } 8515 8516 # Check whether --with-jvm-variants was given. 8517 if test "${with_jvm_variants+set}" = set; then : 8518 withval=$with_jvm_variants; 8519 fi 8520 8521 8522 if test "x$with_jvm_variants" = x; then 8523 with_jvm_variants="server" 8524 fi 8525 8526 JVM_VARIANTS=",$with_jvm_variants," 8527 TEST_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/server,//' -e 's/client,//' -e 's/minimal1,//' -e 's/kernel,//' -e 's/zero,//' -e 's/zeroshark,//'` 8528 8529 if test "x$TEST_VARIANTS" != "x,"; then 8530 as_fn_error $? "The available JVM variants are: server, client, minimal1, kernel, zero, zeroshark" "$LINENO" 5 8531 fi 8532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_variants" >&5 8533 $as_echo "$with_jvm_variants" >&6; } 8534 8535 JVM_VARIANT_SERVER=`$ECHO "$JVM_VARIANTS" | $SED -e '/,server,/!s/.*/false/g' -e '/,server,/s/.*/true/g'` 8536 JVM_VARIANT_CLIENT=`$ECHO "$JVM_VARIANTS" | $SED -e '/,client,/!s/.*/false/g' -e '/,client,/s/.*/true/g'` 8537 JVM_VARIANT_MINIMAL1=`$ECHO "$JVM_VARIANTS" | $SED -e '/,minimal1,/!s/.*/false/g' -e '/,minimal1,/s/.*/true/g'` 8538 JVM_VARIANT_KERNEL=`$ECHO "$JVM_VARIANTS" | $SED -e '/,kernel,/!s/.*/false/g' -e '/,kernel,/s/.*/true/g'` 8539 JVM_VARIANT_ZERO=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zero,/!s/.*/false/g' -e '/,zero,/s/.*/true/g'` 8540 JVM_VARIANT_ZEROSHARK=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zeroshark,/!s/.*/false/g' -e '/,zeroshark,/s/.*/true/g'` 8541 8542 if test "x$JVM_VARIANT_CLIENT" = xtrue; then 8543 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 8544 as_fn_error $? "You cannot build a client JVM for a 64-bit machine." "$LINENO" 5 8545 fi 8546 fi 8547 if test "x$JVM_VARIANT_KERNEL" = xtrue; then 8548 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 8549 as_fn_error $? "You cannot build a kernel JVM for a 64-bit machine." "$LINENO" 5 8550 fi 8551 fi 8552 if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then 8553 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 8554 as_fn_error $? "You cannot build a minimal JVM for a 64-bit machine." "$LINENO" 5 8555 fi 8556 fi 8557 8558 # Replace the commas with AND for use in the build directory name. 8559 ANDED_JVM_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/^,//' -e 's/,$//' -e 's/,/AND/'` 8560 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/'` 8561 if test "x$COUNT_VARIANTS" != "x,1"; then 8562 BUILDING_MULTIPLE_JVM_VARIANTS=yes 8563 else 8564 BUILDING_MULTIPLE_JVM_VARIANTS=no 8565 fi 8566 8567 8568 8569 8570 8571 8572 8573 8574 8575 INCLUDE_SA=true 8576 if test "x$JVM_VARIANT_ZERO" = xtrue ; then 8577 INCLUDE_SA=false 8578 fi 8579 if test "x$JVM_VARIANT_ZEROSHARK" = xtrue ; then 8580 INCLUDE_SA=false 8581 fi 8582 8583 8584 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 8585 MACOSX_UNIVERSAL="true" 8586 fi 8587 8588 8589 8590 8591 8592 ############################################################################### 8593 # 8594 # Set the debug level 8595 # release: no debug information, all optimizations, no asserts. 8596 # fastdebug: debug information (-g), all optimizations, all asserts 8597 # slowdebug: debug information (-g), no optimizations, all asserts 8598 # 8599 DEBUG_LEVEL="release" 8600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5 8601 $as_echo_n "checking which debug level to use... " >&6; } 8602 # Check whether --enable-debug was given. 8603 if test "${enable_debug+set}" = set; then : 8604 enableval=$enable_debug; 8605 ENABLE_DEBUG="${enableval}" 8606 DEBUG_LEVEL="fastdebug" 8607 8608 else 8609 ENABLE_DEBUG="no" 8610 fi 8611 8612 8613 8614 # Check whether --with-debug-level was given. 8615 if test "${with_debug_level+set}" = set; then : 8616 withval=$with_debug_level; 8617 DEBUG_LEVEL="${withval}" 8618 if test "x$ENABLE_DEBUG" = xyes; then 8619 as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5 8620 fi 8621 8622 fi 8623 8624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5 8625 $as_echo "$DEBUG_LEVEL" >&6; } 8626 8627 if test "x$DEBUG_LEVEL" != xrelease && \ 8628 test "x$DEBUG_LEVEL" != xfastdebug && \ 8629 test "x$DEBUG_LEVEL" != xslowdebug; then 8630 as_fn_error $? "Allowed debug levels are: release, fastdebug and slowdebug" "$LINENO" 5 8631 fi 8632 8633 8634 ############################################################################### 8635 # 8636 # Setup legacy vars/targets and new vars to deal with different debug levels. 8637 # 8638 8639 case $DEBUG_LEVEL in 8640 release ) 8641 VARIANT="OPT" 8642 FASTDEBUG="false" 8643 DEBUG_CLASSFILES="false" 8644 BUILD_VARIANT_RELEASE="" 8645 HOTSPOT_DEBUG_LEVEL="product" 8646 HOTSPOT_EXPORT="product" 8647 ;; 8648 fastdebug ) 8649 VARIANT="DBG" 8650 FASTDEBUG="true" 8651 DEBUG_CLASSFILES="true" 8652 BUILD_VARIANT_RELEASE="-fastdebug" 8653 HOTSPOT_DEBUG_LEVEL="fastdebug" 8654 HOTSPOT_EXPORT="fastdebug" 8655 ;; 8656 slowdebug ) 8657 VARIANT="DBG" 8658 FASTDEBUG="false" 8659 DEBUG_CLASSFILES="true" 8660 BUILD_VARIANT_RELEASE="-debug" 8661 HOTSPOT_DEBUG_LEVEL="jvmg" 8662 HOTSPOT_EXPORT="debug" 8663 ;; 8664 esac 8665 8666 ##### 8667 # Generate the legacy makefile targets for hotspot. 8668 # The hotspot api for selecting the build artifacts, really, needs to be improved. 8669 # JDK-7195896 will fix this on the hotspot side by using the JVM_VARIANT_* variables to 8670 # determine what needs to be built. All we will need to set here is all_product, all_fastdebug etc 8671 # But until then ... 8672 HOTSPOT_TARGET="" 8673 8674 if test "x$JVM_VARIANT_SERVER" = xtrue; then 8675 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL} " 8676 fi 8677 8678 if test "x$JVM_VARIANT_CLIENT" = xtrue; then 8679 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}1 " 8680 fi 8681 8682 if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then 8683 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}minimal1 " 8684 fi 8685 8686 if test "x$JVM_VARIANT_KERNEL" = xtrue; then 8687 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}kernel " 8688 fi 8689 8690 if test "x$JVM_VARIANT_ZERO" = xtrue; then 8691 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}zero " 8692 fi 8693 8694 if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 8695 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}shark " 8696 fi 8697 8698 HOTSPOT_TARGET="$HOTSPOT_TARGET docs export_$HOTSPOT_EXPORT" 8699 8700 # On Macosx universal binaries are produced, but they only contain 8701 # 64 bit intel. This invalidates control of which jvms are built 8702 # from configure, but only server is valid anyway. Fix this 8703 # when hotspot makefiles are rewritten. 8704 if test "x$MACOSX_UNIVERSAL" = xtrue; then 8705 HOTSPOT_TARGET=universal_${HOTSPOT_EXPORT} 8706 fi 8707 8708 ##### 8709 8710 8711 8712 8713 8714 8715 8716 8717 # With basic setup done, call the custom early hook. 8718 8719 8720 # To properly create a configuration name, we need to have the OpenJDK target 8721 # and options (variants and debug level) parsed. 8722 8723 8724 8725 # Check whether --with-conf-name was given. 8726 if test "${with_conf_name+set}" = set; then : 8727 withval=$with_conf_name; CONF_NAME=${with_conf_name} 8728 fi 8729 8730 8731 # Test from where we are running configure, in or outside of src root. 8732 # To enable comparison of directories, CURDIR needs to be symlink free 8733 # just like SRC_ROOT already is 8734 NOSYM_CURDIR="$CURDIR" 8735 8736 if test "x$OPENJDK_BUILD_OS" != xwindows; then 8737 # Follow a chain of symbolic links. Use readlink 8738 # where it exists, else fall back to horribly 8739 # complicated shell code. 8740 if test "x$READLINK_TESTED" != yes; then 8741 # On MacOSX there is a readlink tool with a different 8742 # purpose than the GNU readlink tool. Check the found readlink. 8743 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 8744 if test "x$ISGNU" = x; then 8745 # A readlink that we do not know how to use. 8746 # Are there other non-GNU readlinks out there? 8747 READLINK_TESTED=yes 8748 READLINK= 8749 fi 8750 fi 8751 8752 if test "x$READLINK" != x; then 8753 NOSYM_CURDIR=`$READLINK -f $NOSYM_CURDIR` 8754 else 8755 # Save the current directory for restoring afterwards 8756 STARTDIR=$PWD 8757 COUNTER=0 8758 sym_link_dir=`$DIRNAME $NOSYM_CURDIR` 8759 sym_link_file=`$BASENAME $NOSYM_CURDIR` 8760 # Use the system pwd and not the shell builtin to resolve directory symlinks 8761 cd $sym_link_dir 8762 cd `$THEPWDCMD` 8763 sym_link_dir=`$THEPWDCMD` 8764 # Resolve file symlinks 8765 while test $COUNTER -lt 20; do 8766 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 8767 if test "x$ISLINK" == x; then 8768 # This is not a symbolic link! We are done! 8769 break 8770 fi 8771 # Again resolve directory symlinks since the target of the just found 8772 # link could be in a different directory 8773 cd `$DIRNAME $ISLINK` 8774 sym_link_dir=`$THEPWDCMD` 8775 sym_link_file=`$BASENAME $ISLINK` 8776 let COUNTER=COUNTER+1 8777 done 8778 cd $STARTDIR 8779 NOSYM_CURDIR=$sym_link_dir/$sym_link_file 8780 fi 8781 fi 8782 8783 if test "x$NOSYM_CURDIR" = "x$SRC_ROOT" || test "x$NOSYM_CURDIR" = "x$SRC_ROOT/common" \ 8784 || test "x$NOSYM_CURDIR" = "x$SRC_ROOT/common/autoconf" \ 8785 || test "x$NOSYM_CURDIR" = "x$SRC_ROOT/common/makefiles" ; then 8786 # We are running configure from the src root. 8787 # Create a default ./build/target-variant-debuglevel output root. 8788 if test "x${CONF_NAME}" = x; then 8789 CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${ANDED_JVM_VARIANTS}-${DEBUG_LEVEL}" 8790 fi 8791 OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}" 8792 $MKDIR -p "$OUTPUT_ROOT" 8793 if test ! -d "$OUTPUT_ROOT"; then 8794 as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5 8795 fi 8796 else 8797 # We are running configure from outside of the src dir. 8798 # Then use the current directory as output dir! 8799 # If configuration is situated in normal build directory, just use the build 8800 # directory name as configuration name, otherwise use the complete path. 8801 if test "x${CONF_NAME}" = x; then 8802 CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"` 8803 fi 8804 OUTPUT_ROOT="$CURDIR" 8805 8806 # WARNING: This might be a bad thing to do. You need to be sure you want to 8807 # have a configuration in this directory. Do some sanity checks! 8808 8809 if test ! -e "$OUTPUT_ROOT/spec.gmk"; then 8810 # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for 8811 # other files 8812 files_present=`$LS $OUTPUT_ROOT` 8813 # Configure has already touched config.log and confdefs.h in the current dir when this check 8814 # is performed. 8815 filtered_files=`$ECHO "$files_present" | $SED -e 's/config.log//g' -e 's/confdefs.h//g' -e 's/ //g' \ 8816 | $TR -d '\n'` 8817 if test "x$filtered_files" != x; then 8818 { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5 8819 $as_echo "$as_me: Current directory is $CURDIR." >&6;} 8820 { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5 8821 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;} 8822 { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5 8823 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;} 8824 { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5 8825 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;} 8826 { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5 8827 $as_echo "$as_me: seriously mess up just about everything." >&6;} 8828 { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5 8829 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;} 8830 { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5 8831 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;} 8832 as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5 8833 fi 8834 fi 8835 fi 8836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5 8837 $as_echo_n "checking what configuration name to use... " >&6; } 8838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5 8839 $as_echo "$CONF_NAME" >&6; } 8840 8841 8842 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8843 8844 # Input might be given as Windows format, start by converting to 8845 # unix format. 8846 path="$OUTPUT_ROOT" 8847 new_path=`$CYGPATH -u "$path"` 8848 8849 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 8850 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 8851 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 8852 # "foo.exe" is OK but "foo" is an error. 8853 # 8854 # This test is therefore slightly more accurate than "test -f" to check for file precense. 8855 # It is also a way to make sure we got the proper file name for the real test later on. 8856 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 8857 if test "x$test_shortpath" = x; then 8858 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 8859 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 8860 as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5 8861 fi 8862 8863 # Call helper function which possibly converts this using DOS-style short mode. 8864 # If so, the updated path is stored in $new_path. 8865 8866 input_path="$new_path" 8867 # Check if we need to convert this using DOS-style short mode. If the path 8868 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8869 # take no chances and rewrite it. 8870 # Note: m4 eats our [], so we need to use [ and ] instead. 8871 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 8872 if test "x$has_forbidden_chars" != x; then 8873 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8874 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 8875 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 8876 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 8877 # Going to short mode and back again did indeed matter. Since short mode is 8878 # case insensitive, let's make it lowercase to improve readability. 8879 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8880 # Now convert it back to Unix-stile (cygpath) 8881 input_path=`$CYGPATH -u "$shortmode_path"` 8882 new_path="$input_path" 8883 fi 8884 fi 8885 8886 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 8887 if test "x$test_cygdrive_prefix" = x; then 8888 # As a simple fix, exclude /usr/bin since it's not a real path. 8889 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 8890 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 8891 # a path prefixed by /cygdrive for fixpath to work. 8892 new_path="$CYGWIN_ROOT_PATH$input_path" 8893 fi 8894 fi 8895 8896 8897 if test "x$path" != "x$new_path"; then 8898 OUTPUT_ROOT="$new_path" 8899 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 8900 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 8901 fi 8902 8903 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8904 8905 path="$OUTPUT_ROOT" 8906 has_colon=`$ECHO $path | $GREP ^.:` 8907 new_path="$path" 8908 if test "x$has_colon" = x; then 8909 # Not in mixed or Windows style, start by that. 8910 new_path=`cmd //c echo $path` 8911 fi 8912 8913 8914 input_path="$new_path" 8915 # Check if we need to convert this using DOS-style short mode. If the path 8916 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8917 # take no chances and rewrite it. 8918 # Note: m4 eats our [], so we need to use [ and ] instead. 8919 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 8920 if test "x$has_forbidden_chars" != x; then 8921 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8922 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8923 fi 8924 8925 8926 windows_path="$new_path" 8927 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8928 unix_path=`$CYGPATH -u "$windows_path"` 8929 new_path="$unix_path" 8930 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8931 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8932 new_path="$unix_path" 8933 fi 8934 8935 if test "x$path" != "x$new_path"; then 8936 OUTPUT_ROOT="$new_path" 8937 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 8938 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 8939 fi 8940 8941 # Save the first 10 bytes of this path to the storage, so fixpath can work. 8942 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 8943 8944 else 8945 # We're on a posix platform. Hooray! :) 8946 path="$OUTPUT_ROOT" 8947 8948 if test ! -f "$path" && test ! -d "$path"; then 8949 as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5 8950 fi 8951 8952 has_space=`$ECHO "$path" | $GREP " "` 8953 if test "x$has_space" != x; then 8954 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 8955 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 8956 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 8957 fi 8958 fi 8959 8960 8961 SPEC=$OUTPUT_ROOT/spec.gmk 8962 8963 CONF_NAME=$CONF_NAME 8964 8965 OUTPUT_ROOT=$OUTPUT_ROOT 8966 8967 8968 # Most of the probed defines are put into config.h 8969 ac_config_headers="$ac_config_headers $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in" 8970 8971 # The spec.gmk file contains all variables for the make system. 8972 ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" 8973 8974 # The hotspot-spec.gmk file contains legacy variables for the hotspot make system. 8975 ac_config_files="$ac_config_files $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" 8976 8977 # The bootcycle-spec.gmk file contains support for boot cycle builds. 8978 ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" 8979 8980 # The compare.sh is used to compare the build output to other builds. 8981 ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" 8982 8983 # Spec.sh is currently used by compare-objects.sh 8984 ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in" 8985 8986 # The generated Makefile knows where the spec.gmk is and where the source is. 8987 # You can run make from the OUTPUT_ROOT, or from the top-level Makefile 8988 # which will look for generated configurations 8989 ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" 8990 8991 8992 # Save the arguments given to us 8993 echo "$CONFIGURE_COMMAND_LINE" > $OUTPUT_ROOT/configure-arguments 8994 8995 8996 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY. 8997 8998 for ac_prog in apt-get yum port pkgutil pkgadd 8999 do 9000 # Extract the first word of "$ac_prog", so it can be a program name with args. 9001 set dummy $ac_prog; ac_word=$2 9002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9003 $as_echo_n "checking for $ac_word... " >&6; } 9004 if ${ac_cv_prog_PKGHANDLER+:} false; then : 9005 $as_echo_n "(cached) " >&6 9006 else 9007 if test -n "$PKGHANDLER"; then 9008 ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test. 9009 else 9010 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9011 for as_dir in $PATH 9012 do 9013 IFS=$as_save_IFS 9014 test -z "$as_dir" && as_dir=. 9015 for ac_exec_ext in '' $ac_executable_extensions; do 9016 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 9017 ac_cv_prog_PKGHANDLER="$ac_prog" 9018 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9019 break 2 9020 fi 9021 done 9022 done 9023 IFS=$as_save_IFS 9024 9025 fi 9026 fi 9027 PKGHANDLER=$ac_cv_prog_PKGHANDLER 9028 if test -n "$PKGHANDLER"; then 9029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5 9030 $as_echo "$PKGHANDLER" >&6; } 9031 else 9032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9033 $as_echo "no" >&6; } 9034 fi 9035 9036 9037 test -n "$PKGHANDLER" && break 9038 done 9039 9040 9041 9042 # Setup tools that requires more complex handling, or that is not needed by the configure script. 9043 9044 9045 # We need to find a recent version of GNU make. Especially on Solaris, this can be tricky. 9046 if test "x$MAKE" != x; then 9047 # User has supplied a make, test it. 9048 if test ! -f "$MAKE"; then 9049 as_fn_error $? "The specified make (by MAKE=$MAKE) is not found." "$LINENO" 5 9050 fi 9051 9052 MAKE_CANDIDATE=""$MAKE"" 9053 DESCRIPTION="user supplied MAKE=$MAKE" 9054 if test "x$MAKE_CANDIDATE" != x; then 9055 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 9056 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 9057 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 9058 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 9059 if test "x$IS_GNU_MAKE" = x; then 9060 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 9061 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 9062 else 9063 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP '3.8[12346789]'` 9064 if test "x$IS_MODERN_MAKE" = x; then 9065 { $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 9066 $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;} 9067 else 9068 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 9069 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9070 MAKE_EXPECTED_ENV='cygwin' 9071 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9072 MAKE_EXPECTED_ENV='msys' 9073 else 9074 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 9075 fi 9076 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 9077 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 9078 else 9079 # Not relevant for non-Windows 9080 IS_MAKE_CORRECT_ENV=true 9081 fi 9082 if test "x$IS_MAKE_CORRECT_ENV" = x; then 9083 { $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 9084 $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;} 9085 else 9086 FOUND_MAKE=$MAKE_CANDIDATE 9087 9088 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9089 9090 # First separate the path from the arguments. This will split at the first 9091 # space. 9092 complete="$FOUND_MAKE" 9093 path="${complete%% *}" 9094 tmp="$complete EOL" 9095 arguments="${tmp#* }" 9096 9097 # Input might be given as Windows format, start by converting to 9098 # unix format. 9099 new_path=`$CYGPATH -u "$path"` 9100 9101 # Now try to locate executable using which 9102 new_path=`$WHICH "$new_path" 2> /dev/null` 9103 # bat and cmd files are not always considered executable in cygwin causing which 9104 # to not find them 9105 if test "x$new_path" = x \ 9106 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 9107 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 9108 new_path=`$CYGPATH -u "$path"` 9109 fi 9110 if test "x$new_path" = x; then 9111 # Oops. Which didn't find the executable. 9112 # The splitting of arguments from the executable at a space might have been incorrect, 9113 # since paths with space are more likely in Windows. Give it another try with the whole 9114 # argument. 9115 path="$complete" 9116 arguments="EOL" 9117 new_path=`$CYGPATH -u "$path"` 9118 new_path=`$WHICH "$new_path" 2> /dev/null` 9119 # bat and cmd files are not always considered executable in cygwin causing which 9120 # to not find them 9121 if test "x$new_path" = x \ 9122 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 9123 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 9124 new_path=`$CYGPATH -u "$path"` 9125 fi 9126 if test "x$new_path" = x; then 9127 # It's still not found. Now this is an unrecoverable error. 9128 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9129 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9130 has_space=`$ECHO "$complete" | $GREP " "` 9131 if test "x$has_space" != x; then 9132 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9133 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9134 fi 9135 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9136 fi 9137 fi 9138 9139 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 9140 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 9141 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 9142 # "foo.exe" is OK but "foo" is an error. 9143 # 9144 # This test is therefore slightly more accurate than "test -f" to check for file precense. 9145 # It is also a way to make sure we got the proper file name for the real test later on. 9146 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 9147 if test "x$test_shortpath" = x; then 9148 # Short path failed, file does not exist as specified. 9149 # Try adding .exe or .cmd 9150 if test -f "${new_path}.exe"; then 9151 input_to_shortpath="${new_path}.exe" 9152 elif test -f "${new_path}.cmd"; then 9153 input_to_shortpath="${new_path}.cmd" 9154 else 9155 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 9156 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 9157 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 9158 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 9159 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9160 fi 9161 else 9162 input_to_shortpath="$new_path" 9163 fi 9164 9165 # Call helper function which possibly converts this using DOS-style short mode. 9166 # If so, the updated path is stored in $new_path. 9167 new_path="$input_to_shortpath" 9168 9169 input_path="$input_to_shortpath" 9170 # Check if we need to convert this using DOS-style short mode. If the path 9171 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9172 # take no chances and rewrite it. 9173 # Note: m4 eats our [], so we need to use [ and ] instead. 9174 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 9175 if test "x$has_forbidden_chars" != x; then 9176 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9177 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 9178 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 9179 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 9180 # Going to short mode and back again did indeed matter. Since short mode is 9181 # case insensitive, let's make it lowercase to improve readability. 9182 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9183 # Now convert it back to Unix-stile (cygpath) 9184 input_path=`$CYGPATH -u "$shortmode_path"` 9185 new_path="$input_path" 9186 fi 9187 fi 9188 9189 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 9190 if test "x$test_cygdrive_prefix" = x; then 9191 # As a simple fix, exclude /usr/bin since it's not a real path. 9192 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 9193 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 9194 # a path prefixed by /cygdrive for fixpath to work. 9195 new_path="$CYGWIN_ROOT_PATH$input_path" 9196 fi 9197 fi 9198 9199 # remove trailing .exe if any 9200 new_path="${new_path/%.exe/}" 9201 9202 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9203 9204 # First separate the path from the arguments. This will split at the first 9205 # space. 9206 complete="$FOUND_MAKE" 9207 path="${complete%% *}" 9208 tmp="$complete EOL" 9209 arguments="${tmp#* }" 9210 9211 # Input might be given as Windows format, start by converting to 9212 # unix format. 9213 new_path="$path" 9214 9215 windows_path="$new_path" 9216 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9217 unix_path=`$CYGPATH -u "$windows_path"` 9218 new_path="$unix_path" 9219 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9220 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9221 new_path="$unix_path" 9222 fi 9223 9224 9225 # Now try to locate executable using which 9226 new_path=`$WHICH "$new_path" 2> /dev/null` 9227 9228 if test "x$new_path" = x; then 9229 # Oops. Which didn't find the executable. 9230 # The splitting of arguments from the executable at a space might have been incorrect, 9231 # since paths with space are more likely in Windows. Give it another try with the whole 9232 # argument. 9233 path="$complete" 9234 arguments="EOL" 9235 new_path="$path" 9236 9237 windows_path="$new_path" 9238 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9239 unix_path=`$CYGPATH -u "$windows_path"` 9240 new_path="$unix_path" 9241 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9242 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9243 new_path="$unix_path" 9244 fi 9245 9246 9247 new_path=`$WHICH "$new_path" 2> /dev/null` 9248 9249 if test "x$new_path" = x; then 9250 # It's still not found. Now this is an unrecoverable error. 9251 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9252 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9253 has_space=`$ECHO "$complete" | $GREP " "` 9254 if test "x$has_space" != x; then 9255 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9256 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9257 fi 9258 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9259 fi 9260 fi 9261 9262 # Now new_path has a complete unix path to the binary 9263 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 9264 # Keep paths in /bin as-is, but remove trailing .exe if any 9265 new_path="${new_path/%.exe/}" 9266 # Do not save /bin paths to all_fixpath_prefixes! 9267 else 9268 # Not in mixed or Windows style, start by that. 9269 new_path=`cmd //c echo $new_path` 9270 9271 input_path="$new_path" 9272 # Check if we need to convert this using DOS-style short mode. If the path 9273 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9274 # take no chances and rewrite it. 9275 # Note: m4 eats our [], so we need to use [ and ] instead. 9276 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 9277 if test "x$has_forbidden_chars" != x; then 9278 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9279 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9280 fi 9281 9282 # Output is in $new_path 9283 9284 windows_path="$new_path" 9285 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9286 unix_path=`$CYGPATH -u "$windows_path"` 9287 new_path="$unix_path" 9288 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9289 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9290 new_path="$unix_path" 9291 fi 9292 9293 # remove trailing .exe if any 9294 new_path="${new_path/%.exe/}" 9295 9296 # Save the first 10 bytes of this path to the storage, so fixpath can work. 9297 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 9298 fi 9299 9300 else 9301 # We're on a posix platform. Hooray! :) 9302 # First separate the path from the arguments. This will split at the first 9303 # space. 9304 complete="$FOUND_MAKE" 9305 path="${complete%% *}" 9306 tmp="$complete EOL" 9307 arguments="${tmp#* }" 9308 9309 # Cannot rely on the command "which" here since it doesn't always work. 9310 is_absolute_path=`$ECHO "$path" | $GREP ^/` 9311 if test -z "$is_absolute_path"; then 9312 # Path to executable is not absolute. Find it. 9313 IFS_save="$IFS" 9314 IFS=: 9315 for p in $PATH; do 9316 if test -f "$p/$path" && test -x "$p/$path"; then 9317 new_path="$p/$path" 9318 break 9319 fi 9320 done 9321 IFS="$IFS_save" 9322 else 9323 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5 9324 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;} 9325 new_path="$path" 9326 fi 9327 9328 if test "x$new_path" = x; then 9329 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9330 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9331 has_space=`$ECHO "$complete" | $GREP " "` 9332 if test "x$has_space" != x; then 9333 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 9334 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 9335 fi 9336 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9337 fi 9338 fi 9339 9340 # Now join together the path and the arguments once again 9341 if test "x$arguments" != xEOL; then 9342 new_complete="$new_path ${arguments% *}" 9343 else 9344 new_complete="$new_path" 9345 fi 9346 9347 if test "x$complete" != "x$new_complete"; then 9348 FOUND_MAKE="$new_complete" 9349 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 9350 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 9351 fi 9352 9353 fi 9354 fi 9355 fi 9356 fi 9357 9358 if test "x$FOUND_MAKE" = x; then 9359 as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make 3.81 or newer." "$LINENO" 5 9360 fi 9361 else 9362 # Try our hardest to locate a correct version of GNU make 9363 for ac_prog in gmake 9364 do 9365 # Extract the first word of "$ac_prog", so it can be a program name with args. 9366 set dummy $ac_prog; ac_word=$2 9367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9368 $as_echo_n "checking for $ac_word... " >&6; } 9369 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 9370 $as_echo_n "(cached) " >&6 9371 else 9372 case $CHECK_GMAKE in 9373 [\\/]* | ?:[\\/]*) 9374 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 9375 ;; 9376 *) 9377 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9378 for as_dir in $PATH 9379 do 9380 IFS=$as_save_IFS 9381 test -z "$as_dir" && as_dir=. 9382 for ac_exec_ext in '' $ac_executable_extensions; do 9383 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 9384 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 9385 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9386 break 2 9387 fi 9388 done 9389 done 9390 IFS=$as_save_IFS 9391 9392 ;; 9393 esac 9394 fi 9395 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 9396 if test -n "$CHECK_GMAKE"; then 9397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 9398 $as_echo "$CHECK_GMAKE" >&6; } 9399 else 9400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9401 $as_echo "no" >&6; } 9402 fi 9403 9404 9405 test -n "$CHECK_GMAKE" && break 9406 done 9407 9408 9409 MAKE_CANDIDATE=""$CHECK_GMAKE"" 9410 DESCRIPTION="gmake in PATH" 9411 if test "x$MAKE_CANDIDATE" != x; then 9412 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 9413 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 9414 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 9415 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 9416 if test "x$IS_GNU_MAKE" = x; then 9417 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 9418 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 9419 else 9420 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP '3.8[12346789]'` 9421 if test "x$IS_MODERN_MAKE" = x; then 9422 { $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 9423 $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;} 9424 else 9425 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 9426 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9427 MAKE_EXPECTED_ENV='cygwin' 9428 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9429 MAKE_EXPECTED_ENV='msys' 9430 else 9431 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 9432 fi 9433 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 9434 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 9435 else 9436 # Not relevant for non-Windows 9437 IS_MAKE_CORRECT_ENV=true 9438 fi 9439 if test "x$IS_MAKE_CORRECT_ENV" = x; then 9440 { $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 9441 $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;} 9442 else 9443 FOUND_MAKE=$MAKE_CANDIDATE 9444 9445 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9446 9447 # First separate the path from the arguments. This will split at the first 9448 # space. 9449 complete="$FOUND_MAKE" 9450 path="${complete%% *}" 9451 tmp="$complete EOL" 9452 arguments="${tmp#* }" 9453 9454 # Input might be given as Windows format, start by converting to 9455 # unix format. 9456 new_path=`$CYGPATH -u "$path"` 9457 9458 # Now try to locate executable using which 9459 new_path=`$WHICH "$new_path" 2> /dev/null` 9460 # bat and cmd files are not always considered executable in cygwin causing which 9461 # to not find them 9462 if test "x$new_path" = x \ 9463 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 9464 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 9465 new_path=`$CYGPATH -u "$path"` 9466 fi 9467 if test "x$new_path" = x; then 9468 # Oops. Which didn't find the executable. 9469 # The splitting of arguments from the executable at a space might have been incorrect, 9470 # since paths with space are more likely in Windows. Give it another try with the whole 9471 # argument. 9472 path="$complete" 9473 arguments="EOL" 9474 new_path=`$CYGPATH -u "$path"` 9475 new_path=`$WHICH "$new_path" 2> /dev/null` 9476 # bat and cmd files are not always considered executable in cygwin causing which 9477 # to not find them 9478 if test "x$new_path" = x \ 9479 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 9480 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 9481 new_path=`$CYGPATH -u "$path"` 9482 fi 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 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 9497 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 9498 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 9499 # "foo.exe" is OK but "foo" is an error. 9500 # 9501 # This test is therefore slightly more accurate than "test -f" to check for file precense. 9502 # It is also a way to make sure we got the proper file name for the real test later on. 9503 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 9504 if test "x$test_shortpath" = x; then 9505 # Short path failed, file does not exist as specified. 9506 # Try adding .exe or .cmd 9507 if test -f "${new_path}.exe"; then 9508 input_to_shortpath="${new_path}.exe" 9509 elif test -f "${new_path}.cmd"; then 9510 input_to_shortpath="${new_path}.cmd" 9511 else 9512 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 9513 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 9514 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 9515 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 9516 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9517 fi 9518 else 9519 input_to_shortpath="$new_path" 9520 fi 9521 9522 # Call helper function which possibly converts this using DOS-style short mode. 9523 # If so, the updated path is stored in $new_path. 9524 new_path="$input_to_shortpath" 9525 9526 input_path="$input_to_shortpath" 9527 # Check if we need to convert this using DOS-style short mode. If the path 9528 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9529 # take no chances and rewrite it. 9530 # Note: m4 eats our [], so we need to use [ and ] instead. 9531 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 9532 if test "x$has_forbidden_chars" != x; then 9533 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9534 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 9535 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 9536 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 9537 # Going to short mode and back again did indeed matter. Since short mode is 9538 # case insensitive, let's make it lowercase to improve readability. 9539 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9540 # Now convert it back to Unix-stile (cygpath) 9541 input_path=`$CYGPATH -u "$shortmode_path"` 9542 new_path="$input_path" 9543 fi 9544 fi 9545 9546 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 9547 if test "x$test_cygdrive_prefix" = x; then 9548 # As a simple fix, exclude /usr/bin since it's not a real path. 9549 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 9550 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 9551 # a path prefixed by /cygdrive for fixpath to work. 9552 new_path="$CYGWIN_ROOT_PATH$input_path" 9553 fi 9554 fi 9555 9556 # remove trailing .exe if any 9557 new_path="${new_path/%.exe/}" 9558 9559 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9560 9561 # First separate the path from the arguments. This will split at the first 9562 # space. 9563 complete="$FOUND_MAKE" 9564 path="${complete%% *}" 9565 tmp="$complete EOL" 9566 arguments="${tmp#* }" 9567 9568 # Input might be given as Windows format, start by converting to 9569 # unix format. 9570 new_path="$path" 9571 9572 windows_path="$new_path" 9573 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9574 unix_path=`$CYGPATH -u "$windows_path"` 9575 new_path="$unix_path" 9576 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9577 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9578 new_path="$unix_path" 9579 fi 9580 9581 9582 # Now try to locate executable using which 9583 new_path=`$WHICH "$new_path" 2> /dev/null` 9584 9585 if test "x$new_path" = x; then 9586 # Oops. Which didn't find the executable. 9587 # The splitting of arguments from the executable at a space might have been incorrect, 9588 # since paths with space are more likely in Windows. Give it another try with the whole 9589 # argument. 9590 path="$complete" 9591 arguments="EOL" 9592 new_path="$path" 9593 9594 windows_path="$new_path" 9595 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9596 unix_path=`$CYGPATH -u "$windows_path"` 9597 new_path="$unix_path" 9598 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9599 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9600 new_path="$unix_path" 9601 fi 9602 9603 9604 new_path=`$WHICH "$new_path" 2> /dev/null` 9605 9606 if test "x$new_path" = x; then 9607 # It's still not found. Now this is an unrecoverable error. 9608 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9609 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9610 has_space=`$ECHO "$complete" | $GREP " "` 9611 if test "x$has_space" != x; then 9612 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9613 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9614 fi 9615 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9616 fi 9617 fi 9618 9619 # Now new_path has a complete unix path to the binary 9620 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 9621 # Keep paths in /bin as-is, but remove trailing .exe if any 9622 new_path="${new_path/%.exe/}" 9623 # Do not save /bin paths to all_fixpath_prefixes! 9624 else 9625 # Not in mixed or Windows style, start by that. 9626 new_path=`cmd //c echo $new_path` 9627 9628 input_path="$new_path" 9629 # Check if we need to convert this using DOS-style short mode. If the path 9630 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9631 # take no chances and rewrite it. 9632 # Note: m4 eats our [], so we need to use [ and ] instead. 9633 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 9634 if test "x$has_forbidden_chars" != x; then 9635 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9636 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9637 fi 9638 9639 # Output is in $new_path 9640 9641 windows_path="$new_path" 9642 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9643 unix_path=`$CYGPATH -u "$windows_path"` 9644 new_path="$unix_path" 9645 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9646 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9647 new_path="$unix_path" 9648 fi 9649 9650 # remove trailing .exe if any 9651 new_path="${new_path/%.exe/}" 9652 9653 # Save the first 10 bytes of this path to the storage, so fixpath can work. 9654 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 9655 fi 9656 9657 else 9658 # We're on a posix platform. Hooray! :) 9659 # First separate the path from the arguments. This will split at the first 9660 # space. 9661 complete="$FOUND_MAKE" 9662 path="${complete%% *}" 9663 tmp="$complete EOL" 9664 arguments="${tmp#* }" 9665 9666 # Cannot rely on the command "which" here since it doesn't always work. 9667 is_absolute_path=`$ECHO "$path" | $GREP ^/` 9668 if test -z "$is_absolute_path"; then 9669 # Path to executable is not absolute. Find it. 9670 IFS_save="$IFS" 9671 IFS=: 9672 for p in $PATH; do 9673 if test -f "$p/$path" && test -x "$p/$path"; then 9674 new_path="$p/$path" 9675 break 9676 fi 9677 done 9678 IFS="$IFS_save" 9679 else 9680 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5 9681 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;} 9682 new_path="$path" 9683 fi 9684 9685 if test "x$new_path" = x; then 9686 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9687 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9688 has_space=`$ECHO "$complete" | $GREP " "` 9689 if test "x$has_space" != x; then 9690 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 9691 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 9692 fi 9693 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9694 fi 9695 fi 9696 9697 # Now join together the path and the arguments once again 9698 if test "x$arguments" != xEOL; then 9699 new_complete="$new_path ${arguments% *}" 9700 else 9701 new_complete="$new_path" 9702 fi 9703 9704 if test "x$complete" != "x$new_complete"; then 9705 FOUND_MAKE="$new_complete" 9706 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 9707 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 9708 fi 9709 9710 fi 9711 fi 9712 fi 9713 fi 9714 9715 9716 if test "x$FOUND_MAKE" = x; then 9717 for ac_prog in make 9718 do 9719 # Extract the first word of "$ac_prog", so it can be a program name with args. 9720 set dummy $ac_prog; ac_word=$2 9721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9722 $as_echo_n "checking for $ac_word... " >&6; } 9723 if ${ac_cv_path_CHECK_MAKE+:} false; then : 9724 $as_echo_n "(cached) " >&6 9725 else 9726 case $CHECK_MAKE in 9727 [\\/]* | ?:[\\/]*) 9728 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 9729 ;; 9730 *) 9731 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9732 for as_dir in $PATH 9733 do 9734 IFS=$as_save_IFS 9735 test -z "$as_dir" && as_dir=. 9736 for ac_exec_ext in '' $ac_executable_extensions; do 9737 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 9738 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 9739 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9740 break 2 9741 fi 9742 done 9743 done 9744 IFS=$as_save_IFS 9745 9746 ;; 9747 esac 9748 fi 9749 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 9750 if test -n "$CHECK_MAKE"; then 9751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 9752 $as_echo "$CHECK_MAKE" >&6; } 9753 else 9754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9755 $as_echo "no" >&6; } 9756 fi 9757 9758 9759 test -n "$CHECK_MAKE" && break 9760 done 9761 9762 9763 MAKE_CANDIDATE=""$CHECK_MAKE"" 9764 DESCRIPTION="make in PATH" 9765 if test "x$MAKE_CANDIDATE" != x; then 9766 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 9767 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 9768 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 9769 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 9770 if test "x$IS_GNU_MAKE" = x; then 9771 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 9772 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 9773 else 9774 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP '3.8[12346789]'` 9775 if test "x$IS_MODERN_MAKE" = x; then 9776 { $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 9777 $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;} 9778 else 9779 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 9780 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9781 MAKE_EXPECTED_ENV='cygwin' 9782 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9783 MAKE_EXPECTED_ENV='msys' 9784 else 9785 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 9786 fi 9787 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 9788 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 9789 else 9790 # Not relevant for non-Windows 9791 IS_MAKE_CORRECT_ENV=true 9792 fi 9793 if test "x$IS_MAKE_CORRECT_ENV" = x; then 9794 { $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 9795 $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;} 9796 else 9797 FOUND_MAKE=$MAKE_CANDIDATE 9798 9799 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9800 9801 # First separate the path from the arguments. This will split at the first 9802 # space. 9803 complete="$FOUND_MAKE" 9804 path="${complete%% *}" 9805 tmp="$complete EOL" 9806 arguments="${tmp#* }" 9807 9808 # Input might be given as Windows format, start by converting to 9809 # unix format. 9810 new_path=`$CYGPATH -u "$path"` 9811 9812 # Now try to locate executable using which 9813 new_path=`$WHICH "$new_path" 2> /dev/null` 9814 # bat and cmd files are not always considered executable in cygwin causing which 9815 # to not find them 9816 if test "x$new_path" = x \ 9817 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 9818 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 9819 new_path=`$CYGPATH -u "$path"` 9820 fi 9821 if test "x$new_path" = x; then 9822 # Oops. Which didn't find the executable. 9823 # The splitting of arguments from the executable at a space might have been incorrect, 9824 # since paths with space are more likely in Windows. Give it another try with the whole 9825 # argument. 9826 path="$complete" 9827 arguments="EOL" 9828 new_path=`$CYGPATH -u "$path"` 9829 new_path=`$WHICH "$new_path" 2> /dev/null` 9830 # bat and cmd files are not always considered executable in cygwin causing which 9831 # to not find them 9832 if test "x$new_path" = x \ 9833 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 9834 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 9835 new_path=`$CYGPATH -u "$path"` 9836 fi 9837 if test "x$new_path" = x; then 9838 # It's still not found. Now this is an unrecoverable error. 9839 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9840 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9841 has_space=`$ECHO "$complete" | $GREP " "` 9842 if test "x$has_space" != x; then 9843 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9844 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9845 fi 9846 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9847 fi 9848 fi 9849 9850 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 9851 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 9852 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 9853 # "foo.exe" is OK but "foo" is an error. 9854 # 9855 # This test is therefore slightly more accurate than "test -f" to check for file precense. 9856 # It is also a way to make sure we got the proper file name for the real test later on. 9857 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 9858 if test "x$test_shortpath" = x; then 9859 # Short path failed, file does not exist as specified. 9860 # Try adding .exe or .cmd 9861 if test -f "${new_path}.exe"; then 9862 input_to_shortpath="${new_path}.exe" 9863 elif test -f "${new_path}.cmd"; then 9864 input_to_shortpath="${new_path}.cmd" 9865 else 9866 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 9867 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 9868 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 9869 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 9870 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9871 fi 9872 else 9873 input_to_shortpath="$new_path" 9874 fi 9875 9876 # Call helper function which possibly converts this using DOS-style short mode. 9877 # If so, the updated path is stored in $new_path. 9878 new_path="$input_to_shortpath" 9879 9880 input_path="$input_to_shortpath" 9881 # Check if we need to convert this using DOS-style short mode. If the path 9882 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9883 # take no chances and rewrite it. 9884 # Note: m4 eats our [], so we need to use [ and ] instead. 9885 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 9886 if test "x$has_forbidden_chars" != x; then 9887 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9888 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 9889 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 9890 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 9891 # Going to short mode and back again did indeed matter. Since short mode is 9892 # case insensitive, let's make it lowercase to improve readability. 9893 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9894 # Now convert it back to Unix-stile (cygpath) 9895 input_path=`$CYGPATH -u "$shortmode_path"` 9896 new_path="$input_path" 9897 fi 9898 fi 9899 9900 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 9901 if test "x$test_cygdrive_prefix" = x; then 9902 # As a simple fix, exclude /usr/bin since it's not a real path. 9903 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 9904 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 9905 # a path prefixed by /cygdrive for fixpath to work. 9906 new_path="$CYGWIN_ROOT_PATH$input_path" 9907 fi 9908 fi 9909 9910 # remove trailing .exe if any 9911 new_path="${new_path/%.exe/}" 9912 9913 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9914 9915 # First separate the path from the arguments. This will split at the first 9916 # space. 9917 complete="$FOUND_MAKE" 9918 path="${complete%% *}" 9919 tmp="$complete EOL" 9920 arguments="${tmp#* }" 9921 9922 # Input might be given as Windows format, start by converting to 9923 # unix format. 9924 new_path="$path" 9925 9926 windows_path="$new_path" 9927 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9928 unix_path=`$CYGPATH -u "$windows_path"` 9929 new_path="$unix_path" 9930 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9931 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9932 new_path="$unix_path" 9933 fi 9934 9935 9936 # Now try to locate executable using which 9937 new_path=`$WHICH "$new_path" 2> /dev/null` 9938 9939 if test "x$new_path" = x; then 9940 # Oops. Which didn't find the executable. 9941 # The splitting of arguments from the executable at a space might have been incorrect, 9942 # since paths with space are more likely in Windows. Give it another try with the whole 9943 # argument. 9944 path="$complete" 9945 arguments="EOL" 9946 new_path="$path" 9947 9948 windows_path="$new_path" 9949 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9950 unix_path=`$CYGPATH -u "$windows_path"` 9951 new_path="$unix_path" 9952 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9953 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9954 new_path="$unix_path" 9955 fi 9956 9957 9958 new_path=`$WHICH "$new_path" 2> /dev/null` 9959 9960 if test "x$new_path" = x; then 9961 # It's still not found. Now this is an unrecoverable error. 9962 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9963 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9964 has_space=`$ECHO "$complete" | $GREP " "` 9965 if test "x$has_space" != x; then 9966 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9967 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9968 fi 9969 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9970 fi 9971 fi 9972 9973 # Now new_path has a complete unix path to the binary 9974 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 9975 # Keep paths in /bin as-is, but remove trailing .exe if any 9976 new_path="${new_path/%.exe/}" 9977 # Do not save /bin paths to all_fixpath_prefixes! 9978 else 9979 # Not in mixed or Windows style, start by that. 9980 new_path=`cmd //c echo $new_path` 9981 9982 input_path="$new_path" 9983 # Check if we need to convert this using DOS-style short mode. If the path 9984 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9985 # take no chances and rewrite it. 9986 # Note: m4 eats our [], so we need to use [ and ] instead. 9987 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 9988 if test "x$has_forbidden_chars" != x; then 9989 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9990 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9991 fi 9992 9993 # Output is in $new_path 9994 9995 windows_path="$new_path" 9996 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9997 unix_path=`$CYGPATH -u "$windows_path"` 9998 new_path="$unix_path" 9999 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10000 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 10001 new_path="$unix_path" 10002 fi 10003 10004 # remove trailing .exe if any 10005 new_path="${new_path/%.exe/}" 10006 10007 # Save the first 10 bytes of this path to the storage, so fixpath can work. 10008 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 10009 fi 10010 10011 else 10012 # We're on a posix platform. Hooray! :) 10013 # First separate the path from the arguments. This will split at the first 10014 # space. 10015 complete="$FOUND_MAKE" 10016 path="${complete%% *}" 10017 tmp="$complete EOL" 10018 arguments="${tmp#* }" 10019 10020 # Cannot rely on the command "which" here since it doesn't always work. 10021 is_absolute_path=`$ECHO "$path" | $GREP ^/` 10022 if test -z "$is_absolute_path"; then 10023 # Path to executable is not absolute. Find it. 10024 IFS_save="$IFS" 10025 IFS=: 10026 for p in $PATH; do 10027 if test -f "$p/$path" && test -x "$p/$path"; then 10028 new_path="$p/$path" 10029 break 10030 fi 10031 done 10032 IFS="$IFS_save" 10033 else 10034 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5 10035 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;} 10036 new_path="$path" 10037 fi 10038 10039 if test "x$new_path" = x; then 10040 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 10041 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 10042 has_space=`$ECHO "$complete" | $GREP " "` 10043 if test "x$has_space" != x; then 10044 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 10045 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 10046 fi 10047 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 10048 fi 10049 fi 10050 10051 # Now join together the path and the arguments once again 10052 if test "x$arguments" != xEOL; then 10053 new_complete="$new_path ${arguments% *}" 10054 else 10055 new_complete="$new_path" 10056 fi 10057 10058 if test "x$complete" != "x$new_complete"; then 10059 FOUND_MAKE="$new_complete" 10060 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 10061 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 10062 fi 10063 10064 fi 10065 fi 10066 fi 10067 fi 10068 10069 fi 10070 10071 if test "x$FOUND_MAKE" = x; then 10072 if test "x$TOOLS_DIR" != x; then 10073 # We have a tools-dir, check that as well before giving up. 10074 OLD_PATH=$PATH 10075 PATH=$TOOLS_DIR:$PATH 10076 for ac_prog in gmake 10077 do 10078 # Extract the first word of "$ac_prog", so it can be a program name with args. 10079 set dummy $ac_prog; ac_word=$2 10080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10081 $as_echo_n "checking for $ac_word... " >&6; } 10082 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 10083 $as_echo_n "(cached) " >&6 10084 else 10085 case $CHECK_TOOLSDIR_GMAKE in 10086 [\\/]* | ?:[\\/]*) 10087 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 10088 ;; 10089 *) 10090 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10091 for as_dir in $PATH 10092 do 10093 IFS=$as_save_IFS 10094 test -z "$as_dir" && as_dir=. 10095 for ac_exec_ext in '' $ac_executable_extensions; do 10096 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10097 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 10098 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10099 break 2 10100 fi 10101 done 10102 done 10103 IFS=$as_save_IFS 10104 10105 ;; 10106 esac 10107 fi 10108 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 10109 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 10110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 10111 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 10112 else 10113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10114 $as_echo "no" >&6; } 10115 fi 10116 10117 10118 test -n "$CHECK_TOOLSDIR_GMAKE" && break 10119 done 10120 10121 10122 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 10123 DESCRIPTION="gmake in tools-dir" 10124 if test "x$MAKE_CANDIDATE" != x; then 10125 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 10126 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 10127 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 10128 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 10129 if test "x$IS_GNU_MAKE" = x; then 10130 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 10131 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 10132 else 10133 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP '3.8[12346789]'` 10134 if test "x$IS_MODERN_MAKE" = x; then 10135 { $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 10136 $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;} 10137 else 10138 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 10139 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 10140 MAKE_EXPECTED_ENV='cygwin' 10141 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10142 MAKE_EXPECTED_ENV='msys' 10143 else 10144 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 10145 fi 10146 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 10147 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 10148 else 10149 # Not relevant for non-Windows 10150 IS_MAKE_CORRECT_ENV=true 10151 fi 10152 if test "x$IS_MAKE_CORRECT_ENV" = x; then 10153 { $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 10154 $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;} 10155 else 10156 FOUND_MAKE=$MAKE_CANDIDATE 10157 10158 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 10159 10160 # First separate the path from the arguments. This will split at the first 10161 # space. 10162 complete="$FOUND_MAKE" 10163 path="${complete%% *}" 10164 tmp="$complete EOL" 10165 arguments="${tmp#* }" 10166 10167 # Input might be given as Windows format, start by converting to 10168 # unix format. 10169 new_path=`$CYGPATH -u "$path"` 10170 10171 # Now try to locate executable using which 10172 new_path=`$WHICH "$new_path" 2> /dev/null` 10173 # bat and cmd files are not always considered executable in cygwin causing which 10174 # to not find them 10175 if test "x$new_path" = x \ 10176 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 10177 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 10178 new_path=`$CYGPATH -u "$path"` 10179 fi 10180 if test "x$new_path" = x; then 10181 # Oops. Which didn't find the executable. 10182 # The splitting of arguments from the executable at a space might have been incorrect, 10183 # since paths with space are more likely in Windows. Give it another try with the whole 10184 # argument. 10185 path="$complete" 10186 arguments="EOL" 10187 new_path=`$CYGPATH -u "$path"` 10188 new_path=`$WHICH "$new_path" 2> /dev/null` 10189 # bat and cmd files are not always considered executable in cygwin causing which 10190 # to not find them 10191 if test "x$new_path" = x \ 10192 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 10193 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 10194 new_path=`$CYGPATH -u "$path"` 10195 fi 10196 if test "x$new_path" = x; then 10197 # It's still not found. Now this is an unrecoverable error. 10198 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 10199 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 10200 has_space=`$ECHO "$complete" | $GREP " "` 10201 if test "x$has_space" != x; then 10202 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 10203 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 10204 fi 10205 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 10206 fi 10207 fi 10208 10209 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 10210 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 10211 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 10212 # "foo.exe" is OK but "foo" is an error. 10213 # 10214 # This test is therefore slightly more accurate than "test -f" to check for file precense. 10215 # It is also a way to make sure we got the proper file name for the real test later on. 10216 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 10217 if test "x$test_shortpath" = x; then 10218 # Short path failed, file does not exist as specified. 10219 # Try adding .exe or .cmd 10220 if test -f "${new_path}.exe"; then 10221 input_to_shortpath="${new_path}.exe" 10222 elif test -f "${new_path}.cmd"; then 10223 input_to_shortpath="${new_path}.cmd" 10224 else 10225 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 10226 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 10227 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 10228 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 10229 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 10230 fi 10231 else 10232 input_to_shortpath="$new_path" 10233 fi 10234 10235 # Call helper function which possibly converts this using DOS-style short mode. 10236 # If so, the updated path is stored in $new_path. 10237 new_path="$input_to_shortpath" 10238 10239 input_path="$input_to_shortpath" 10240 # Check if we need to convert this using DOS-style short mode. If the path 10241 # contains just simple characters, use it. Otherwise (spaces, weird characters), 10242 # take no chances and rewrite it. 10243 # Note: m4 eats our [], so we need to use [ and ] instead. 10244 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 10245 if test "x$has_forbidden_chars" != x; then 10246 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 10247 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 10248 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 10249 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 10250 # Going to short mode and back again did indeed matter. Since short mode is 10251 # case insensitive, let's make it lowercase to improve readability. 10252 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 10253 # Now convert it back to Unix-stile (cygpath) 10254 input_path=`$CYGPATH -u "$shortmode_path"` 10255 new_path="$input_path" 10256 fi 10257 fi 10258 10259 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 10260 if test "x$test_cygdrive_prefix" = x; then 10261 # As a simple fix, exclude /usr/bin since it's not a real path. 10262 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 10263 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 10264 # a path prefixed by /cygdrive for fixpath to work. 10265 new_path="$CYGWIN_ROOT_PATH$input_path" 10266 fi 10267 fi 10268 10269 # remove trailing .exe if any 10270 new_path="${new_path/%.exe/}" 10271 10272 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10273 10274 # First separate the path from the arguments. This will split at the first 10275 # space. 10276 complete="$FOUND_MAKE" 10277 path="${complete%% *}" 10278 tmp="$complete EOL" 10279 arguments="${tmp#* }" 10280 10281 # Input might be given as Windows format, start by converting to 10282 # unix format. 10283 new_path="$path" 10284 10285 windows_path="$new_path" 10286 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 10287 unix_path=`$CYGPATH -u "$windows_path"` 10288 new_path="$unix_path" 10289 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10290 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 10291 new_path="$unix_path" 10292 fi 10293 10294 10295 # Now try to locate executable using which 10296 new_path=`$WHICH "$new_path" 2> /dev/null` 10297 10298 if test "x$new_path" = x; then 10299 # Oops. Which didn't find the executable. 10300 # The splitting of arguments from the executable at a space might have been incorrect, 10301 # since paths with space are more likely in Windows. Give it another try with the whole 10302 # argument. 10303 path="$complete" 10304 arguments="EOL" 10305 new_path="$path" 10306 10307 windows_path="$new_path" 10308 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 10309 unix_path=`$CYGPATH -u "$windows_path"` 10310 new_path="$unix_path" 10311 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10312 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 10313 new_path="$unix_path" 10314 fi 10315 10316 10317 new_path=`$WHICH "$new_path" 2> /dev/null` 10318 10319 if test "x$new_path" = x; then 10320 # It's still not found. Now this is an unrecoverable error. 10321 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 10322 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 10323 has_space=`$ECHO "$complete" | $GREP " "` 10324 if test "x$has_space" != x; then 10325 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 10326 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 10327 fi 10328 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 10329 fi 10330 fi 10331 10332 # Now new_path has a complete unix path to the binary 10333 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 10334 # Keep paths in /bin as-is, but remove trailing .exe if any 10335 new_path="${new_path/%.exe/}" 10336 # Do not save /bin paths to all_fixpath_prefixes! 10337 else 10338 # Not in mixed or Windows style, start by that. 10339 new_path=`cmd //c echo $new_path` 10340 10341 input_path="$new_path" 10342 # Check if we need to convert this using DOS-style short mode. If the path 10343 # contains just simple characters, use it. Otherwise (spaces, weird characters), 10344 # take no chances and rewrite it. 10345 # Note: m4 eats our [], so we need to use [ and ] instead. 10346 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 10347 if test "x$has_forbidden_chars" != x; then 10348 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 10349 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 10350 fi 10351 10352 # Output is in $new_path 10353 10354 windows_path="$new_path" 10355 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 10356 unix_path=`$CYGPATH -u "$windows_path"` 10357 new_path="$unix_path" 10358 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10359 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 10360 new_path="$unix_path" 10361 fi 10362 10363 # remove trailing .exe if any 10364 new_path="${new_path/%.exe/}" 10365 10366 # Save the first 10 bytes of this path to the storage, so fixpath can work. 10367 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 10368 fi 10369 10370 else 10371 # We're on a posix platform. Hooray! :) 10372 # First separate the path from the arguments. This will split at the first 10373 # space. 10374 complete="$FOUND_MAKE" 10375 path="${complete%% *}" 10376 tmp="$complete EOL" 10377 arguments="${tmp#* }" 10378 10379 # Cannot rely on the command "which" here since it doesn't always work. 10380 is_absolute_path=`$ECHO "$path" | $GREP ^/` 10381 if test -z "$is_absolute_path"; then 10382 # Path to executable is not absolute. Find it. 10383 IFS_save="$IFS" 10384 IFS=: 10385 for p in $PATH; do 10386 if test -f "$p/$path" && test -x "$p/$path"; then 10387 new_path="$p/$path" 10388 break 10389 fi 10390 done 10391 IFS="$IFS_save" 10392 else 10393 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5 10394 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;} 10395 new_path="$path" 10396 fi 10397 10398 if test "x$new_path" = x; then 10399 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 10400 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 10401 has_space=`$ECHO "$complete" | $GREP " "` 10402 if test "x$has_space" != x; then 10403 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 10404 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 10405 fi 10406 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 10407 fi 10408 fi 10409 10410 # Now join together the path and the arguments once again 10411 if test "x$arguments" != xEOL; then 10412 new_complete="$new_path ${arguments% *}" 10413 else 10414 new_complete="$new_path" 10415 fi 10416 10417 if test "x$complete" != "x$new_complete"; then 10418 FOUND_MAKE="$new_complete" 10419 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 10420 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 10421 fi 10422 10423 fi 10424 fi 10425 fi 10426 fi 10427 10428 if test "x$FOUND_MAKE" = x; then 10429 for ac_prog in make 10430 do 10431 # Extract the first word of "$ac_prog", so it can be a program name with args. 10432 set dummy $ac_prog; ac_word=$2 10433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10434 $as_echo_n "checking for $ac_word... " >&6; } 10435 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 10436 $as_echo_n "(cached) " >&6 10437 else 10438 case $CHECK_TOOLSDIR_MAKE in 10439 [\\/]* | ?:[\\/]*) 10440 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 10441 ;; 10442 *) 10443 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10444 for as_dir in $PATH 10445 do 10446 IFS=$as_save_IFS 10447 test -z "$as_dir" && as_dir=. 10448 for ac_exec_ext in '' $ac_executable_extensions; do 10449 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10450 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 10451 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10452 break 2 10453 fi 10454 done 10455 done 10456 IFS=$as_save_IFS 10457 10458 ;; 10459 esac 10460 fi 10461 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 10462 if test -n "$CHECK_TOOLSDIR_MAKE"; then 10463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 10464 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 10465 else 10466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10467 $as_echo "no" >&6; } 10468 fi 10469 10470 10471 test -n "$CHECK_TOOLSDIR_MAKE" && break 10472 done 10473 10474 10475 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 10476 DESCRIPTION="make in tools-dir" 10477 if test "x$MAKE_CANDIDATE" != x; then 10478 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 10479 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 10480 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 10481 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 10482 if test "x$IS_GNU_MAKE" = x; then 10483 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 10484 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 10485 else 10486 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP '3.8[12346789]'` 10487 if test "x$IS_MODERN_MAKE" = x; then 10488 { $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 10489 $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;} 10490 else 10491 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 10492 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 10493 MAKE_EXPECTED_ENV='cygwin' 10494 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10495 MAKE_EXPECTED_ENV='msys' 10496 else 10497 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 10498 fi 10499 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 10500 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 10501 else 10502 # Not relevant for non-Windows 10503 IS_MAKE_CORRECT_ENV=true 10504 fi 10505 if test "x$IS_MAKE_CORRECT_ENV" = x; then 10506 { $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 10507 $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;} 10508 else 10509 FOUND_MAKE=$MAKE_CANDIDATE 10510 10511 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 10512 10513 # First separate the path from the arguments. This will split at the first 10514 # space. 10515 complete="$FOUND_MAKE" 10516 path="${complete%% *}" 10517 tmp="$complete EOL" 10518 arguments="${tmp#* }" 10519 10520 # Input might be given as Windows format, start by converting to 10521 # unix format. 10522 new_path=`$CYGPATH -u "$path"` 10523 10524 # Now try to locate executable using which 10525 new_path=`$WHICH "$new_path" 2> /dev/null` 10526 # bat and cmd files are not always considered executable in cygwin causing which 10527 # to not find them 10528 if test "x$new_path" = x \ 10529 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 10530 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 10531 new_path=`$CYGPATH -u "$path"` 10532 fi 10533 if test "x$new_path" = x; then 10534 # Oops. Which didn't find the executable. 10535 # The splitting of arguments from the executable at a space might have been incorrect, 10536 # since paths with space are more likely in Windows. Give it another try with the whole 10537 # argument. 10538 path="$complete" 10539 arguments="EOL" 10540 new_path=`$CYGPATH -u "$path"` 10541 new_path=`$WHICH "$new_path" 2> /dev/null` 10542 # bat and cmd files are not always considered executable in cygwin causing which 10543 # to not find them 10544 if test "x$new_path" = x \ 10545 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 10546 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 10547 new_path=`$CYGPATH -u "$path"` 10548 fi 10549 if test "x$new_path" = x; then 10550 # It's still not found. Now this is an unrecoverable error. 10551 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 10552 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 10553 has_space=`$ECHO "$complete" | $GREP " "` 10554 if test "x$has_space" != x; then 10555 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 10556 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 10557 fi 10558 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 10559 fi 10560 fi 10561 10562 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 10563 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 10564 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 10565 # "foo.exe" is OK but "foo" is an error. 10566 # 10567 # This test is therefore slightly more accurate than "test -f" to check for file precense. 10568 # It is also a way to make sure we got the proper file name for the real test later on. 10569 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 10570 if test "x$test_shortpath" = x; then 10571 # Short path failed, file does not exist as specified. 10572 # Try adding .exe or .cmd 10573 if test -f "${new_path}.exe"; then 10574 input_to_shortpath="${new_path}.exe" 10575 elif test -f "${new_path}.cmd"; then 10576 input_to_shortpath="${new_path}.cmd" 10577 else 10578 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 10579 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 10580 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 10581 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 10582 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 10583 fi 10584 else 10585 input_to_shortpath="$new_path" 10586 fi 10587 10588 # Call helper function which possibly converts this using DOS-style short mode. 10589 # If so, the updated path is stored in $new_path. 10590 new_path="$input_to_shortpath" 10591 10592 input_path="$input_to_shortpath" 10593 # Check if we need to convert this using DOS-style short mode. If the path 10594 # contains just simple characters, use it. Otherwise (spaces, weird characters), 10595 # take no chances and rewrite it. 10596 # Note: m4 eats our [], so we need to use [ and ] instead. 10597 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 10598 if test "x$has_forbidden_chars" != x; then 10599 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 10600 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 10601 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 10602 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 10603 # Going to short mode and back again did indeed matter. Since short mode is 10604 # case insensitive, let's make it lowercase to improve readability. 10605 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 10606 # Now convert it back to Unix-stile (cygpath) 10607 input_path=`$CYGPATH -u "$shortmode_path"` 10608 new_path="$input_path" 10609 fi 10610 fi 10611 10612 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 10613 if test "x$test_cygdrive_prefix" = x; then 10614 # As a simple fix, exclude /usr/bin since it's not a real path. 10615 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 10616 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 10617 # a path prefixed by /cygdrive for fixpath to work. 10618 new_path="$CYGWIN_ROOT_PATH$input_path" 10619 fi 10620 fi 10621 10622 # remove trailing .exe if any 10623 new_path="${new_path/%.exe/}" 10624 10625 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10626 10627 # First separate the path from the arguments. This will split at the first 10628 # space. 10629 complete="$FOUND_MAKE" 10630 path="${complete%% *}" 10631 tmp="$complete EOL" 10632 arguments="${tmp#* }" 10633 10634 # Input might be given as Windows format, start by converting to 10635 # unix format. 10636 new_path="$path" 10637 10638 windows_path="$new_path" 10639 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 10640 unix_path=`$CYGPATH -u "$windows_path"` 10641 new_path="$unix_path" 10642 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10643 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 10644 new_path="$unix_path" 10645 fi 10646 10647 10648 # Now try to locate executable using which 10649 new_path=`$WHICH "$new_path" 2> /dev/null` 10650 10651 if test "x$new_path" = x; then 10652 # Oops. Which didn't find the executable. 10653 # The splitting of arguments from the executable at a space might have been incorrect, 10654 # since paths with space are more likely in Windows. Give it another try with the whole 10655 # argument. 10656 path="$complete" 10657 arguments="EOL" 10658 new_path="$path" 10659 10660 windows_path="$new_path" 10661 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 10662 unix_path=`$CYGPATH -u "$windows_path"` 10663 new_path="$unix_path" 10664 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10665 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 10666 new_path="$unix_path" 10667 fi 10668 10669 10670 new_path=`$WHICH "$new_path" 2> /dev/null` 10671 10672 if test "x$new_path" = x; then 10673 # It's still not found. Now this is an unrecoverable error. 10674 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 10675 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 10676 has_space=`$ECHO "$complete" | $GREP " "` 10677 if test "x$has_space" != x; then 10678 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 10679 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 10680 fi 10681 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 10682 fi 10683 fi 10684 10685 # Now new_path has a complete unix path to the binary 10686 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 10687 # Keep paths in /bin as-is, but remove trailing .exe if any 10688 new_path="${new_path/%.exe/}" 10689 # Do not save /bin paths to all_fixpath_prefixes! 10690 else 10691 # Not in mixed or Windows style, start by that. 10692 new_path=`cmd //c echo $new_path` 10693 10694 input_path="$new_path" 10695 # Check if we need to convert this using DOS-style short mode. If the path 10696 # contains just simple characters, use it. Otherwise (spaces, weird characters), 10697 # take no chances and rewrite it. 10698 # Note: m4 eats our [], so we need to use [ and ] instead. 10699 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 10700 if test "x$has_forbidden_chars" != x; then 10701 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 10702 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 10703 fi 10704 10705 # Output is in $new_path 10706 10707 windows_path="$new_path" 10708 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 10709 unix_path=`$CYGPATH -u "$windows_path"` 10710 new_path="$unix_path" 10711 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 10712 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 10713 new_path="$unix_path" 10714 fi 10715 10716 # remove trailing .exe if any 10717 new_path="${new_path/%.exe/}" 10718 10719 # Save the first 10 bytes of this path to the storage, so fixpath can work. 10720 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 10721 fi 10722 10723 else 10724 # We're on a posix platform. Hooray! :) 10725 # First separate the path from the arguments. This will split at the first 10726 # space. 10727 complete="$FOUND_MAKE" 10728 path="${complete%% *}" 10729 tmp="$complete EOL" 10730 arguments="${tmp#* }" 10731 10732 # Cannot rely on the command "which" here since it doesn't always work. 10733 is_absolute_path=`$ECHO "$path" | $GREP ^/` 10734 if test -z "$is_absolute_path"; then 10735 # Path to executable is not absolute. Find it. 10736 IFS_save="$IFS" 10737 IFS=: 10738 for p in $PATH; do 10739 if test -f "$p/$path" && test -x "$p/$path"; then 10740 new_path="$p/$path" 10741 break 10742 fi 10743 done 10744 IFS="$IFS_save" 10745 else 10746 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5 10747 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;} 10748 new_path="$path" 10749 fi 10750 10751 if test "x$new_path" = x; then 10752 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 10753 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 10754 has_space=`$ECHO "$complete" | $GREP " "` 10755 if test "x$has_space" != x; then 10756 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 10757 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 10758 fi 10759 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 10760 fi 10761 fi 10762 10763 # Now join together the path and the arguments once again 10764 if test "x$arguments" != xEOL; then 10765 new_complete="$new_path ${arguments% *}" 10766 else 10767 new_complete="$new_path" 10768 fi 10769 10770 if test "x$complete" != "x$new_complete"; then 10771 FOUND_MAKE="$new_complete" 10772 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 10773 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 10774 fi 10775 10776 fi 10777 fi 10778 fi 10779 fi 10780 10781 fi 10782 PATH=$OLD_PATH 10783 fi 10784 fi 10785 10786 if test "x$FOUND_MAKE" = x; then 10787 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 10788 fi 10789 fi 10790 10791 MAKE=$FOUND_MAKE 10792 10793 { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5 10794 $as_echo "$as_me: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;} 10795 10796 10797 10798 # Test if find supports -delete 10799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5 10800 $as_echo_n "checking if find supports -delete... " >&6; } 10801 FIND_DELETE="-delete" 10802 10803 DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?) 10804 10805 echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete 10806 10807 TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1` 10808 if test -f $DELETEDIR/TestIfFindSupportsDelete; then 10809 # No, it does not. 10810 rm $DELETEDIR/TestIfFindSupportsDelete 10811 FIND_DELETE="-exec rm \{\} \+" 10812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10813 $as_echo "no" >&6; } 10814 else 10815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10816 $as_echo "yes" >&6; } 10817 fi 10818 rmdir $DELETEDIR 10819 10820 10821 10822 # These tools might not be installed by default, 10823 # need hint on how to install them. 10824 10825 for ac_prog in unzip 10826 do 10827 # Extract the first word of "$ac_prog", so it can be a program name with args. 10828 set dummy $ac_prog; ac_word=$2 10829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10830 $as_echo_n "checking for $ac_word... " >&6; } 10831 if ${ac_cv_path_UNZIP+:} false; then : 10832 $as_echo_n "(cached) " >&6 10833 else 10834 case $UNZIP in 10835 [\\/]* | ?:[\\/]*) 10836 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 10837 ;; 10838 *) 10839 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10840 for as_dir in $PATH 10841 do 10842 IFS=$as_save_IFS 10843 test -z "$as_dir" && as_dir=. 10844 for ac_exec_ext in '' $ac_executable_extensions; do 10845 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10846 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 10847 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10848 break 2 10849 fi 10850 done 10851 done 10852 IFS=$as_save_IFS 10853 10854 ;; 10855 esac 10856 fi 10857 UNZIP=$ac_cv_path_UNZIP 10858 if test -n "$UNZIP"; then 10859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 10860 $as_echo "$UNZIP" >&6; } 10861 else 10862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10863 $as_echo "no" >&6; } 10864 fi 10865 10866 10867 test -n "$UNZIP" && break 10868 done 10869 10870 10871 if test "x$UNZIP" = x; then 10872 if test "xunzip" = x; then 10873 PROG_NAME=unzip 10874 else 10875 PROG_NAME=unzip 10876 fi 10877 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 10878 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 10879 as_fn_error $? "Cannot continue" "$LINENO" 5 10880 fi 10881 10882 10883 10884 for ac_prog in zip 10885 do 10886 # Extract the first word of "$ac_prog", so it can be a program name with args. 10887 set dummy $ac_prog; ac_word=$2 10888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10889 $as_echo_n "checking for $ac_word... " >&6; } 10890 if ${ac_cv_path_ZIP+:} false; then : 10891 $as_echo_n "(cached) " >&6 10892 else 10893 case $ZIP in 10894 [\\/]* | ?:[\\/]*) 10895 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 10896 ;; 10897 *) 10898 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10899 for as_dir in $PATH 10900 do 10901 IFS=$as_save_IFS 10902 test -z "$as_dir" && as_dir=. 10903 for ac_exec_ext in '' $ac_executable_extensions; do 10904 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10905 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 10906 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10907 break 2 10908 fi 10909 done 10910 done 10911 IFS=$as_save_IFS 10912 10913 ;; 10914 esac 10915 fi 10916 ZIP=$ac_cv_path_ZIP 10917 if test -n "$ZIP"; then 10918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 10919 $as_echo "$ZIP" >&6; } 10920 else 10921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10922 $as_echo "no" >&6; } 10923 fi 10924 10925 10926 test -n "$ZIP" && break 10927 done 10928 10929 10930 if test "x$ZIP" = x; then 10931 if test "xzip" = x; then 10932 PROG_NAME=zip 10933 else 10934 PROG_NAME=zip 10935 fi 10936 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 10937 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 10938 as_fn_error $? "Cannot continue" "$LINENO" 5 10939 fi 10940 10941 10942 10943 # Non-required basic tools 10944 10945 # Extract the first word of "ldd", so it can be a program name with args. 10946 set dummy ldd; ac_word=$2 10947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10948 $as_echo_n "checking for $ac_word... " >&6; } 10949 if ${ac_cv_path_LDD+:} false; then : 10950 $as_echo_n "(cached) " >&6 10951 else 10952 case $LDD in 10953 [\\/]* | ?:[\\/]*) 10954 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 10955 ;; 10956 *) 10957 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10958 for as_dir in $PATH 10959 do 10960 IFS=$as_save_IFS 10961 test -z "$as_dir" && as_dir=. 10962 for ac_exec_ext in '' $ac_executable_extensions; do 10963 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10964 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 10965 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10966 break 2 10967 fi 10968 done 10969 done 10970 IFS=$as_save_IFS 10971 10972 ;; 10973 esac 10974 fi 10975 LDD=$ac_cv_path_LDD 10976 if test -n "$LDD"; then 10977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 10978 $as_echo "$LDD" >&6; } 10979 else 10980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10981 $as_echo "no" >&6; } 10982 fi 10983 10984 10985 if test "x$LDD" = "x"; then 10986 # List shared lib dependencies is used for 10987 # debug output and checking for forbidden dependencies. 10988 # We can build without it. 10989 LDD="true" 10990 fi 10991 # Extract the first word of "otool", so it can be a program name with args. 10992 set dummy otool; ac_word=$2 10993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10994 $as_echo_n "checking for $ac_word... " >&6; } 10995 if ${ac_cv_path_OTOOL+:} false; then : 10996 $as_echo_n "(cached) " >&6 10997 else 10998 case $OTOOL in 10999 [\\/]* | ?:[\\/]*) 11000 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 11001 ;; 11002 *) 11003 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11004 for as_dir in $PATH 11005 do 11006 IFS=$as_save_IFS 11007 test -z "$as_dir" && as_dir=. 11008 for ac_exec_ext in '' $ac_executable_extensions; do 11009 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11010 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 11011 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11012 break 2 11013 fi 11014 done 11015 done 11016 IFS=$as_save_IFS 11017 11018 ;; 11019 esac 11020 fi 11021 OTOOL=$ac_cv_path_OTOOL 11022 if test -n "$OTOOL"; then 11023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 11024 $as_echo "$OTOOL" >&6; } 11025 else 11026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11027 $as_echo "no" >&6; } 11028 fi 11029 11030 11031 if test "x$OTOOL" = "x"; then 11032 OTOOL="true" 11033 fi 11034 for ac_prog in readelf greadelf 11035 do 11036 # Extract the first word of "$ac_prog", so it can be a program name with args. 11037 set dummy $ac_prog; ac_word=$2 11038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11039 $as_echo_n "checking for $ac_word... " >&6; } 11040 if ${ac_cv_path_READELF+:} false; then : 11041 $as_echo_n "(cached) " >&6 11042 else 11043 case $READELF in 11044 [\\/]* | ?:[\\/]*) 11045 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 11046 ;; 11047 *) 11048 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11049 for as_dir in $PATH 11050 do 11051 IFS=$as_save_IFS 11052 test -z "$as_dir" && as_dir=. 11053 for ac_exec_ext in '' $ac_executable_extensions; do 11054 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11055 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 11056 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11057 break 2 11058 fi 11059 done 11060 done 11061 IFS=$as_save_IFS 11062 11063 ;; 11064 esac 11065 fi 11066 READELF=$ac_cv_path_READELF 11067 if test -n "$READELF"; then 11068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 11069 $as_echo "$READELF" >&6; } 11070 else 11071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11072 $as_echo "no" >&6; } 11073 fi 11074 11075 11076 test -n "$READELF" && break 11077 done 11078 11079 # Extract the first word of "hg", so it can be a program name with args. 11080 set dummy hg; ac_word=$2 11081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11082 $as_echo_n "checking for $ac_word... " >&6; } 11083 if ${ac_cv_path_HG+:} false; then : 11084 $as_echo_n "(cached) " >&6 11085 else 11086 case $HG in 11087 [\\/]* | ?:[\\/]*) 11088 ac_cv_path_HG="$HG" # Let the user override the test with a path. 11089 ;; 11090 *) 11091 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11092 for as_dir in $PATH 11093 do 11094 IFS=$as_save_IFS 11095 test -z "$as_dir" && as_dir=. 11096 for ac_exec_ext in '' $ac_executable_extensions; do 11097 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11098 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 11099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11100 break 2 11101 fi 11102 done 11103 done 11104 IFS=$as_save_IFS 11105 11106 ;; 11107 esac 11108 fi 11109 HG=$ac_cv_path_HG 11110 if test -n "$HG"; then 11111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 11112 $as_echo "$HG" >&6; } 11113 else 11114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11115 $as_echo "no" >&6; } 11116 fi 11117 11118 11119 # Extract the first word of "stat", so it can be a program name with args. 11120 set dummy stat; ac_word=$2 11121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11122 $as_echo_n "checking for $ac_word... " >&6; } 11123 if ${ac_cv_path_STAT+:} false; then : 11124 $as_echo_n "(cached) " >&6 11125 else 11126 case $STAT in 11127 [\\/]* | ?:[\\/]*) 11128 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 11129 ;; 11130 *) 11131 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11132 for as_dir in $PATH 11133 do 11134 IFS=$as_save_IFS 11135 test -z "$as_dir" && as_dir=. 11136 for ac_exec_ext in '' $ac_executable_extensions; do 11137 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11138 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 11139 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11140 break 2 11141 fi 11142 done 11143 done 11144 IFS=$as_save_IFS 11145 11146 ;; 11147 esac 11148 fi 11149 STAT=$ac_cv_path_STAT 11150 if test -n "$STAT"; then 11151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 11152 $as_echo "$STAT" >&6; } 11153 else 11154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11155 $as_echo "no" >&6; } 11156 fi 11157 11158 11159 # Extract the first word of "time", so it can be a program name with args. 11160 set dummy time; ac_word=$2 11161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11162 $as_echo_n "checking for $ac_word... " >&6; } 11163 if ${ac_cv_path_TIME+:} false; then : 11164 $as_echo_n "(cached) " >&6 11165 else 11166 case $TIME in 11167 [\\/]* | ?:[\\/]*) 11168 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 11169 ;; 11170 *) 11171 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11172 for as_dir in $PATH 11173 do 11174 IFS=$as_save_IFS 11175 test -z "$as_dir" && as_dir=. 11176 for ac_exec_ext in '' $ac_executable_extensions; do 11177 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11178 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 11179 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11180 break 2 11181 fi 11182 done 11183 done 11184 IFS=$as_save_IFS 11185 11186 ;; 11187 esac 11188 fi 11189 TIME=$ac_cv_path_TIME 11190 if test -n "$TIME"; then 11191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 11192 $as_echo "$TIME" >&6; } 11193 else 11194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11195 $as_echo "no" >&6; } 11196 fi 11197 11198 11199 11200 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 11201 11202 for ac_prog in comm 11203 do 11204 # Extract the first word of "$ac_prog", so it can be a program name with args. 11205 set dummy $ac_prog; ac_word=$2 11206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11207 $as_echo_n "checking for $ac_word... " >&6; } 11208 if ${ac_cv_path_COMM+:} false; then : 11209 $as_echo_n "(cached) " >&6 11210 else 11211 case $COMM in 11212 [\\/]* | ?:[\\/]*) 11213 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 11214 ;; 11215 *) 11216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11217 for as_dir in $PATH 11218 do 11219 IFS=$as_save_IFS 11220 test -z "$as_dir" && as_dir=. 11221 for ac_exec_ext in '' $ac_executable_extensions; do 11222 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11223 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 11224 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11225 break 2 11226 fi 11227 done 11228 done 11229 IFS=$as_save_IFS 11230 11231 ;; 11232 esac 11233 fi 11234 COMM=$ac_cv_path_COMM 11235 if test -n "$COMM"; then 11236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 11237 $as_echo "$COMM" >&6; } 11238 else 11239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11240 $as_echo "no" >&6; } 11241 fi 11242 11243 11244 test -n "$COMM" && break 11245 done 11246 11247 11248 if test "x$COMM" = x; then 11249 if test "xcomm" = x; then 11250 PROG_NAME=comm 11251 else 11252 PROG_NAME=comm 11253 fi 11254 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 11255 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 11256 as_fn_error $? "Cannot continue" "$LINENO" 5 11257 fi 11258 11259 11260 fi 11261 11262 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 11263 11264 for ac_prog in xattr 11265 do 11266 # Extract the first word of "$ac_prog", so it can be a program name with args. 11267 set dummy $ac_prog; ac_word=$2 11268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11269 $as_echo_n "checking for $ac_word... " >&6; } 11270 if ${ac_cv_path_XATTR+:} false; then : 11271 $as_echo_n "(cached) " >&6 11272 else 11273 case $XATTR in 11274 [\\/]* | ?:[\\/]*) 11275 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 11276 ;; 11277 *) 11278 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11279 for as_dir in $PATH 11280 do 11281 IFS=$as_save_IFS 11282 test -z "$as_dir" && as_dir=. 11283 for ac_exec_ext in '' $ac_executable_extensions; do 11284 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11285 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 11286 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11287 break 2 11288 fi 11289 done 11290 done 11291 IFS=$as_save_IFS 11292 11293 ;; 11294 esac 11295 fi 11296 XATTR=$ac_cv_path_XATTR 11297 if test -n "$XATTR"; then 11298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 11299 $as_echo "$XATTR" >&6; } 11300 else 11301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11302 $as_echo "no" >&6; } 11303 fi 11304 11305 11306 test -n "$XATTR" && break 11307 done 11308 11309 11310 if test "x$XATTR" = x; then 11311 if test "xxattr" = x; then 11312 PROG_NAME=xattr 11313 else 11314 PROG_NAME=xattr 11315 fi 11316 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 11317 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 11318 as_fn_error $? "Cannot continue" "$LINENO" 5 11319 fi 11320 11321 11322 fi 11323 11324 11325 # Check if pkg-config is available. 11326 11327 11328 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 11329 if test -n "$ac_tool_prefix"; then 11330 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 11331 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 11332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11333 $as_echo_n "checking for $ac_word... " >&6; } 11334 if ${ac_cv_path_PKG_CONFIG+:} false; then : 11335 $as_echo_n "(cached) " >&6 11336 else 11337 case $PKG_CONFIG in 11338 [\\/]* | ?:[\\/]*) 11339 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. 11340 ;; 11341 *) 11342 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11343 for as_dir in $PATH 11344 do 11345 IFS=$as_save_IFS 11346 test -z "$as_dir" && as_dir=. 11347 for ac_exec_ext in '' $ac_executable_extensions; do 11348 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11349 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 11350 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11351 break 2 11352 fi 11353 done 11354 done 11355 IFS=$as_save_IFS 11356 11357 ;; 11358 esac 11359 fi 11360 PKG_CONFIG=$ac_cv_path_PKG_CONFIG 11361 if test -n "$PKG_CONFIG"; then 11362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 11363 $as_echo "$PKG_CONFIG" >&6; } 11364 else 11365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11366 $as_echo "no" >&6; } 11367 fi 11368 11369 11370 fi 11371 if test -z "$ac_cv_path_PKG_CONFIG"; then 11372 ac_pt_PKG_CONFIG=$PKG_CONFIG 11373 # Extract the first word of "pkg-config", so it can be a program name with args. 11374 set dummy pkg-config; ac_word=$2 11375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11376 $as_echo_n "checking for $ac_word... " >&6; } 11377 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : 11378 $as_echo_n "(cached) " >&6 11379 else 11380 case $ac_pt_PKG_CONFIG in 11381 [\\/]* | ?:[\\/]*) 11382 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. 11383 ;; 11384 *) 11385 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11386 for as_dir in $PATH 11387 do 11388 IFS=$as_save_IFS 11389 test -z "$as_dir" && as_dir=. 11390 for ac_exec_ext in '' $ac_executable_extensions; do 11391 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11392 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 11393 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11394 break 2 11395 fi 11396 done 11397 done 11398 IFS=$as_save_IFS 11399 11400 ;; 11401 esac 11402 fi 11403 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG 11404 if test -n "$ac_pt_PKG_CONFIG"; then 11405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 11406 $as_echo "$ac_pt_PKG_CONFIG" >&6; } 11407 else 11408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11409 $as_echo "no" >&6; } 11410 fi 11411 11412 if test "x$ac_pt_PKG_CONFIG" = x; then 11413 PKG_CONFIG="" 11414 else 11415 case $cross_compiling:$ac_tool_warned in 11416 yes:) 11417 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 11418 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 11419 ac_tool_warned=yes ;; 11420 esac 11421 PKG_CONFIG=$ac_pt_PKG_CONFIG 11422 fi 11423 else 11424 PKG_CONFIG="$ac_cv_path_PKG_CONFIG" 11425 fi 11426 11427 fi 11428 if test -n "$PKG_CONFIG"; then 11429 _pkg_min_version=0.9.0 11430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 11431 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } 11432 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 11433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 11434 $as_echo "yes" >&6; } 11435 else 11436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11437 $as_echo "no" >&6; } 11438 PKG_CONFIG="" 11439 fi 11440 11441 fi 11442 11443 # After basic tools have been setup, we can check build os specific details. 11444 11445 ############################################################################### 11446 11447 # Note that this is the build platform OS version! 11448 11449 OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`" 11450 OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`" 11451 OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`" 11452 OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`" 11453 11454 11455 11456 11457 11458 # Setup builddeps, for automatic downloading of tools we need. 11459 # This is needed before we can call BDEPS_CHECK_MODULE, which is done in 11460 # boot-jdk setup, but we need to have basic tools setup first. 11461 11462 11463 # Check whether --with-builddeps-conf was given. 11464 if test "${with_builddeps_conf+set}" = set; then : 11465 withval=$with_builddeps_conf; 11466 fi 11467 11468 11469 11470 # Check whether --with-builddeps-server was given. 11471 if test "${with_builddeps_server+set}" = set; then : 11472 withval=$with_builddeps_server; 11473 fi 11474 11475 11476 11477 # Check whether --with-builddeps-dir was given. 11478 if test "${with_builddeps_dir+set}" = set; then : 11479 withval=$with_builddeps_dir; 11480 else 11481 with_builddeps_dir=/localhome/builddeps 11482 fi 11483 11484 11485 11486 # Check whether --with-builddeps-group was given. 11487 if test "${with_builddeps_group+set}" = set; then : 11488 withval=$with_builddeps_group; 11489 fi 11490 11491 11492 11493 11494 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 11495 if test "x$with_builddeps_conf" != x; then 11496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for supplied builddeps configuration file" >&5 11497 $as_echo_n "checking for supplied builddeps configuration file... " >&6; } 11498 builddepsfile=$with_builddeps_conf 11499 if test -s $builddepsfile; then 11500 . $builddepsfile 11501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: loaded!" >&5 11502 $as_echo "loaded!" >&6; } 11503 else 11504 as_fn_error $? "The given builddeps conf file $with_builddeps_conf could not be loaded!" "$LINENO" 5 11505 fi 11506 else 11507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builddeps.conf files in sources..." >&5 11508 $as_echo_n "checking for builddeps.conf files in sources...... " >&6; } 11509 builddepsfile=`mktemp` 11510 touch $builddepsfile 11511 # Put all found confs into a single file. 11512 find ${SRC_ROOT} -name builddeps.conf -exec cat \{\} \; >> $builddepsfile 11513 # Source the file to acquire the variables 11514 if test -s $builddepsfile; then 11515 . $builddepsfile 11516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found at least one!" >&5 11517 $as_echo "found at least one!" >&6; } 11518 else 11519 as_fn_error $? "Could not find any builddeps.conf at all!" "$LINENO" 5 11520 fi 11521 fi 11522 # Create build and target names that use _ instead of "-" and ".". 11523 # This is necessary to use them in variable names. 11524 build_var=`echo ${OPENJDK_BUILD_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'` 11525 target_var=`echo ${OPENJDK_TARGET_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'` 11526 # Extract rewrite information for build and target 11527 eval rewritten_build=\${REWRITE_${build_var}} 11528 if test "x$rewritten_build" = x; then 11529 rewritten_build=${OPENJDK_BUILD_AUTOCONF_NAME} 11530 echo Build stays the same $rewritten_build 11531 else 11532 echo Rewriting build for builddeps into $rewritten_build 11533 fi 11534 eval rewritten_target=\${REWRITE_${target_var}} 11535 if test "x$rewritten_target" = x; then 11536 rewritten_target=${OPENJDK_TARGET_AUTOCONF_NAME} 11537 echo Target stays the same $rewritten_target 11538 else 11539 echo Rewriting target for builddeps into $rewritten_target 11540 fi 11541 rewritten_build_var=`echo ${rewritten_build} | tr '-' '_' | tr '.' '_'` 11542 rewritten_target_var=`echo ${rewritten_target} | tr '-' '_' | tr '.' '_'` 11543 fi 11544 for ac_prog in 7z unzip 11545 do 11546 # Extract the first word of "$ac_prog", so it can be a program name with args. 11547 set dummy $ac_prog; ac_word=$2 11548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11549 $as_echo_n "checking for $ac_word... " >&6; } 11550 if ${ac_cv_prog_BDEPS_UNZIP+:} false; then : 11551 $as_echo_n "(cached) " >&6 11552 else 11553 if test -n "$BDEPS_UNZIP"; then 11554 ac_cv_prog_BDEPS_UNZIP="$BDEPS_UNZIP" # Let the user override the test. 11555 else 11556 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11557 for as_dir in $PATH 11558 do 11559 IFS=$as_save_IFS 11560 test -z "$as_dir" && as_dir=. 11561 for ac_exec_ext in '' $ac_executable_extensions; do 11562 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11563 ac_cv_prog_BDEPS_UNZIP="$ac_prog" 11564 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11565 break 2 11566 fi 11567 done 11568 done 11569 IFS=$as_save_IFS 11570 11571 fi 11572 fi 11573 BDEPS_UNZIP=$ac_cv_prog_BDEPS_UNZIP 11574 if test -n "$BDEPS_UNZIP"; then 11575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_UNZIP" >&5 11576 $as_echo "$BDEPS_UNZIP" >&6; } 11577 else 11578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11579 $as_echo "no" >&6; } 11580 fi 11581 11582 11583 test -n "$BDEPS_UNZIP" && break 11584 done 11585 11586 if test "x$BDEPS_UNZIP" = x7z; then 11587 BDEPS_UNZIP="7z x" 11588 fi 11589 11590 for ac_prog in wget lftp ftp 11591 do 11592 # Extract the first word of "$ac_prog", so it can be a program name with args. 11593 set dummy $ac_prog; ac_word=$2 11594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11595 $as_echo_n "checking for $ac_word... " >&6; } 11596 if ${ac_cv_prog_BDEPS_FTP+:} false; then : 11597 $as_echo_n "(cached) " >&6 11598 else 11599 if test -n "$BDEPS_FTP"; then 11600 ac_cv_prog_BDEPS_FTP="$BDEPS_FTP" # Let the user override the test. 11601 else 11602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11603 for as_dir in $PATH 11604 do 11605 IFS=$as_save_IFS 11606 test -z "$as_dir" && as_dir=. 11607 for ac_exec_ext in '' $ac_executable_extensions; do 11608 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 11609 ac_cv_prog_BDEPS_FTP="$ac_prog" 11610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11611 break 2 11612 fi 11613 done 11614 done 11615 IFS=$as_save_IFS 11616 11617 fi 11618 fi 11619 BDEPS_FTP=$ac_cv_prog_BDEPS_FTP 11620 if test -n "$BDEPS_FTP"; then 11621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_FTP" >&5 11622 $as_echo "$BDEPS_FTP" >&6; } 11623 else 11624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11625 $as_echo "no" >&6; } 11626 fi 11627 11628 11629 test -n "$BDEPS_FTP" && break 11630 done 11631 11632 11633 11634 ############################################################################### 11635 # 11636 # Determine OpenJDK variants, options and version numbers. 11637 # 11638 ############################################################################### 11639 11640 # We need build & target for this. 11641 11642 11643 ############################################################################### 11644 # 11645 # Should we build a JDK/JVM with headful support (ie a graphical ui)? 11646 # We always build headless support. 11647 # 11648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking headful support" >&5 11649 $as_echo_n "checking headful support... " >&6; } 11650 # Check whether --enable-headful was given. 11651 if test "${enable_headful+set}" = set; then : 11652 enableval=$enable_headful; SUPPORT_HEADFUL=${enable_headful} 11653 else 11654 SUPPORT_HEADFUL=yes 11655 fi 11656 11657 11658 SUPPORT_HEADLESS=yes 11659 BUILD_HEADLESS="BUILD_HEADLESS:=true" 11660 11661 if test "x$SUPPORT_HEADFUL" = xyes; then 11662 # We are building both headful and headless. 11663 headful_msg="inlude support for both headful and headless" 11664 fi 11665 11666 if test "x$SUPPORT_HEADFUL" = xno; then 11667 # Thus we are building headless only. 11668 BUILD_HEADLESS="BUILD_HEADLESS:=true" 11669 headful_msg="headless only" 11670 fi 11671 11672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $headful_msg" >&5 11673 $as_echo "$headful_msg" >&6; } 11674 11675 11676 11677 11678 11679 # Control wether Hotspot runs Queens test after build. 11680 # Check whether --enable-hotspot-test-in-build was given. 11681 if test "${enable_hotspot_test_in_build+set}" = set; then : 11682 enableval=$enable_hotspot_test_in_build; 11683 else 11684 enable_hotspot_test_in_build=no 11685 fi 11686 11687 if test "x$enable_hotspot_test_in_build" = "xyes"; then 11688 TEST_IN_BUILD=true 11689 else 11690 TEST_IN_BUILD=false 11691 fi 11692 11693 11694 ############################################################################### 11695 # 11696 # Choose cacerts source file 11697 # 11698 11699 # Check whether --with-cacerts-file was given. 11700 if test "${with_cacerts_file+set}" = set; then : 11701 withval=$with_cacerts_file; 11702 fi 11703 11704 if test "x$with_cacerts_file" != x; then 11705 CACERTS_FILE=$with_cacerts_file 11706 else 11707 if test "x$OPENJDK" = "xtrue"; then 11708 CACERTS_FILE=${SRC_ROOT}/jdk/src/share/lib/security/cacerts 11709 else 11710 CACERTS_FILE=${SRC_ROOT}/jdk/src/closed/share/lib/security/cacerts.internal 11711 fi 11712 fi 11713 11714 11715 ############################################################################### 11716 # 11717 # Enable or disable unlimited crypto 11718 # 11719 # Check whether --enable-unlimited-crypto was given. 11720 if test "${enable_unlimited_crypto+set}" = set; then : 11721 enableval=$enable_unlimited_crypto; 11722 else 11723 enable_unlimited_crypto=no 11724 fi 11725 11726 if test "x$enable_unlimited_crypto" = "xyes"; then 11727 UNLIMITED_CRYPTO=true 11728 else 11729 UNLIMITED_CRYPTO=false 11730 fi 11731 11732 11733 ############################################################################### 11734 # 11735 # Enable or disable the elliptic curve crypto implementation 11736 # 11737 11738 11739 ############################################################################### 11740 # 11741 # Compress jars 11742 # 11743 COMPRESS_JARS=false 11744 11745 11746 11747 11748 # Source the version numbers 11749 . $AUTOCONF_DIR/version-numbers 11750 11751 # Get the settings from parameters 11752 11753 # Check whether --with-milestone was given. 11754 if test "${with_milestone+set}" = set; then : 11755 withval=$with_milestone; 11756 fi 11757 11758 if test "x$with_milestone" = xyes; then 11759 as_fn_error $? "Milestone must have a value" "$LINENO" 5 11760 elif test "x$with_milestone" != x; then 11761 MILESTONE="$with_milestone" 11762 fi 11763 if test "x$MILESTONE" = x; then 11764 MILESTONE=internal 11765 fi 11766 11767 11768 # Check whether --with-build-number was given. 11769 if test "${with_build_number+set}" = set; then : 11770 withval=$with_build_number; 11771 fi 11772 11773 if test "x$with_build_number" = xyes; then 11774 as_fn_error $? "Build number must have a value" "$LINENO" 5 11775 elif test "x$with_build_number" != x; then 11776 JDK_BUILD_NUMBER="$with_build_number" 11777 fi 11778 if test "x$JDK_BUILD_NUMBER" = x; then 11779 JDK_BUILD_NUMBER=b00 11780 fi 11781 11782 11783 # Check whether --with-user-release-suffix was given. 11784 if test "${with_user_release_suffix+set}" = set; then : 11785 withval=$with_user_release_suffix; 11786 fi 11787 11788 if test "x$with_user_release_suffix" = xyes; then 11789 as_fn_error $? "Release suffix must have a value" "$LINENO" 5 11790 elif test "x$with_user_release_suffix" != x; then 11791 USER_RELEASE_SUFFIX="$with_user_release_suffix" 11792 else 11793 BUILD_DATE=`date '+%Y_%m_%d_%H_%M'` 11794 # Avoid [:alnum:] since it depends on the locale. 11795 CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvqxyz0123456789'` 11796 USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11797 fi 11798 11799 11800 # Now set the JDK version, milestone, build number etc. 11801 11802 11803 11804 11805 11806 11807 11808 11809 11810 11811 11812 11813 11814 11815 COPYRIGHT_YEAR=`date +'%Y'` 11816 11817 11818 if test "x$JDK_UPDATE_VERSION" != x; then 11819 JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}_${JDK_UPDATE_VERSION}" 11820 else 11821 JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}" 11822 fi 11823 11824 11825 COOKED_BUILD_NUMBER=`$ECHO $JDK_BUILD_NUMBER | $SED -e 's/^b//' -e 's/^0//'` 11826 11827 11828 11829 ############################################################################### 11830 # 11831 # Setup BootJDK, used to bootstrap the build. 11832 # 11833 ############################################################################### 11834 11835 11836 BOOT_JDK_FOUND=no 11837 11838 # Check whether --with-boot-jdk was given. 11839 if test "${with_boot_jdk+set}" = set; then : 11840 withval=$with_boot_jdk; 11841 fi 11842 11843 11844 # We look for the Boot JDK through various means, going from more certain to 11845 # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if 11846 # we detected something (if so, the path to the jdk is in BOOT_JDK). But we 11847 # must check if this is indeed valid; otherwise we'll continue looking. 11848 11849 # Test: Is bootjdk explicitely set by command line arguments? 11850 11851 if test "x$BOOT_JDK_FOUND" = xno; then 11852 # Now execute the test 11853 11854 if test "x$with_boot_jdk" != x; then 11855 BOOT_JDK=$with_boot_jdk 11856 BOOT_JDK_FOUND=maybe 11857 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5 11858 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;} 11859 fi 11860 11861 11862 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 11863 if test "x$BOOT_JDK_FOUND" = xmaybe; then 11864 # Do we have a bin/java? 11865 if test ! -x "$BOOT_JDK/bin/java"; then 11866 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 11867 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 11868 BOOT_JDK_FOUND=no 11869 else 11870 # Do we have a bin/javac? 11871 if test ! -x "$BOOT_JDK/bin/javac"; then 11872 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 11873 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 11874 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 11875 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 11876 BOOT_JDK_FOUND=no 11877 else 11878 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 11879 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 11880 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 11881 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 11882 BOOT_JDK_FOUND=no 11883 else 11884 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 11885 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 11886 11887 # Extra M4 quote needed to protect [] in grep expression. 11888 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 11889 if test "x$FOUND_VERSION_78" = x; then 11890 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 11891 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 11892 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 11893 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 11894 BOOT_JDK_FOUND=no 11895 else 11896 # We're done! :-) 11897 BOOT_JDK_FOUND=yes 11898 11899 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11900 11901 # Input might be given as Windows format, start by converting to 11902 # unix format. 11903 path="$BOOT_JDK" 11904 new_path=`$CYGPATH -u "$path"` 11905 11906 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 11907 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 11908 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 11909 # "foo.exe" is OK but "foo" is an error. 11910 # 11911 # This test is therefore slightly more accurate than "test -f" to check for file precense. 11912 # It is also a way to make sure we got the proper file name for the real test later on. 11913 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 11914 if test "x$test_shortpath" = x; then 11915 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 11916 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 11917 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 11918 fi 11919 11920 # Call helper function which possibly converts this using DOS-style short mode. 11921 # If so, the updated path is stored in $new_path. 11922 11923 input_path="$new_path" 11924 # Check if we need to convert this using DOS-style short mode. If the path 11925 # contains just simple characters, use it. Otherwise (spaces, weird characters), 11926 # take no chances and rewrite it. 11927 # Note: m4 eats our [], so we need to use [ and ] instead. 11928 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 11929 if test "x$has_forbidden_chars" != x; then 11930 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 11931 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 11932 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 11933 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 11934 # Going to short mode and back again did indeed matter. Since short mode is 11935 # case insensitive, let's make it lowercase to improve readability. 11936 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11937 # Now convert it back to Unix-stile (cygpath) 11938 input_path=`$CYGPATH -u "$shortmode_path"` 11939 new_path="$input_path" 11940 fi 11941 fi 11942 11943 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 11944 if test "x$test_cygdrive_prefix" = x; then 11945 # As a simple fix, exclude /usr/bin since it's not a real path. 11946 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 11947 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 11948 # a path prefixed by /cygdrive for fixpath to work. 11949 new_path="$CYGWIN_ROOT_PATH$input_path" 11950 fi 11951 fi 11952 11953 11954 if test "x$path" != "x$new_path"; then 11955 BOOT_JDK="$new_path" 11956 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 11957 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 11958 fi 11959 11960 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 11961 11962 path="$BOOT_JDK" 11963 has_colon=`$ECHO $path | $GREP ^.:` 11964 new_path="$path" 11965 if test "x$has_colon" = x; then 11966 # Not in mixed or Windows style, start by that. 11967 new_path=`cmd //c echo $path` 11968 fi 11969 11970 11971 input_path="$new_path" 11972 # Check if we need to convert this using DOS-style short mode. If the path 11973 # contains just simple characters, use it. Otherwise (spaces, weird characters), 11974 # take no chances and rewrite it. 11975 # Note: m4 eats our [], so we need to use [ and ] instead. 11976 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 11977 if test "x$has_forbidden_chars" != x; then 11978 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 11979 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11980 fi 11981 11982 11983 windows_path="$new_path" 11984 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11985 unix_path=`$CYGPATH -u "$windows_path"` 11986 new_path="$unix_path" 11987 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 11988 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 11989 new_path="$unix_path" 11990 fi 11991 11992 if test "x$path" != "x$new_path"; then 11993 BOOT_JDK="$new_path" 11994 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 11995 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 11996 fi 11997 11998 # Save the first 10 bytes of this path to the storage, so fixpath can work. 11999 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 12000 12001 else 12002 # We're on a posix platform. Hooray! :) 12003 path="$BOOT_JDK" 12004 12005 if test ! -f "$path" && test ! -d "$path"; then 12006 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 12007 fi 12008 12009 has_space=`$ECHO "$path" | $GREP " "` 12010 if test "x$has_space" != x; then 12011 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12012 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12013 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 12014 fi 12015 fi 12016 12017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 12018 $as_echo_n "checking for Boot JDK... " >&6; } 12019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 12020 $as_echo "$BOOT_JDK" >&6; } 12021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 12022 $as_echo_n "checking Boot JDK version... " >&6; } 12023 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 12024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 12025 $as_echo "$BOOT_JDK_VERSION" >&6; } 12026 fi # end check jdk version 12027 fi # end check rt.jar 12028 fi # end check javac 12029 fi # end check java 12030 fi # end check boot jdk found 12031 fi 12032 12033 if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then 12034 # Having specified an argument which is incorrect will produce an instant failure; 12035 # we should not go on looking 12036 as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5 12037 fi 12038 12039 # Test: Is bootjdk available from builddeps? 12040 12041 if test "x$BOOT_JDK_FOUND" = xno; then 12042 # Now execute the test 12043 12044 12045 12046 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 12047 # Source the builddeps file again, to make sure it uses the latest variables! 12048 . $builddepsfile 12049 # Look for a target and build machine specific resource! 12050 eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}} 12051 if test "x$resource" = x; then 12052 # Ok, lets instead look for a target specific resource 12053 eval resource=\${builddep_bootjdk_TARGET_${rewritten_target_var}} 12054 fi 12055 if test "x$resource" = x; then 12056 # Ok, lets instead look for a build specific resource 12057 eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}} 12058 fi 12059 if test "x$resource" = x; then 12060 # Ok, lets instead look for a generic resource 12061 # (The bootjdk comes from M4 and not the shell, thus no need for eval here.) 12062 resource=${builddep_bootjdk} 12063 fi 12064 if test "x$resource" != x; then 12065 { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for bootjdk" >&5 12066 $as_echo "$as_me: Using builddeps $resource for bootjdk" >&6;} 12067 # If the resource in the builddeps.conf file is an existing directory, 12068 # for example /java/linux/cups 12069 if test -d ${resource}; then 12070 depdir=${resource} 12071 else 12072 12073 # bootjdk is for example mymodule 12074 # $resource is for example libs/general/libmymod_1_2_3.zip 12075 # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps 12076 # $with_builddeps_dir is for example /localhome/builddeps 12077 # depdir is the name of the variable into which we store the depdir, eg MYMOD 12078 # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and 12079 # unzip into the directory: /localhome/builddeps/libmymod_1_2_3 12080 filename=`basename $resource` 12081 filebase=`echo $filename | sed 's/\.[^\.]*$//'` 12082 filebase=${filename%%.*} 12083 extension=${filename#*.} 12084 installdir=$with_builddeps_dir/$filebase 12085 if test ! -f $installdir/$filename.unpacked; then 12086 { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&5 12087 $as_echo "$as_me: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&6;} 12088 if test ! -d $installdir; then 12089 mkdir -p $installdir 12090 fi 12091 if test ! -d $installdir; then 12092 as_fn_error $? "Could not create directory $installdir" "$LINENO" 5 12093 fi 12094 tmpfile=`mktemp $installdir/bootjdk.XXXXXXXXX` 12095 touch $tmpfile 12096 if test ! -f $tmpfile; then 12097 as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5 12098 fi 12099 12100 # $with_builddeps_server/$resource is the ftp://abuilddeps.server.com/libs/cups.zip 12101 # $tmpfile is the local file name for the downloaded file. 12102 VALID_TOOL=no 12103 if test "x$BDEPS_FTP" = xwget; then 12104 VALID_TOOL=yes 12105 wget -O $tmpfile $with_builddeps_server/$resource 12106 fi 12107 if test "x$BDEPS_FTP" = xlftp; then 12108 VALID_TOOL=yes 12109 lftp -c "get $with_builddeps_server/$resource -o $tmpfile" 12110 fi 12111 if test "x$BDEPS_FTP" = xftp; then 12112 VALID_TOOL=yes 12113 FTPSERVER=`echo $with_builddeps_server/$resource | cut -f 3 -d '/'` 12114 FTPPATH=`echo $with_builddeps_server/$resource | cut -f 4- -d '/'` 12115 FTPUSERPWD=${FTPSERVER%%@*} 12116 if test "x$FTPSERVER" != "x$FTPUSERPWD"; then 12117 FTPUSER=${userpwd%%:*} 12118 FTPPWD=${userpwd#*@} 12119 FTPSERVER=${FTPSERVER#*@} 12120 else 12121 FTPUSER=ftp 12122 FTPPWD=ftp 12123 fi 12124 # the "pass" command does not work on some 12125 # ftp clients (read ftp.exe) but if it works, 12126 # passive mode is better! 12127 (\ 12128 echo "user $FTPUSER $FTPPWD" ;\ 12129 echo "pass" ;\ 12130 echo "bin" ;\ 12131 echo "get $FTPPATH $tmpfile" ;\ 12132 ) | ftp -in $FTPSERVER 12133 fi 12134 if test "x$VALID_TOOL" != xyes; then 12135 as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5 12136 fi 12137 12138 mv $tmpfile $installdir/$filename 12139 if test ! -s $installdir/$filename; then 12140 as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5 12141 fi 12142 case "$extension" in 12143 zip) echo "Unzipping $installdir/$filename..." 12144 (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked) 12145 ;; 12146 tar.gz) echo "Untaring $installdir/$filename..." 12147 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 12148 ;; 12149 tgz) echo "Untaring $installdir/$filename..." 12150 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 12151 ;; 12152 *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5 12153 ;; 12154 esac 12155 fi 12156 if test -f $installdir/$filename.unpacked; then 12157 depdir=$installdir 12158 fi 12159 12160 fi 12161 # Source the builddeps file again, because in the previous command, the depdir 12162 # was updated to point at the current build dependency install directory. 12163 . $builddepsfile 12164 # Now extract variables from the builddeps.conf files. 12165 theroot=${builddep_bootjdk_ROOT} 12166 thecflags=${builddep_bootjdk_CFLAGS} 12167 thelibs=${builddep_bootjdk_LIBS} 12168 if test "x$depdir" = x; then 12169 as_fn_error $? "Could not download build dependency bootjdk" "$LINENO" 5 12170 fi 12171 BOOT_JDK=$depdir 12172 if test "x$theroot" != x; then 12173 BOOT_JDK="$theroot" 12174 fi 12175 if test "x$thecflags" != x; then 12176 BOOT_JDK_CFLAGS="$thecflags" 12177 fi 12178 if test "x$thelibs" != x; then 12179 BOOT_JDK_LIBS="$thelibs" 12180 fi 12181 BOOT_JDK_FOUND=maybe 12182 else BOOT_JDK_FOUND=no 12183 12184 fi 12185 else BOOT_JDK_FOUND=no 12186 12187 fi 12188 12189 12190 12191 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 12192 if test "x$BOOT_JDK_FOUND" = xmaybe; then 12193 # Do we have a bin/java? 12194 if test ! -x "$BOOT_JDK/bin/java"; then 12195 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 12196 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 12197 BOOT_JDK_FOUND=no 12198 else 12199 # Do we have a bin/javac? 12200 if test ! -x "$BOOT_JDK/bin/javac"; then 12201 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 12202 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 12203 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 12204 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 12205 BOOT_JDK_FOUND=no 12206 else 12207 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 12208 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 12209 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 12210 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 12211 BOOT_JDK_FOUND=no 12212 else 12213 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 12214 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 12215 12216 # Extra M4 quote needed to protect [] in grep expression. 12217 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 12218 if test "x$FOUND_VERSION_78" = x; then 12219 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 12220 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 12221 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 12222 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 12223 BOOT_JDK_FOUND=no 12224 else 12225 # We're done! :-) 12226 BOOT_JDK_FOUND=yes 12227 12228 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12229 12230 # Input might be given as Windows format, start by converting to 12231 # unix format. 12232 path="$BOOT_JDK" 12233 new_path=`$CYGPATH -u "$path"` 12234 12235 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 12236 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 12237 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 12238 # "foo.exe" is OK but "foo" is an error. 12239 # 12240 # This test is therefore slightly more accurate than "test -f" to check for file precense. 12241 # It is also a way to make sure we got the proper file name for the real test later on. 12242 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 12243 if test "x$test_shortpath" = x; then 12244 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12245 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12246 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 12247 fi 12248 12249 # Call helper function which possibly converts this using DOS-style short mode. 12250 # If so, the updated path is stored in $new_path. 12251 12252 input_path="$new_path" 12253 # Check if we need to convert this using DOS-style short mode. If the path 12254 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12255 # take no chances and rewrite it. 12256 # Note: m4 eats our [], so we need to use [ and ] instead. 12257 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 12258 if test "x$has_forbidden_chars" != x; then 12259 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12260 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 12261 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 12262 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 12263 # Going to short mode and back again did indeed matter. Since short mode is 12264 # case insensitive, let's make it lowercase to improve readability. 12265 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12266 # Now convert it back to Unix-stile (cygpath) 12267 input_path=`$CYGPATH -u "$shortmode_path"` 12268 new_path="$input_path" 12269 fi 12270 fi 12271 12272 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 12273 if test "x$test_cygdrive_prefix" = x; then 12274 # As a simple fix, exclude /usr/bin since it's not a real path. 12275 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 12276 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 12277 # a path prefixed by /cygdrive for fixpath to work. 12278 new_path="$CYGWIN_ROOT_PATH$input_path" 12279 fi 12280 fi 12281 12282 12283 if test "x$path" != "x$new_path"; then 12284 BOOT_JDK="$new_path" 12285 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12286 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12287 fi 12288 12289 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12290 12291 path="$BOOT_JDK" 12292 has_colon=`$ECHO $path | $GREP ^.:` 12293 new_path="$path" 12294 if test "x$has_colon" = x; then 12295 # Not in mixed or Windows style, start by that. 12296 new_path=`cmd //c echo $path` 12297 fi 12298 12299 12300 input_path="$new_path" 12301 # Check if we need to convert this using DOS-style short mode. If the path 12302 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12303 # take no chances and rewrite it. 12304 # Note: m4 eats our [], so we need to use [ and ] instead. 12305 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 12306 if test "x$has_forbidden_chars" != x; then 12307 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12308 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12309 fi 12310 12311 12312 windows_path="$new_path" 12313 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12314 unix_path=`$CYGPATH -u "$windows_path"` 12315 new_path="$unix_path" 12316 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12317 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12318 new_path="$unix_path" 12319 fi 12320 12321 if test "x$path" != "x$new_path"; then 12322 BOOT_JDK="$new_path" 12323 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12324 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12325 fi 12326 12327 # Save the first 10 bytes of this path to the storage, so fixpath can work. 12328 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 12329 12330 else 12331 # We're on a posix platform. Hooray! :) 12332 path="$BOOT_JDK" 12333 12334 if test ! -f "$path" && test ! -d "$path"; then 12335 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 12336 fi 12337 12338 has_space=`$ECHO "$path" | $GREP " "` 12339 if test "x$has_space" != x; then 12340 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12341 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12342 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 12343 fi 12344 fi 12345 12346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 12347 $as_echo_n "checking for Boot JDK... " >&6; } 12348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 12349 $as_echo "$BOOT_JDK" >&6; } 12350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 12351 $as_echo_n "checking Boot JDK version... " >&6; } 12352 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 12353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 12354 $as_echo "$BOOT_JDK_VERSION" >&6; } 12355 fi # end check jdk version 12356 fi # end check rt.jar 12357 fi # end check javac 12358 fi # end check java 12359 fi # end check boot jdk found 12360 fi 12361 12362 12363 # Test: Is $JAVA_HOME set? 12364 12365 if test "x$BOOT_JDK_FOUND" = xno; then 12366 # Now execute the test 12367 12368 if test "x$JAVA_HOME" != x; then 12369 JAVA_HOME_PROCESSED="$JAVA_HOME" 12370 12371 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12372 12373 # Input might be given as Windows format, start by converting to 12374 # unix format. 12375 path="$JAVA_HOME_PROCESSED" 12376 new_path=`$CYGPATH -u "$path"` 12377 12378 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 12379 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 12380 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 12381 # "foo.exe" is OK but "foo" is an error. 12382 # 12383 # This test is therefore slightly more accurate than "test -f" to check for file precense. 12384 # It is also a way to make sure we got the proper file name for the real test later on. 12385 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 12386 if test "x$test_shortpath" = x; then 12387 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 12388 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 12389 as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5 12390 fi 12391 12392 # Call helper function which possibly converts this using DOS-style short mode. 12393 # If so, the updated path is stored in $new_path. 12394 12395 input_path="$new_path" 12396 # Check if we need to convert this using DOS-style short mode. If the path 12397 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12398 # take no chances and rewrite it. 12399 # Note: m4 eats our [], so we need to use [ and ] instead. 12400 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 12401 if test "x$has_forbidden_chars" != x; then 12402 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12403 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 12404 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 12405 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 12406 # Going to short mode and back again did indeed matter. Since short mode is 12407 # case insensitive, let's make it lowercase to improve readability. 12408 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12409 # Now convert it back to Unix-stile (cygpath) 12410 input_path=`$CYGPATH -u "$shortmode_path"` 12411 new_path="$input_path" 12412 fi 12413 fi 12414 12415 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 12416 if test "x$test_cygdrive_prefix" = x; then 12417 # As a simple fix, exclude /usr/bin since it's not a real path. 12418 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 12419 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 12420 # a path prefixed by /cygdrive for fixpath to work. 12421 new_path="$CYGWIN_ROOT_PATH$input_path" 12422 fi 12423 fi 12424 12425 12426 if test "x$path" != "x$new_path"; then 12427 JAVA_HOME_PROCESSED="$new_path" 12428 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 12429 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 12430 fi 12431 12432 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12433 12434 path="$JAVA_HOME_PROCESSED" 12435 has_colon=`$ECHO $path | $GREP ^.:` 12436 new_path="$path" 12437 if test "x$has_colon" = x; then 12438 # Not in mixed or Windows style, start by that. 12439 new_path=`cmd //c echo $path` 12440 fi 12441 12442 12443 input_path="$new_path" 12444 # Check if we need to convert this using DOS-style short mode. If the path 12445 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12446 # take no chances and rewrite it. 12447 # Note: m4 eats our [], so we need to use [ and ] instead. 12448 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 12449 if test "x$has_forbidden_chars" != x; then 12450 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12451 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12452 fi 12453 12454 12455 windows_path="$new_path" 12456 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12457 unix_path=`$CYGPATH -u "$windows_path"` 12458 new_path="$unix_path" 12459 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12460 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12461 new_path="$unix_path" 12462 fi 12463 12464 if test "x$path" != "x$new_path"; then 12465 JAVA_HOME_PROCESSED="$new_path" 12466 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 12467 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 12468 fi 12469 12470 # Save the first 10 bytes of this path to the storage, so fixpath can work. 12471 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 12472 12473 else 12474 # We're on a posix platform. Hooray! :) 12475 path="$JAVA_HOME_PROCESSED" 12476 12477 if test ! -f "$path" && test ! -d "$path"; then 12478 as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5 12479 fi 12480 12481 has_space=`$ECHO "$path" | $GREP " "` 12482 if test "x$has_space" != x; then 12483 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 12484 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 12485 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 12486 fi 12487 fi 12488 12489 if test ! -d "$JAVA_HOME_PROCESSED"; then 12490 { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5 12491 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;} 12492 else 12493 # Aha, the user has set a JAVA_HOME 12494 # let us use that as the Boot JDK. 12495 BOOT_JDK="$JAVA_HOME_PROCESSED" 12496 BOOT_JDK_FOUND=maybe 12497 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5 12498 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;} 12499 fi 12500 fi 12501 12502 12503 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 12504 if test "x$BOOT_JDK_FOUND" = xmaybe; then 12505 # Do we have a bin/java? 12506 if test ! -x "$BOOT_JDK/bin/java"; then 12507 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 12508 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 12509 BOOT_JDK_FOUND=no 12510 else 12511 # Do we have a bin/javac? 12512 if test ! -x "$BOOT_JDK/bin/javac"; then 12513 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 12514 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 12515 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 12516 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 12517 BOOT_JDK_FOUND=no 12518 else 12519 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 12520 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 12521 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 12522 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 12523 BOOT_JDK_FOUND=no 12524 else 12525 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 12526 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 12527 12528 # Extra M4 quote needed to protect [] in grep expression. 12529 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 12530 if test "x$FOUND_VERSION_78" = x; then 12531 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 12532 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 12533 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 12534 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 12535 BOOT_JDK_FOUND=no 12536 else 12537 # We're done! :-) 12538 BOOT_JDK_FOUND=yes 12539 12540 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12541 12542 # Input might be given as Windows format, start by converting to 12543 # unix format. 12544 path="$BOOT_JDK" 12545 new_path=`$CYGPATH -u "$path"` 12546 12547 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 12548 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 12549 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 12550 # "foo.exe" is OK but "foo" is an error. 12551 # 12552 # This test is therefore slightly more accurate than "test -f" to check for file precense. 12553 # It is also a way to make sure we got the proper file name for the real test later on. 12554 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 12555 if test "x$test_shortpath" = x; then 12556 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12557 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12558 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 12559 fi 12560 12561 # Call helper function which possibly converts this using DOS-style short mode. 12562 # If so, the updated path is stored in $new_path. 12563 12564 input_path="$new_path" 12565 # Check if we need to convert this using DOS-style short mode. If the path 12566 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12567 # take no chances and rewrite it. 12568 # Note: m4 eats our [], so we need to use [ and ] instead. 12569 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 12570 if test "x$has_forbidden_chars" != x; then 12571 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12572 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 12573 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 12574 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 12575 # Going to short mode and back again did indeed matter. Since short mode is 12576 # case insensitive, let's make it lowercase to improve readability. 12577 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12578 # Now convert it back to Unix-stile (cygpath) 12579 input_path=`$CYGPATH -u "$shortmode_path"` 12580 new_path="$input_path" 12581 fi 12582 fi 12583 12584 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 12585 if test "x$test_cygdrive_prefix" = x; then 12586 # As a simple fix, exclude /usr/bin since it's not a real path. 12587 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 12588 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 12589 # a path prefixed by /cygdrive for fixpath to work. 12590 new_path="$CYGWIN_ROOT_PATH$input_path" 12591 fi 12592 fi 12593 12594 12595 if test "x$path" != "x$new_path"; then 12596 BOOT_JDK="$new_path" 12597 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12598 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12599 fi 12600 12601 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12602 12603 path="$BOOT_JDK" 12604 has_colon=`$ECHO $path | $GREP ^.:` 12605 new_path="$path" 12606 if test "x$has_colon" = x; then 12607 # Not in mixed or Windows style, start by that. 12608 new_path=`cmd //c echo $path` 12609 fi 12610 12611 12612 input_path="$new_path" 12613 # Check if we need to convert this using DOS-style short mode. If the path 12614 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12615 # take no chances and rewrite it. 12616 # Note: m4 eats our [], so we need to use [ and ] instead. 12617 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 12618 if test "x$has_forbidden_chars" != x; then 12619 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12620 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12621 fi 12622 12623 12624 windows_path="$new_path" 12625 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12626 unix_path=`$CYGPATH -u "$windows_path"` 12627 new_path="$unix_path" 12628 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12629 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12630 new_path="$unix_path" 12631 fi 12632 12633 if test "x$path" != "x$new_path"; then 12634 BOOT_JDK="$new_path" 12635 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12636 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12637 fi 12638 12639 # Save the first 10 bytes of this path to the storage, so fixpath can work. 12640 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 12641 12642 else 12643 # We're on a posix platform. Hooray! :) 12644 path="$BOOT_JDK" 12645 12646 if test ! -f "$path" && test ! -d "$path"; then 12647 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 12648 fi 12649 12650 has_space=`$ECHO "$path" | $GREP " "` 12651 if test "x$has_space" != x; then 12652 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12653 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12654 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 12655 fi 12656 fi 12657 12658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 12659 $as_echo_n "checking for Boot JDK... " >&6; } 12660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 12661 $as_echo "$BOOT_JDK" >&6; } 12662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 12663 $as_echo_n "checking Boot JDK version... " >&6; } 12664 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 12665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 12666 $as_echo "$BOOT_JDK_VERSION" >&6; } 12667 fi # end check jdk version 12668 fi # end check rt.jar 12669 fi # end check javac 12670 fi # end check java 12671 fi # end check boot jdk found 12672 fi 12673 12674 12675 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 12676 12677 if test "x$BOOT_JDK_FOUND" = xno; then 12678 # Now execute the test 12679 12680 if test -x /usr/libexec/java_home; then 12681 BOOT_JDK=`/usr/libexec/java_home` 12682 BOOT_JDK_FOUND=maybe 12683 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home" >&5 12684 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home" >&6;} 12685 fi 12686 12687 12688 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 12689 if test "x$BOOT_JDK_FOUND" = xmaybe; then 12690 # Do we have a bin/java? 12691 if test ! -x "$BOOT_JDK/bin/java"; then 12692 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 12693 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 12694 BOOT_JDK_FOUND=no 12695 else 12696 # Do we have a bin/javac? 12697 if test ! -x "$BOOT_JDK/bin/javac"; then 12698 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 12699 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 12700 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 12701 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 12702 BOOT_JDK_FOUND=no 12703 else 12704 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 12705 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 12706 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 12707 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 12708 BOOT_JDK_FOUND=no 12709 else 12710 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 12711 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 12712 12713 # Extra M4 quote needed to protect [] in grep expression. 12714 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 12715 if test "x$FOUND_VERSION_78" = x; then 12716 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 12717 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 12718 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 12719 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 12720 BOOT_JDK_FOUND=no 12721 else 12722 # We're done! :-) 12723 BOOT_JDK_FOUND=yes 12724 12725 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12726 12727 # Input might be given as Windows format, start by converting to 12728 # unix format. 12729 path="$BOOT_JDK" 12730 new_path=`$CYGPATH -u "$path"` 12731 12732 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 12733 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 12734 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 12735 # "foo.exe" is OK but "foo" is an error. 12736 # 12737 # This test is therefore slightly more accurate than "test -f" to check for file precense. 12738 # It is also a way to make sure we got the proper file name for the real test later on. 12739 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 12740 if test "x$test_shortpath" = x; then 12741 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12742 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12743 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 12744 fi 12745 12746 # Call helper function which possibly converts this using DOS-style short mode. 12747 # If so, the updated path is stored in $new_path. 12748 12749 input_path="$new_path" 12750 # Check if we need to convert this using DOS-style short mode. If the path 12751 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12752 # take no chances and rewrite it. 12753 # Note: m4 eats our [], so we need to use [ and ] instead. 12754 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 12755 if test "x$has_forbidden_chars" != x; then 12756 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12757 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 12758 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 12759 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 12760 # Going to short mode and back again did indeed matter. Since short mode is 12761 # case insensitive, let's make it lowercase to improve readability. 12762 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12763 # Now convert it back to Unix-stile (cygpath) 12764 input_path=`$CYGPATH -u "$shortmode_path"` 12765 new_path="$input_path" 12766 fi 12767 fi 12768 12769 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 12770 if test "x$test_cygdrive_prefix" = x; then 12771 # As a simple fix, exclude /usr/bin since it's not a real path. 12772 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 12773 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 12774 # a path prefixed by /cygdrive for fixpath to work. 12775 new_path="$CYGWIN_ROOT_PATH$input_path" 12776 fi 12777 fi 12778 12779 12780 if test "x$path" != "x$new_path"; then 12781 BOOT_JDK="$new_path" 12782 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12783 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12784 fi 12785 12786 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12787 12788 path="$BOOT_JDK" 12789 has_colon=`$ECHO $path | $GREP ^.:` 12790 new_path="$path" 12791 if test "x$has_colon" = x; then 12792 # Not in mixed or Windows style, start by that. 12793 new_path=`cmd //c echo $path` 12794 fi 12795 12796 12797 input_path="$new_path" 12798 # Check if we need to convert this using DOS-style short mode. If the path 12799 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12800 # take no chances and rewrite it. 12801 # Note: m4 eats our [], so we need to use [ and ] instead. 12802 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 12803 if test "x$has_forbidden_chars" != x; then 12804 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12805 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12806 fi 12807 12808 12809 windows_path="$new_path" 12810 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12811 unix_path=`$CYGPATH -u "$windows_path"` 12812 new_path="$unix_path" 12813 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12814 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12815 new_path="$unix_path" 12816 fi 12817 12818 if test "x$path" != "x$new_path"; then 12819 BOOT_JDK="$new_path" 12820 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12821 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12822 fi 12823 12824 # Save the first 10 bytes of this path to the storage, so fixpath can work. 12825 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 12826 12827 else 12828 # We're on a posix platform. Hooray! :) 12829 path="$BOOT_JDK" 12830 12831 if test ! -f "$path" && test ! -d "$path"; then 12832 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 12833 fi 12834 12835 has_space=`$ECHO "$path" | $GREP " "` 12836 if test "x$has_space" != x; then 12837 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12838 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12839 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 12840 fi 12841 fi 12842 12843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 12844 $as_echo_n "checking for Boot JDK... " >&6; } 12845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 12846 $as_echo "$BOOT_JDK" >&6; } 12847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 12848 $as_echo_n "checking Boot JDK version... " >&6; } 12849 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 12850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 12851 $as_echo "$BOOT_JDK_VERSION" >&6; } 12852 fi # end check jdk version 12853 fi # end check rt.jar 12854 fi # end check javac 12855 fi # end check java 12856 fi # end check boot jdk found 12857 fi 12858 12859 12860 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 12861 12862 if test "x$BOOT_JDK_FOUND" = xno; then 12863 # Now execute the test 12864 12865 # Extract the first word of "javac", so it can be a program name with args. 12866 set dummy javac; ac_word=$2 12867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12868 $as_echo_n "checking for $ac_word... " >&6; } 12869 if ${ac_cv_path_JAVAC_CHECK+:} false; then : 12870 $as_echo_n "(cached) " >&6 12871 else 12872 case $JAVAC_CHECK in 12873 [\\/]* | ?:[\\/]*) 12874 ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path. 12875 ;; 12876 *) 12877 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12878 for as_dir in $PATH 12879 do 12880 IFS=$as_save_IFS 12881 test -z "$as_dir" && as_dir=. 12882 for ac_exec_ext in '' $ac_executable_extensions; do 12883 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 12884 ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext" 12885 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12886 break 2 12887 fi 12888 done 12889 done 12890 IFS=$as_save_IFS 12891 12892 ;; 12893 esac 12894 fi 12895 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK 12896 if test -n "$JAVAC_CHECK"; then 12897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5 12898 $as_echo "$JAVAC_CHECK" >&6; } 12899 else 12900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12901 $as_echo "no" >&6; } 12902 fi 12903 12904 12905 # Extract the first word of "java", so it can be a program name with args. 12906 set dummy java; ac_word=$2 12907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12908 $as_echo_n "checking for $ac_word... " >&6; } 12909 if ${ac_cv_path_JAVA_CHECK+:} false; then : 12910 $as_echo_n "(cached) " >&6 12911 else 12912 case $JAVA_CHECK in 12913 [\\/]* | ?:[\\/]*) 12914 ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path. 12915 ;; 12916 *) 12917 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12918 for as_dir in $PATH 12919 do 12920 IFS=$as_save_IFS 12921 test -z "$as_dir" && as_dir=. 12922 for ac_exec_ext in '' $ac_executable_extensions; do 12923 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 12924 ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext" 12925 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12926 break 2 12927 fi 12928 done 12929 done 12930 IFS=$as_save_IFS 12931 12932 ;; 12933 esac 12934 fi 12935 JAVA_CHECK=$ac_cv_path_JAVA_CHECK 12936 if test -n "$JAVA_CHECK"; then 12937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5 12938 $as_echo "$JAVA_CHECK" >&6; } 12939 else 12940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12941 $as_echo "no" >&6; } 12942 fi 12943 12944 12945 BINARY="$JAVAC_CHECK" 12946 if test "x$JAVAC_CHECK" = x; then 12947 BINARY="$JAVA_CHECK" 12948 fi 12949 if test "x$BINARY" != x; then 12950 # So there is a java(c) binary, it might be part of a JDK. 12951 # Lets find the JDK/JRE directory by following symbolic links. 12952 # Linux/GNU systems often have links from /usr/bin/java to 12953 # /etc/alternatives/java to the real JDK binary. 12954 12955 if test "x$OPENJDK_BUILD_OS" != xwindows; then 12956 # Follow a chain of symbolic links. Use readlink 12957 # where it exists, else fall back to horribly 12958 # complicated shell code. 12959 if test "x$READLINK_TESTED" != yes; then 12960 # On MacOSX there is a readlink tool with a different 12961 # purpose than the GNU readlink tool. Check the found readlink. 12962 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 12963 if test "x$ISGNU" = x; then 12964 # A readlink that we do not know how to use. 12965 # Are there other non-GNU readlinks out there? 12966 READLINK_TESTED=yes 12967 READLINK= 12968 fi 12969 fi 12970 12971 if test "x$READLINK" != x; then 12972 BINARY=`$READLINK -f $BINARY` 12973 else 12974 # Save the current directory for restoring afterwards 12975 STARTDIR=$PWD 12976 COUNTER=0 12977 sym_link_dir=`$DIRNAME $BINARY` 12978 sym_link_file=`$BASENAME $BINARY` 12979 # Use the system pwd and not the shell builtin to resolve directory symlinks 12980 cd $sym_link_dir 12981 cd `$THEPWDCMD` 12982 sym_link_dir=`$THEPWDCMD` 12983 # Resolve file symlinks 12984 while test $COUNTER -lt 20; do 12985 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 12986 if test "x$ISLINK" == x; then 12987 # This is not a symbolic link! We are done! 12988 break 12989 fi 12990 # Again resolve directory symlinks since the target of the just found 12991 # link could be in a different directory 12992 cd `$DIRNAME $ISLINK` 12993 sym_link_dir=`$THEPWDCMD` 12994 sym_link_file=`$BASENAME $ISLINK` 12995 let COUNTER=COUNTER+1 12996 done 12997 cd $STARTDIR 12998 BINARY=$sym_link_dir/$sym_link_file 12999 fi 13000 fi 13001 13002 BOOT_JDK=`dirname "$BINARY"` 13003 BOOT_JDK=`cd "$BOOT_JDK/.."; pwd` 13004 if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then 13005 # Looks like we found ourselves an JDK 13006 BOOT_JDK_FOUND=maybe 13007 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5 13008 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;} 13009 fi 13010 fi 13011 13012 13013 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13014 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13015 # Do we have a bin/java? 13016 if test ! -x "$BOOT_JDK/bin/java"; then 13017 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13018 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13019 BOOT_JDK_FOUND=no 13020 else 13021 # Do we have a bin/javac? 13022 if test ! -x "$BOOT_JDK/bin/javac"; then 13023 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 13024 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 13025 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 13026 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 13027 BOOT_JDK_FOUND=no 13028 else 13029 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 13030 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 13031 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 13032 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 13033 BOOT_JDK_FOUND=no 13034 else 13035 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 13036 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 13037 13038 # Extra M4 quote needed to protect [] in grep expression. 13039 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 13040 if test "x$FOUND_VERSION_78" = x; then 13041 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 13042 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 13043 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 13044 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 13045 BOOT_JDK_FOUND=no 13046 else 13047 # We're done! :-) 13048 BOOT_JDK_FOUND=yes 13049 13050 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13051 13052 # Input might be given as Windows format, start by converting to 13053 # unix format. 13054 path="$BOOT_JDK" 13055 new_path=`$CYGPATH -u "$path"` 13056 13057 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 13058 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 13059 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 13060 # "foo.exe" is OK but "foo" is an error. 13061 # 13062 # This test is therefore slightly more accurate than "test -f" to check for file precense. 13063 # It is also a way to make sure we got the proper file name for the real test later on. 13064 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 13065 if test "x$test_shortpath" = x; then 13066 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13067 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13068 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 13069 fi 13070 13071 # Call helper function which possibly converts this using DOS-style short mode. 13072 # If so, the updated path is stored in $new_path. 13073 13074 input_path="$new_path" 13075 # Check if we need to convert this using DOS-style short mode. If the path 13076 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13077 # take no chances and rewrite it. 13078 # Note: m4 eats our [], so we need to use [ and ] instead. 13079 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 13080 if test "x$has_forbidden_chars" != x; then 13081 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13082 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 13083 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 13084 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 13085 # Going to short mode and back again did indeed matter. Since short mode is 13086 # case insensitive, let's make it lowercase to improve readability. 13087 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13088 # Now convert it back to Unix-stile (cygpath) 13089 input_path=`$CYGPATH -u "$shortmode_path"` 13090 new_path="$input_path" 13091 fi 13092 fi 13093 13094 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 13095 if test "x$test_cygdrive_prefix" = x; then 13096 # As a simple fix, exclude /usr/bin since it's not a real path. 13097 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 13098 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 13099 # a path prefixed by /cygdrive for fixpath to work. 13100 new_path="$CYGWIN_ROOT_PATH$input_path" 13101 fi 13102 fi 13103 13104 13105 if test "x$path" != "x$new_path"; then 13106 BOOT_JDK="$new_path" 13107 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13108 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13109 fi 13110 13111 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13112 13113 path="$BOOT_JDK" 13114 has_colon=`$ECHO $path | $GREP ^.:` 13115 new_path="$path" 13116 if test "x$has_colon" = x; then 13117 # Not in mixed or Windows style, start by that. 13118 new_path=`cmd //c echo $path` 13119 fi 13120 13121 13122 input_path="$new_path" 13123 # Check if we need to convert this using DOS-style short mode. If the path 13124 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13125 # take no chances and rewrite it. 13126 # Note: m4 eats our [], so we need to use [ and ] instead. 13127 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 13128 if test "x$has_forbidden_chars" != x; then 13129 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13130 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13131 fi 13132 13133 13134 windows_path="$new_path" 13135 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13136 unix_path=`$CYGPATH -u "$windows_path"` 13137 new_path="$unix_path" 13138 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13139 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13140 new_path="$unix_path" 13141 fi 13142 13143 if test "x$path" != "x$new_path"; then 13144 BOOT_JDK="$new_path" 13145 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13146 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13147 fi 13148 13149 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13150 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13151 13152 else 13153 # We're on a posix platform. Hooray! :) 13154 path="$BOOT_JDK" 13155 13156 if test ! -f "$path" && test ! -d "$path"; then 13157 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13158 fi 13159 13160 has_space=`$ECHO "$path" | $GREP " "` 13161 if test "x$has_space" != x; then 13162 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13163 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13164 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13165 fi 13166 fi 13167 13168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13169 $as_echo_n "checking for Boot JDK... " >&6; } 13170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13171 $as_echo "$BOOT_JDK" >&6; } 13172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13173 $as_echo_n "checking Boot JDK version... " >&6; } 13174 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13176 $as_echo "$BOOT_JDK_VERSION" >&6; } 13177 fi # end check jdk version 13178 fi # end check rt.jar 13179 fi # end check javac 13180 fi # end check java 13181 fi # end check boot jdk found 13182 fi 13183 13184 13185 # Test: Is there a JDK installed in default, well-known locations? 13186 13187 if test "x$BOOT_JDK_FOUND" = xno; then 13188 # Now execute the test 13189 13190 if test "x$OPENJDK_TARGET_OS" = xwindows; then 13191 13192 if test "x$BOOT_JDK_FOUND" = xno; then 13193 # Now execute the test 13194 13195 if test "x$ProgramW6432" != x; then 13196 VIRTUAL_DIR="$ProgramW6432/Java" 13197 13198 windows_path="$VIRTUAL_DIR" 13199 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13200 unix_path=`$CYGPATH -u "$windows_path"` 13201 VIRTUAL_DIR="$unix_path" 13202 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13203 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13204 VIRTUAL_DIR="$unix_path" 13205 fi 13206 13207 13208 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 13209 BOOT_JDK_SUFFIX="" 13210 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 13211 if test "x$ALL_JDKS_FOUND" != x; then 13212 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 13213 13214 if test "x$BOOT_JDK_FOUND" = xno; then 13215 # Now execute the test 13216 13217 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 13218 if test -d "$BOOT_JDK"; then 13219 BOOT_JDK_FOUND=maybe 13220 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 13221 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 13222 fi 13223 13224 13225 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13226 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13227 # Do we have a bin/java? 13228 if test ! -x "$BOOT_JDK/bin/java"; then 13229 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13230 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13231 BOOT_JDK_FOUND=no 13232 else 13233 # Do we have a bin/javac? 13234 if test ! -x "$BOOT_JDK/bin/javac"; then 13235 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 13236 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 13237 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 13238 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 13239 BOOT_JDK_FOUND=no 13240 else 13241 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 13242 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 13243 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 13244 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 13245 BOOT_JDK_FOUND=no 13246 else 13247 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 13248 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 13249 13250 # Extra M4 quote needed to protect [] in grep expression. 13251 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 13252 if test "x$FOUND_VERSION_78" = x; then 13253 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 13254 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 13255 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 13256 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 13257 BOOT_JDK_FOUND=no 13258 else 13259 # We're done! :-) 13260 BOOT_JDK_FOUND=yes 13261 13262 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13263 13264 # Input might be given as Windows format, start by converting to 13265 # unix format. 13266 path="$BOOT_JDK" 13267 new_path=`$CYGPATH -u "$path"` 13268 13269 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 13270 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 13271 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 13272 # "foo.exe" is OK but "foo" is an error. 13273 # 13274 # This test is therefore slightly more accurate than "test -f" to check for file precense. 13275 # It is also a way to make sure we got the proper file name for the real test later on. 13276 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 13277 if test "x$test_shortpath" = x; then 13278 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13279 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13280 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 13281 fi 13282 13283 # Call helper function which possibly converts this using DOS-style short mode. 13284 # If so, the updated path is stored in $new_path. 13285 13286 input_path="$new_path" 13287 # Check if we need to convert this using DOS-style short mode. If the path 13288 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13289 # take no chances and rewrite it. 13290 # Note: m4 eats our [], so we need to use [ and ] instead. 13291 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 13292 if test "x$has_forbidden_chars" != x; then 13293 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13294 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 13295 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 13296 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 13297 # Going to short mode and back again did indeed matter. Since short mode is 13298 # case insensitive, let's make it lowercase to improve readability. 13299 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13300 # Now convert it back to Unix-stile (cygpath) 13301 input_path=`$CYGPATH -u "$shortmode_path"` 13302 new_path="$input_path" 13303 fi 13304 fi 13305 13306 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 13307 if test "x$test_cygdrive_prefix" = x; then 13308 # As a simple fix, exclude /usr/bin since it's not a real path. 13309 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 13310 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 13311 # a path prefixed by /cygdrive for fixpath to work. 13312 new_path="$CYGWIN_ROOT_PATH$input_path" 13313 fi 13314 fi 13315 13316 13317 if test "x$path" != "x$new_path"; then 13318 BOOT_JDK="$new_path" 13319 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13320 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13321 fi 13322 13323 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13324 13325 path="$BOOT_JDK" 13326 has_colon=`$ECHO $path | $GREP ^.:` 13327 new_path="$path" 13328 if test "x$has_colon" = x; then 13329 # Not in mixed or Windows style, start by that. 13330 new_path=`cmd //c echo $path` 13331 fi 13332 13333 13334 input_path="$new_path" 13335 # Check if we need to convert this using DOS-style short mode. If the path 13336 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13337 # take no chances and rewrite it. 13338 # Note: m4 eats our [], so we need to use [ and ] instead. 13339 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 13340 if test "x$has_forbidden_chars" != x; then 13341 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13342 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13343 fi 13344 13345 13346 windows_path="$new_path" 13347 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13348 unix_path=`$CYGPATH -u "$windows_path"` 13349 new_path="$unix_path" 13350 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13351 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13352 new_path="$unix_path" 13353 fi 13354 13355 if test "x$path" != "x$new_path"; then 13356 BOOT_JDK="$new_path" 13357 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13358 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13359 fi 13360 13361 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13362 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13363 13364 else 13365 # We're on a posix platform. Hooray! :) 13366 path="$BOOT_JDK" 13367 13368 if test ! -f "$path" && test ! -d "$path"; then 13369 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13370 fi 13371 13372 has_space=`$ECHO "$path" | $GREP " "` 13373 if test "x$has_space" != x; then 13374 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13375 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13376 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13377 fi 13378 fi 13379 13380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13381 $as_echo_n "checking for Boot JDK... " >&6; } 13382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13383 $as_echo "$BOOT_JDK" >&6; } 13384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13385 $as_echo_n "checking Boot JDK version... " >&6; } 13386 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13388 $as_echo "$BOOT_JDK_VERSION" >&6; } 13389 fi # end check jdk version 13390 fi # end check rt.jar 13391 fi # end check javac 13392 fi # end check java 13393 fi # end check boot jdk found 13394 fi 13395 13396 done 13397 fi 13398 13399 fi 13400 13401 13402 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13403 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13404 # Do we have a bin/java? 13405 if test ! -x "$BOOT_JDK/bin/java"; then 13406 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13407 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13408 BOOT_JDK_FOUND=no 13409 else 13410 # Do we have a bin/javac? 13411 if test ! -x "$BOOT_JDK/bin/javac"; then 13412 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 13413 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 13414 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 13415 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 13416 BOOT_JDK_FOUND=no 13417 else 13418 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 13419 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 13420 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 13421 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 13422 BOOT_JDK_FOUND=no 13423 else 13424 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 13425 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 13426 13427 # Extra M4 quote needed to protect [] in grep expression. 13428 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 13429 if test "x$FOUND_VERSION_78" = x; then 13430 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 13431 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 13432 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 13433 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 13434 BOOT_JDK_FOUND=no 13435 else 13436 # We're done! :-) 13437 BOOT_JDK_FOUND=yes 13438 13439 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13440 13441 # Input might be given as Windows format, start by converting to 13442 # unix format. 13443 path="$BOOT_JDK" 13444 new_path=`$CYGPATH -u "$path"` 13445 13446 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 13447 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 13448 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 13449 # "foo.exe" is OK but "foo" is an error. 13450 # 13451 # This test is therefore slightly more accurate than "test -f" to check for file precense. 13452 # It is also a way to make sure we got the proper file name for the real test later on. 13453 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 13454 if test "x$test_shortpath" = x; then 13455 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13456 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13457 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 13458 fi 13459 13460 # Call helper function which possibly converts this using DOS-style short mode. 13461 # If so, the updated path is stored in $new_path. 13462 13463 input_path="$new_path" 13464 # Check if we need to convert this using DOS-style short mode. If the path 13465 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13466 # take no chances and rewrite it. 13467 # Note: m4 eats our [], so we need to use [ and ] instead. 13468 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 13469 if test "x$has_forbidden_chars" != x; then 13470 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13471 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 13472 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 13473 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 13474 # Going to short mode and back again did indeed matter. Since short mode is 13475 # case insensitive, let's make it lowercase to improve readability. 13476 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13477 # Now convert it back to Unix-stile (cygpath) 13478 input_path=`$CYGPATH -u "$shortmode_path"` 13479 new_path="$input_path" 13480 fi 13481 fi 13482 13483 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 13484 if test "x$test_cygdrive_prefix" = x; then 13485 # As a simple fix, exclude /usr/bin since it's not a real path. 13486 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 13487 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 13488 # a path prefixed by /cygdrive for fixpath to work. 13489 new_path="$CYGWIN_ROOT_PATH$input_path" 13490 fi 13491 fi 13492 13493 13494 if test "x$path" != "x$new_path"; then 13495 BOOT_JDK="$new_path" 13496 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13497 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13498 fi 13499 13500 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13501 13502 path="$BOOT_JDK" 13503 has_colon=`$ECHO $path | $GREP ^.:` 13504 new_path="$path" 13505 if test "x$has_colon" = x; then 13506 # Not in mixed or Windows style, start by that. 13507 new_path=`cmd //c echo $path` 13508 fi 13509 13510 13511 input_path="$new_path" 13512 # Check if we need to convert this using DOS-style short mode. If the path 13513 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13514 # take no chances and rewrite it. 13515 # Note: m4 eats our [], so we need to use [ and ] instead. 13516 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 13517 if test "x$has_forbidden_chars" != x; then 13518 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13519 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13520 fi 13521 13522 13523 windows_path="$new_path" 13524 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13525 unix_path=`$CYGPATH -u "$windows_path"` 13526 new_path="$unix_path" 13527 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13528 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13529 new_path="$unix_path" 13530 fi 13531 13532 if test "x$path" != "x$new_path"; then 13533 BOOT_JDK="$new_path" 13534 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13535 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13536 fi 13537 13538 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13539 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13540 13541 else 13542 # We're on a posix platform. Hooray! :) 13543 path="$BOOT_JDK" 13544 13545 if test ! -f "$path" && test ! -d "$path"; then 13546 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13547 fi 13548 13549 has_space=`$ECHO "$path" | $GREP " "` 13550 if test "x$has_space" != x; then 13551 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13552 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13553 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13554 fi 13555 fi 13556 13557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13558 $as_echo_n "checking for Boot JDK... " >&6; } 13559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13560 $as_echo "$BOOT_JDK" >&6; } 13561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13562 $as_echo_n "checking Boot JDK version... " >&6; } 13563 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13565 $as_echo "$BOOT_JDK_VERSION" >&6; } 13566 fi # end check jdk version 13567 fi # end check rt.jar 13568 fi # end check javac 13569 fi # end check java 13570 fi # end check boot jdk found 13571 fi 13572 13573 13574 if test "x$BOOT_JDK_FOUND" = xno; then 13575 # Now execute the test 13576 13577 if test "x$PROGRAMW6432" != x; then 13578 VIRTUAL_DIR="$PROGRAMW6432/Java" 13579 13580 windows_path="$VIRTUAL_DIR" 13581 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13582 unix_path=`$CYGPATH -u "$windows_path"` 13583 VIRTUAL_DIR="$unix_path" 13584 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13585 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13586 VIRTUAL_DIR="$unix_path" 13587 fi 13588 13589 13590 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 13591 BOOT_JDK_SUFFIX="" 13592 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 13593 if test "x$ALL_JDKS_FOUND" != x; then 13594 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 13595 13596 if test "x$BOOT_JDK_FOUND" = xno; then 13597 # Now execute the test 13598 13599 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 13600 if test -d "$BOOT_JDK"; then 13601 BOOT_JDK_FOUND=maybe 13602 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 13603 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 13604 fi 13605 13606 13607 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13608 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13609 # Do we have a bin/java? 13610 if test ! -x "$BOOT_JDK/bin/java"; then 13611 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13612 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13613 BOOT_JDK_FOUND=no 13614 else 13615 # Do we have a bin/javac? 13616 if test ! -x "$BOOT_JDK/bin/javac"; then 13617 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 13618 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 13619 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 13620 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 13621 BOOT_JDK_FOUND=no 13622 else 13623 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 13624 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 13625 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 13626 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 13627 BOOT_JDK_FOUND=no 13628 else 13629 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 13630 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 13631 13632 # Extra M4 quote needed to protect [] in grep expression. 13633 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 13634 if test "x$FOUND_VERSION_78" = x; then 13635 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 13636 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 13637 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 13638 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 13639 BOOT_JDK_FOUND=no 13640 else 13641 # We're done! :-) 13642 BOOT_JDK_FOUND=yes 13643 13644 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13645 13646 # Input might be given as Windows format, start by converting to 13647 # unix format. 13648 path="$BOOT_JDK" 13649 new_path=`$CYGPATH -u "$path"` 13650 13651 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 13652 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 13653 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 13654 # "foo.exe" is OK but "foo" is an error. 13655 # 13656 # This test is therefore slightly more accurate than "test -f" to check for file precense. 13657 # It is also a way to make sure we got the proper file name for the real test later on. 13658 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 13659 if test "x$test_shortpath" = x; then 13660 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13661 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13662 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 13663 fi 13664 13665 # Call helper function which possibly converts this using DOS-style short mode. 13666 # If so, the updated path is stored in $new_path. 13667 13668 input_path="$new_path" 13669 # Check if we need to convert this using DOS-style short mode. If the path 13670 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13671 # take no chances and rewrite it. 13672 # Note: m4 eats our [], so we need to use [ and ] instead. 13673 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 13674 if test "x$has_forbidden_chars" != x; then 13675 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13676 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 13677 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 13678 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 13679 # Going to short mode and back again did indeed matter. Since short mode is 13680 # case insensitive, let's make it lowercase to improve readability. 13681 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13682 # Now convert it back to Unix-stile (cygpath) 13683 input_path=`$CYGPATH -u "$shortmode_path"` 13684 new_path="$input_path" 13685 fi 13686 fi 13687 13688 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 13689 if test "x$test_cygdrive_prefix" = x; then 13690 # As a simple fix, exclude /usr/bin since it's not a real path. 13691 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 13692 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 13693 # a path prefixed by /cygdrive for fixpath to work. 13694 new_path="$CYGWIN_ROOT_PATH$input_path" 13695 fi 13696 fi 13697 13698 13699 if test "x$path" != "x$new_path"; then 13700 BOOT_JDK="$new_path" 13701 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13702 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13703 fi 13704 13705 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13706 13707 path="$BOOT_JDK" 13708 has_colon=`$ECHO $path | $GREP ^.:` 13709 new_path="$path" 13710 if test "x$has_colon" = x; then 13711 # Not in mixed or Windows style, start by that. 13712 new_path=`cmd //c echo $path` 13713 fi 13714 13715 13716 input_path="$new_path" 13717 # Check if we need to convert this using DOS-style short mode. If the path 13718 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13719 # take no chances and rewrite it. 13720 # Note: m4 eats our [], so we need to use [ and ] instead. 13721 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 13722 if test "x$has_forbidden_chars" != x; then 13723 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13724 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13725 fi 13726 13727 13728 windows_path="$new_path" 13729 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13730 unix_path=`$CYGPATH -u "$windows_path"` 13731 new_path="$unix_path" 13732 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13733 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13734 new_path="$unix_path" 13735 fi 13736 13737 if test "x$path" != "x$new_path"; then 13738 BOOT_JDK="$new_path" 13739 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13740 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13741 fi 13742 13743 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13744 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13745 13746 else 13747 # We're on a posix platform. Hooray! :) 13748 path="$BOOT_JDK" 13749 13750 if test ! -f "$path" && test ! -d "$path"; then 13751 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13752 fi 13753 13754 has_space=`$ECHO "$path" | $GREP " "` 13755 if test "x$has_space" != x; then 13756 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13757 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13758 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13759 fi 13760 fi 13761 13762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13763 $as_echo_n "checking for Boot JDK... " >&6; } 13764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13765 $as_echo "$BOOT_JDK" >&6; } 13766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13767 $as_echo_n "checking Boot JDK version... " >&6; } 13768 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13770 $as_echo "$BOOT_JDK_VERSION" >&6; } 13771 fi # end check jdk version 13772 fi # end check rt.jar 13773 fi # end check javac 13774 fi # end check java 13775 fi # end check boot jdk found 13776 fi 13777 13778 done 13779 fi 13780 13781 fi 13782 13783 13784 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13785 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13786 # Do we have a bin/java? 13787 if test ! -x "$BOOT_JDK/bin/java"; then 13788 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13789 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13790 BOOT_JDK_FOUND=no 13791 else 13792 # Do we have a bin/javac? 13793 if test ! -x "$BOOT_JDK/bin/javac"; then 13794 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 13795 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 13796 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 13797 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 13798 BOOT_JDK_FOUND=no 13799 else 13800 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 13801 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 13802 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 13803 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 13804 BOOT_JDK_FOUND=no 13805 else 13806 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 13807 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 13808 13809 # Extra M4 quote needed to protect [] in grep expression. 13810 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 13811 if test "x$FOUND_VERSION_78" = x; then 13812 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 13813 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 13814 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 13815 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 13816 BOOT_JDK_FOUND=no 13817 else 13818 # We're done! :-) 13819 BOOT_JDK_FOUND=yes 13820 13821 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13822 13823 # Input might be given as Windows format, start by converting to 13824 # unix format. 13825 path="$BOOT_JDK" 13826 new_path=`$CYGPATH -u "$path"` 13827 13828 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 13829 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 13830 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 13831 # "foo.exe" is OK but "foo" is an error. 13832 # 13833 # This test is therefore slightly more accurate than "test -f" to check for file precense. 13834 # It is also a way to make sure we got the proper file name for the real test later on. 13835 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 13836 if test "x$test_shortpath" = x; then 13837 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13838 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13839 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 13840 fi 13841 13842 # Call helper function which possibly converts this using DOS-style short mode. 13843 # If so, the updated path is stored in $new_path. 13844 13845 input_path="$new_path" 13846 # Check if we need to convert this using DOS-style short mode. If the path 13847 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13848 # take no chances and rewrite it. 13849 # Note: m4 eats our [], so we need to use [ and ] instead. 13850 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 13851 if test "x$has_forbidden_chars" != x; then 13852 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13853 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 13854 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 13855 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 13856 # Going to short mode and back again did indeed matter. Since short mode is 13857 # case insensitive, let's make it lowercase to improve readability. 13858 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13859 # Now convert it back to Unix-stile (cygpath) 13860 input_path=`$CYGPATH -u "$shortmode_path"` 13861 new_path="$input_path" 13862 fi 13863 fi 13864 13865 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 13866 if test "x$test_cygdrive_prefix" = x; then 13867 # As a simple fix, exclude /usr/bin since it's not a real path. 13868 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 13869 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 13870 # a path prefixed by /cygdrive for fixpath to work. 13871 new_path="$CYGWIN_ROOT_PATH$input_path" 13872 fi 13873 fi 13874 13875 13876 if test "x$path" != "x$new_path"; then 13877 BOOT_JDK="$new_path" 13878 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13879 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13880 fi 13881 13882 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13883 13884 path="$BOOT_JDK" 13885 has_colon=`$ECHO $path | $GREP ^.:` 13886 new_path="$path" 13887 if test "x$has_colon" = x; then 13888 # Not in mixed or Windows style, start by that. 13889 new_path=`cmd //c echo $path` 13890 fi 13891 13892 13893 input_path="$new_path" 13894 # Check if we need to convert this using DOS-style short mode. If the path 13895 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13896 # take no chances and rewrite it. 13897 # Note: m4 eats our [], so we need to use [ and ] instead. 13898 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 13899 if test "x$has_forbidden_chars" != x; then 13900 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13901 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13902 fi 13903 13904 13905 windows_path="$new_path" 13906 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13907 unix_path=`$CYGPATH -u "$windows_path"` 13908 new_path="$unix_path" 13909 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13910 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13911 new_path="$unix_path" 13912 fi 13913 13914 if test "x$path" != "x$new_path"; then 13915 BOOT_JDK="$new_path" 13916 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13917 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13918 fi 13919 13920 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13921 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13922 13923 else 13924 # We're on a posix platform. Hooray! :) 13925 path="$BOOT_JDK" 13926 13927 if test ! -f "$path" && test ! -d "$path"; then 13928 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13929 fi 13930 13931 has_space=`$ECHO "$path" | $GREP " "` 13932 if test "x$has_space" != x; then 13933 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13934 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13935 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13936 fi 13937 fi 13938 13939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13940 $as_echo_n "checking for Boot JDK... " >&6; } 13941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13942 $as_echo "$BOOT_JDK" >&6; } 13943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13944 $as_echo_n "checking Boot JDK version... " >&6; } 13945 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13947 $as_echo "$BOOT_JDK_VERSION" >&6; } 13948 fi # end check jdk version 13949 fi # end check rt.jar 13950 fi # end check javac 13951 fi # end check java 13952 fi # end check boot jdk found 13953 fi 13954 13955 13956 if test "x$BOOT_JDK_FOUND" = xno; then 13957 # Now execute the test 13958 13959 if test "x$PROGRAMFILES" != x; then 13960 VIRTUAL_DIR="$PROGRAMFILES/Java" 13961 13962 windows_path="$VIRTUAL_DIR" 13963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13964 unix_path=`$CYGPATH -u "$windows_path"` 13965 VIRTUAL_DIR="$unix_path" 13966 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13967 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13968 VIRTUAL_DIR="$unix_path" 13969 fi 13970 13971 13972 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 13973 BOOT_JDK_SUFFIX="" 13974 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 13975 if test "x$ALL_JDKS_FOUND" != x; then 13976 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 13977 13978 if test "x$BOOT_JDK_FOUND" = xno; then 13979 # Now execute the test 13980 13981 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 13982 if test -d "$BOOT_JDK"; then 13983 BOOT_JDK_FOUND=maybe 13984 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 13985 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 13986 fi 13987 13988 13989 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13990 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13991 # Do we have a bin/java? 13992 if test ! -x "$BOOT_JDK/bin/java"; then 13993 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13994 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13995 BOOT_JDK_FOUND=no 13996 else 13997 # Do we have a bin/javac? 13998 if test ! -x "$BOOT_JDK/bin/javac"; then 13999 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14000 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14001 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14002 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14003 BOOT_JDK_FOUND=no 14004 else 14005 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14006 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14007 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14008 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14009 BOOT_JDK_FOUND=no 14010 else 14011 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14012 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14013 14014 # Extra M4 quote needed to protect [] in grep expression. 14015 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14016 if test "x$FOUND_VERSION_78" = x; then 14017 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14018 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14019 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14020 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14021 BOOT_JDK_FOUND=no 14022 else 14023 # We're done! :-) 14024 BOOT_JDK_FOUND=yes 14025 14026 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14027 14028 # Input might be given as Windows format, start by converting to 14029 # unix format. 14030 path="$BOOT_JDK" 14031 new_path=`$CYGPATH -u "$path"` 14032 14033 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14034 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14035 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14036 # "foo.exe" is OK but "foo" is an error. 14037 # 14038 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14039 # It is also a way to make sure we got the proper file name for the real test later on. 14040 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14041 if test "x$test_shortpath" = x; then 14042 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14043 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14044 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14045 fi 14046 14047 # Call helper function which possibly converts this using DOS-style short mode. 14048 # If so, the updated path is stored in $new_path. 14049 14050 input_path="$new_path" 14051 # Check if we need to convert this using DOS-style short mode. If the path 14052 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14053 # take no chances and rewrite it. 14054 # Note: m4 eats our [], so we need to use [ and ] instead. 14055 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14056 if test "x$has_forbidden_chars" != x; then 14057 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14058 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14059 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14060 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14061 # Going to short mode and back again did indeed matter. Since short mode is 14062 # case insensitive, let's make it lowercase to improve readability. 14063 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14064 # Now convert it back to Unix-stile (cygpath) 14065 input_path=`$CYGPATH -u "$shortmode_path"` 14066 new_path="$input_path" 14067 fi 14068 fi 14069 14070 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14071 if test "x$test_cygdrive_prefix" = x; then 14072 # As a simple fix, exclude /usr/bin since it's not a real path. 14073 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 14074 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 14075 # a path prefixed by /cygdrive for fixpath to work. 14076 new_path="$CYGWIN_ROOT_PATH$input_path" 14077 fi 14078 fi 14079 14080 14081 if test "x$path" != "x$new_path"; then 14082 BOOT_JDK="$new_path" 14083 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14084 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14085 fi 14086 14087 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14088 14089 path="$BOOT_JDK" 14090 has_colon=`$ECHO $path | $GREP ^.:` 14091 new_path="$path" 14092 if test "x$has_colon" = x; then 14093 # Not in mixed or Windows style, start by that. 14094 new_path=`cmd //c echo $path` 14095 fi 14096 14097 14098 input_path="$new_path" 14099 # Check if we need to convert this using DOS-style short mode. If the path 14100 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14101 # take no chances and rewrite it. 14102 # Note: m4 eats our [], so we need to use [ and ] instead. 14103 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 14104 if test "x$has_forbidden_chars" != x; then 14105 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14106 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14107 fi 14108 14109 14110 windows_path="$new_path" 14111 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14112 unix_path=`$CYGPATH -u "$windows_path"` 14113 new_path="$unix_path" 14114 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14115 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14116 new_path="$unix_path" 14117 fi 14118 14119 if test "x$path" != "x$new_path"; then 14120 BOOT_JDK="$new_path" 14121 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14122 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14123 fi 14124 14125 # Save the first 10 bytes of this path to the storage, so fixpath can work. 14126 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 14127 14128 else 14129 # We're on a posix platform. Hooray! :) 14130 path="$BOOT_JDK" 14131 14132 if test ! -f "$path" && test ! -d "$path"; then 14133 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 14134 fi 14135 14136 has_space=`$ECHO "$path" | $GREP " "` 14137 if test "x$has_space" != x; then 14138 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14139 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14140 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 14141 fi 14142 fi 14143 14144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 14145 $as_echo_n "checking for Boot JDK... " >&6; } 14146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 14147 $as_echo "$BOOT_JDK" >&6; } 14148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 14149 $as_echo_n "checking Boot JDK version... " >&6; } 14150 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 14151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 14152 $as_echo "$BOOT_JDK_VERSION" >&6; } 14153 fi # end check jdk version 14154 fi # end check rt.jar 14155 fi # end check javac 14156 fi # end check java 14157 fi # end check boot jdk found 14158 fi 14159 14160 done 14161 fi 14162 14163 fi 14164 14165 14166 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14167 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14168 # Do we have a bin/java? 14169 if test ! -x "$BOOT_JDK/bin/java"; then 14170 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14171 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14172 BOOT_JDK_FOUND=no 14173 else 14174 # Do we have a bin/javac? 14175 if test ! -x "$BOOT_JDK/bin/javac"; then 14176 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14177 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14178 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14179 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14180 BOOT_JDK_FOUND=no 14181 else 14182 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14183 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14184 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14185 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14186 BOOT_JDK_FOUND=no 14187 else 14188 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14189 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14190 14191 # Extra M4 quote needed to protect [] in grep expression. 14192 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14193 if test "x$FOUND_VERSION_78" = x; then 14194 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14195 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14196 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14197 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14198 BOOT_JDK_FOUND=no 14199 else 14200 # We're done! :-) 14201 BOOT_JDK_FOUND=yes 14202 14203 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14204 14205 # Input might be given as Windows format, start by converting to 14206 # unix format. 14207 path="$BOOT_JDK" 14208 new_path=`$CYGPATH -u "$path"` 14209 14210 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14211 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14212 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14213 # "foo.exe" is OK but "foo" is an error. 14214 # 14215 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14216 # It is also a way to make sure we got the proper file name for the real test later on. 14217 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14218 if test "x$test_shortpath" = x; then 14219 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14220 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14221 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14222 fi 14223 14224 # Call helper function which possibly converts this using DOS-style short mode. 14225 # If so, the updated path is stored in $new_path. 14226 14227 input_path="$new_path" 14228 # Check if we need to convert this using DOS-style short mode. If the path 14229 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14230 # take no chances and rewrite it. 14231 # Note: m4 eats our [], so we need to use [ and ] instead. 14232 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14233 if test "x$has_forbidden_chars" != x; then 14234 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14235 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14236 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14237 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14238 # Going to short mode and back again did indeed matter. Since short mode is 14239 # case insensitive, let's make it lowercase to improve readability. 14240 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14241 # Now convert it back to Unix-stile (cygpath) 14242 input_path=`$CYGPATH -u "$shortmode_path"` 14243 new_path="$input_path" 14244 fi 14245 fi 14246 14247 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14248 if test "x$test_cygdrive_prefix" = x; then 14249 # As a simple fix, exclude /usr/bin since it's not a real path. 14250 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 14251 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 14252 # a path prefixed by /cygdrive for fixpath to work. 14253 new_path="$CYGWIN_ROOT_PATH$input_path" 14254 fi 14255 fi 14256 14257 14258 if test "x$path" != "x$new_path"; then 14259 BOOT_JDK="$new_path" 14260 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14261 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14262 fi 14263 14264 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14265 14266 path="$BOOT_JDK" 14267 has_colon=`$ECHO $path | $GREP ^.:` 14268 new_path="$path" 14269 if test "x$has_colon" = x; then 14270 # Not in mixed or Windows style, start by that. 14271 new_path=`cmd //c echo $path` 14272 fi 14273 14274 14275 input_path="$new_path" 14276 # Check if we need to convert this using DOS-style short mode. If the path 14277 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14278 # take no chances and rewrite it. 14279 # Note: m4 eats our [], so we need to use [ and ] instead. 14280 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 14281 if test "x$has_forbidden_chars" != x; then 14282 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14283 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14284 fi 14285 14286 14287 windows_path="$new_path" 14288 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14289 unix_path=`$CYGPATH -u "$windows_path"` 14290 new_path="$unix_path" 14291 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14292 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14293 new_path="$unix_path" 14294 fi 14295 14296 if test "x$path" != "x$new_path"; then 14297 BOOT_JDK="$new_path" 14298 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14299 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14300 fi 14301 14302 # Save the first 10 bytes of this path to the storage, so fixpath can work. 14303 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 14304 14305 else 14306 # We're on a posix platform. Hooray! :) 14307 path="$BOOT_JDK" 14308 14309 if test ! -f "$path" && test ! -d "$path"; then 14310 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 14311 fi 14312 14313 has_space=`$ECHO "$path" | $GREP " "` 14314 if test "x$has_space" != x; then 14315 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14316 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14317 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 14318 fi 14319 fi 14320 14321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 14322 $as_echo_n "checking for Boot JDK... " >&6; } 14323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 14324 $as_echo "$BOOT_JDK" >&6; } 14325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 14326 $as_echo_n "checking Boot JDK version... " >&6; } 14327 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 14328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 14329 $as_echo "$BOOT_JDK_VERSION" >&6; } 14330 fi # end check jdk version 14331 fi # end check rt.jar 14332 fi # end check javac 14333 fi # end check java 14334 fi # end check boot jdk found 14335 fi 14336 14337 14338 if test "x$BOOT_JDK_FOUND" = xno; then 14339 # Now execute the test 14340 14341 if test "x$ProgramFiles" != x; then 14342 VIRTUAL_DIR="$ProgramFiles/Java" 14343 14344 windows_path="$VIRTUAL_DIR" 14345 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14346 unix_path=`$CYGPATH -u "$windows_path"` 14347 VIRTUAL_DIR="$unix_path" 14348 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14349 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14350 VIRTUAL_DIR="$unix_path" 14351 fi 14352 14353 14354 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 14355 BOOT_JDK_SUFFIX="" 14356 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 14357 if test "x$ALL_JDKS_FOUND" != x; then 14358 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 14359 14360 if test "x$BOOT_JDK_FOUND" = xno; then 14361 # Now execute the test 14362 14363 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 14364 if test -d "$BOOT_JDK"; then 14365 BOOT_JDK_FOUND=maybe 14366 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 14367 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 14368 fi 14369 14370 14371 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14372 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14373 # Do we have a bin/java? 14374 if test ! -x "$BOOT_JDK/bin/java"; then 14375 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14376 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14377 BOOT_JDK_FOUND=no 14378 else 14379 # Do we have a bin/javac? 14380 if test ! -x "$BOOT_JDK/bin/javac"; then 14381 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14382 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14383 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14384 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14385 BOOT_JDK_FOUND=no 14386 else 14387 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14388 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14389 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14390 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14391 BOOT_JDK_FOUND=no 14392 else 14393 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14394 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14395 14396 # Extra M4 quote needed to protect [] in grep expression. 14397 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14398 if test "x$FOUND_VERSION_78" = x; then 14399 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14400 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14401 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14402 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14403 BOOT_JDK_FOUND=no 14404 else 14405 # We're done! :-) 14406 BOOT_JDK_FOUND=yes 14407 14408 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14409 14410 # Input might be given as Windows format, start by converting to 14411 # unix format. 14412 path="$BOOT_JDK" 14413 new_path=`$CYGPATH -u "$path"` 14414 14415 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14416 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14417 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14418 # "foo.exe" is OK but "foo" is an error. 14419 # 14420 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14421 # It is also a way to make sure we got the proper file name for the real test later on. 14422 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14423 if test "x$test_shortpath" = x; then 14424 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14425 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14426 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14427 fi 14428 14429 # Call helper function which possibly converts this using DOS-style short mode. 14430 # If so, the updated path is stored in $new_path. 14431 14432 input_path="$new_path" 14433 # Check if we need to convert this using DOS-style short mode. If the path 14434 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14435 # take no chances and rewrite it. 14436 # Note: m4 eats our [], so we need to use [ and ] instead. 14437 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14438 if test "x$has_forbidden_chars" != x; then 14439 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14440 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14441 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14442 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14443 # Going to short mode and back again did indeed matter. Since short mode is 14444 # case insensitive, let's make it lowercase to improve readability. 14445 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14446 # Now convert it back to Unix-stile (cygpath) 14447 input_path=`$CYGPATH -u "$shortmode_path"` 14448 new_path="$input_path" 14449 fi 14450 fi 14451 14452 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14453 if test "x$test_cygdrive_prefix" = x; then 14454 # As a simple fix, exclude /usr/bin since it's not a real path. 14455 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 14456 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 14457 # a path prefixed by /cygdrive for fixpath to work. 14458 new_path="$CYGWIN_ROOT_PATH$input_path" 14459 fi 14460 fi 14461 14462 14463 if test "x$path" != "x$new_path"; then 14464 BOOT_JDK="$new_path" 14465 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14466 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14467 fi 14468 14469 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14470 14471 path="$BOOT_JDK" 14472 has_colon=`$ECHO $path | $GREP ^.:` 14473 new_path="$path" 14474 if test "x$has_colon" = x; then 14475 # Not in mixed or Windows style, start by that. 14476 new_path=`cmd //c echo $path` 14477 fi 14478 14479 14480 input_path="$new_path" 14481 # Check if we need to convert this using DOS-style short mode. If the path 14482 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14483 # take no chances and rewrite it. 14484 # Note: m4 eats our [], so we need to use [ and ] instead. 14485 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 14486 if test "x$has_forbidden_chars" != x; then 14487 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14488 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14489 fi 14490 14491 14492 windows_path="$new_path" 14493 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14494 unix_path=`$CYGPATH -u "$windows_path"` 14495 new_path="$unix_path" 14496 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14497 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14498 new_path="$unix_path" 14499 fi 14500 14501 if test "x$path" != "x$new_path"; then 14502 BOOT_JDK="$new_path" 14503 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14504 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14505 fi 14506 14507 # Save the first 10 bytes of this path to the storage, so fixpath can work. 14508 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 14509 14510 else 14511 # We're on a posix platform. Hooray! :) 14512 path="$BOOT_JDK" 14513 14514 if test ! -f "$path" && test ! -d "$path"; then 14515 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 14516 fi 14517 14518 has_space=`$ECHO "$path" | $GREP " "` 14519 if test "x$has_space" != x; then 14520 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14521 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14522 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 14523 fi 14524 fi 14525 14526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 14527 $as_echo_n "checking for Boot JDK... " >&6; } 14528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 14529 $as_echo "$BOOT_JDK" >&6; } 14530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 14531 $as_echo_n "checking Boot JDK version... " >&6; } 14532 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 14533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 14534 $as_echo "$BOOT_JDK_VERSION" >&6; } 14535 fi # end check jdk version 14536 fi # end check rt.jar 14537 fi # end check javac 14538 fi # end check java 14539 fi # end check boot jdk found 14540 fi 14541 14542 done 14543 fi 14544 14545 fi 14546 14547 14548 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14549 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14550 # Do we have a bin/java? 14551 if test ! -x "$BOOT_JDK/bin/java"; then 14552 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14553 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14554 BOOT_JDK_FOUND=no 14555 else 14556 # Do we have a bin/javac? 14557 if test ! -x "$BOOT_JDK/bin/javac"; then 14558 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14559 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14560 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14561 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14562 BOOT_JDK_FOUND=no 14563 else 14564 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14565 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14566 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14567 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14568 BOOT_JDK_FOUND=no 14569 else 14570 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14571 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14572 14573 # Extra M4 quote needed to protect [] in grep expression. 14574 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14575 if test "x$FOUND_VERSION_78" = x; then 14576 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14577 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14578 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14579 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14580 BOOT_JDK_FOUND=no 14581 else 14582 # We're done! :-) 14583 BOOT_JDK_FOUND=yes 14584 14585 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14586 14587 # Input might be given as Windows format, start by converting to 14588 # unix format. 14589 path="$BOOT_JDK" 14590 new_path=`$CYGPATH -u "$path"` 14591 14592 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14593 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14594 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14595 # "foo.exe" is OK but "foo" is an error. 14596 # 14597 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14598 # It is also a way to make sure we got the proper file name for the real test later on. 14599 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14600 if test "x$test_shortpath" = x; then 14601 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14602 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14603 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14604 fi 14605 14606 # Call helper function which possibly converts this using DOS-style short mode. 14607 # If so, the updated path is stored in $new_path. 14608 14609 input_path="$new_path" 14610 # Check if we need to convert this using DOS-style short mode. If the path 14611 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14612 # take no chances and rewrite it. 14613 # Note: m4 eats our [], so we need to use [ and ] instead. 14614 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14615 if test "x$has_forbidden_chars" != x; then 14616 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14617 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14618 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14619 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14620 # Going to short mode and back again did indeed matter. Since short mode is 14621 # case insensitive, let's make it lowercase to improve readability. 14622 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14623 # Now convert it back to Unix-stile (cygpath) 14624 input_path=`$CYGPATH -u "$shortmode_path"` 14625 new_path="$input_path" 14626 fi 14627 fi 14628 14629 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14630 if test "x$test_cygdrive_prefix" = x; then 14631 # As a simple fix, exclude /usr/bin since it's not a real path. 14632 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 14633 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 14634 # a path prefixed by /cygdrive for fixpath to work. 14635 new_path="$CYGWIN_ROOT_PATH$input_path" 14636 fi 14637 fi 14638 14639 14640 if test "x$path" != "x$new_path"; then 14641 BOOT_JDK="$new_path" 14642 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14643 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14644 fi 14645 14646 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14647 14648 path="$BOOT_JDK" 14649 has_colon=`$ECHO $path | $GREP ^.:` 14650 new_path="$path" 14651 if test "x$has_colon" = x; then 14652 # Not in mixed or Windows style, start by that. 14653 new_path=`cmd //c echo $path` 14654 fi 14655 14656 14657 input_path="$new_path" 14658 # Check if we need to convert this using DOS-style short mode. If the path 14659 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14660 # take no chances and rewrite it. 14661 # Note: m4 eats our [], so we need to use [ and ] instead. 14662 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 14663 if test "x$has_forbidden_chars" != x; then 14664 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14665 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14666 fi 14667 14668 14669 windows_path="$new_path" 14670 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14671 unix_path=`$CYGPATH -u "$windows_path"` 14672 new_path="$unix_path" 14673 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14674 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14675 new_path="$unix_path" 14676 fi 14677 14678 if test "x$path" != "x$new_path"; then 14679 BOOT_JDK="$new_path" 14680 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14681 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14682 fi 14683 14684 # Save the first 10 bytes of this path to the storage, so fixpath can work. 14685 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 14686 14687 else 14688 # We're on a posix platform. Hooray! :) 14689 path="$BOOT_JDK" 14690 14691 if test ! -f "$path" && test ! -d "$path"; then 14692 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 14693 fi 14694 14695 has_space=`$ECHO "$path" | $GREP " "` 14696 if test "x$has_space" != x; then 14697 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14698 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14699 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 14700 fi 14701 fi 14702 14703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 14704 $as_echo_n "checking for Boot JDK... " >&6; } 14705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 14706 $as_echo "$BOOT_JDK" >&6; } 14707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 14708 $as_echo_n "checking Boot JDK version... " >&6; } 14709 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 14710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 14711 $as_echo "$BOOT_JDK_VERSION" >&6; } 14712 fi # end check jdk version 14713 fi # end check rt.jar 14714 fi # end check javac 14715 fi # end check java 14716 fi # end check boot jdk found 14717 fi 14718 14719 14720 if test "x$BOOT_JDK_FOUND" = xno; then 14721 # Now execute the test 14722 14723 BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java" 14724 BOOT_JDK_SUFFIX="" 14725 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 14726 if test "x$ALL_JDKS_FOUND" != x; then 14727 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 14728 14729 if test "x$BOOT_JDK_FOUND" = xno; then 14730 # Now execute the test 14731 14732 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 14733 if test -d "$BOOT_JDK"; then 14734 BOOT_JDK_FOUND=maybe 14735 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 14736 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 14737 fi 14738 14739 14740 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14741 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14742 # Do we have a bin/java? 14743 if test ! -x "$BOOT_JDK/bin/java"; then 14744 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14745 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14746 BOOT_JDK_FOUND=no 14747 else 14748 # Do we have a bin/javac? 14749 if test ! -x "$BOOT_JDK/bin/javac"; then 14750 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14751 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14752 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14753 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14754 BOOT_JDK_FOUND=no 14755 else 14756 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14757 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14758 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14759 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14760 BOOT_JDK_FOUND=no 14761 else 14762 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14763 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14764 14765 # Extra M4 quote needed to protect [] in grep expression. 14766 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14767 if test "x$FOUND_VERSION_78" = x; then 14768 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14769 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14770 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14771 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14772 BOOT_JDK_FOUND=no 14773 else 14774 # We're done! :-) 14775 BOOT_JDK_FOUND=yes 14776 14777 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14778 14779 # Input might be given as Windows format, start by converting to 14780 # unix format. 14781 path="$BOOT_JDK" 14782 new_path=`$CYGPATH -u "$path"` 14783 14784 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14785 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14786 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14787 # "foo.exe" is OK but "foo" is an error. 14788 # 14789 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14790 # It is also a way to make sure we got the proper file name for the real test later on. 14791 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14792 if test "x$test_shortpath" = x; then 14793 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14794 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14795 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14796 fi 14797 14798 # Call helper function which possibly converts this using DOS-style short mode. 14799 # If so, the updated path is stored in $new_path. 14800 14801 input_path="$new_path" 14802 # Check if we need to convert this using DOS-style short mode. If the path 14803 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14804 # take no chances and rewrite it. 14805 # Note: m4 eats our [], so we need to use [ and ] instead. 14806 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14807 if test "x$has_forbidden_chars" != x; then 14808 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14809 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14810 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14811 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14812 # Going to short mode and back again did indeed matter. Since short mode is 14813 # case insensitive, let's make it lowercase to improve readability. 14814 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14815 # Now convert it back to Unix-stile (cygpath) 14816 input_path=`$CYGPATH -u "$shortmode_path"` 14817 new_path="$input_path" 14818 fi 14819 fi 14820 14821 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14822 if test "x$test_cygdrive_prefix" = x; then 14823 # As a simple fix, exclude /usr/bin since it's not a real path. 14824 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 14825 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 14826 # a path prefixed by /cygdrive for fixpath to work. 14827 new_path="$CYGWIN_ROOT_PATH$input_path" 14828 fi 14829 fi 14830 14831 14832 if test "x$path" != "x$new_path"; then 14833 BOOT_JDK="$new_path" 14834 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14835 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14836 fi 14837 14838 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14839 14840 path="$BOOT_JDK" 14841 has_colon=`$ECHO $path | $GREP ^.:` 14842 new_path="$path" 14843 if test "x$has_colon" = x; then 14844 # Not in mixed or Windows style, start by that. 14845 new_path=`cmd //c echo $path` 14846 fi 14847 14848 14849 input_path="$new_path" 14850 # Check if we need to convert this using DOS-style short mode. If the path 14851 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14852 # take no chances and rewrite it. 14853 # Note: m4 eats our [], so we need to use [ and ] instead. 14854 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 14855 if test "x$has_forbidden_chars" != x; then 14856 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14857 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14858 fi 14859 14860 14861 windows_path="$new_path" 14862 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14863 unix_path=`$CYGPATH -u "$windows_path"` 14864 new_path="$unix_path" 14865 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14866 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14867 new_path="$unix_path" 14868 fi 14869 14870 if test "x$path" != "x$new_path"; then 14871 BOOT_JDK="$new_path" 14872 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14873 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14874 fi 14875 14876 # Save the first 10 bytes of this path to the storage, so fixpath can work. 14877 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 14878 14879 else 14880 # We're on a posix platform. Hooray! :) 14881 path="$BOOT_JDK" 14882 14883 if test ! -f "$path" && test ! -d "$path"; then 14884 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 14885 fi 14886 14887 has_space=`$ECHO "$path" | $GREP " "` 14888 if test "x$has_space" != x; then 14889 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14890 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14891 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 14892 fi 14893 fi 14894 14895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 14896 $as_echo_n "checking for Boot JDK... " >&6; } 14897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 14898 $as_echo "$BOOT_JDK" >&6; } 14899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 14900 $as_echo_n "checking Boot JDK version... " >&6; } 14901 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 14902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 14903 $as_echo "$BOOT_JDK_VERSION" >&6; } 14904 fi # end check jdk version 14905 fi # end check rt.jar 14906 fi # end check javac 14907 fi # end check java 14908 fi # end check boot jdk found 14909 fi 14910 14911 done 14912 fi 14913 14914 14915 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14916 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14917 # Do we have a bin/java? 14918 if test ! -x "$BOOT_JDK/bin/java"; then 14919 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14920 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14921 BOOT_JDK_FOUND=no 14922 else 14923 # Do we have a bin/javac? 14924 if test ! -x "$BOOT_JDK/bin/javac"; then 14925 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14926 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14927 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14928 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14929 BOOT_JDK_FOUND=no 14930 else 14931 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14932 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14933 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14934 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14935 BOOT_JDK_FOUND=no 14936 else 14937 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14938 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14939 14940 # Extra M4 quote needed to protect [] in grep expression. 14941 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14942 if test "x$FOUND_VERSION_78" = x; then 14943 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14944 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14945 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14946 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14947 BOOT_JDK_FOUND=no 14948 else 14949 # We're done! :-) 14950 BOOT_JDK_FOUND=yes 14951 14952 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14953 14954 # Input might be given as Windows format, start by converting to 14955 # unix format. 14956 path="$BOOT_JDK" 14957 new_path=`$CYGPATH -u "$path"` 14958 14959 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14960 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14961 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14962 # "foo.exe" is OK but "foo" is an error. 14963 # 14964 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14965 # It is also a way to make sure we got the proper file name for the real test later on. 14966 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14967 if test "x$test_shortpath" = x; then 14968 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14969 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14970 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14971 fi 14972 14973 # Call helper function which possibly converts this using DOS-style short mode. 14974 # If so, the updated path is stored in $new_path. 14975 14976 input_path="$new_path" 14977 # Check if we need to convert this using DOS-style short mode. If the path 14978 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14979 # take no chances and rewrite it. 14980 # Note: m4 eats our [], so we need to use [ and ] instead. 14981 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14982 if test "x$has_forbidden_chars" != x; then 14983 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14984 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14985 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14986 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14987 # Going to short mode and back again did indeed matter. Since short mode is 14988 # case insensitive, let's make it lowercase to improve readability. 14989 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14990 # Now convert it back to Unix-stile (cygpath) 14991 input_path=`$CYGPATH -u "$shortmode_path"` 14992 new_path="$input_path" 14993 fi 14994 fi 14995 14996 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14997 if test "x$test_cygdrive_prefix" = x; then 14998 # As a simple fix, exclude /usr/bin since it's not a real path. 14999 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15000 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15001 # a path prefixed by /cygdrive for fixpath to work. 15002 new_path="$CYGWIN_ROOT_PATH$input_path" 15003 fi 15004 fi 15005 15006 15007 if test "x$path" != "x$new_path"; then 15008 BOOT_JDK="$new_path" 15009 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15010 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15011 fi 15012 15013 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15014 15015 path="$BOOT_JDK" 15016 has_colon=`$ECHO $path | $GREP ^.:` 15017 new_path="$path" 15018 if test "x$has_colon" = x; then 15019 # Not in mixed or Windows style, start by that. 15020 new_path=`cmd //c echo $path` 15021 fi 15022 15023 15024 input_path="$new_path" 15025 # Check if we need to convert this using DOS-style short mode. If the path 15026 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15027 # take no chances and rewrite it. 15028 # Note: m4 eats our [], so we need to use [ and ] instead. 15029 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15030 if test "x$has_forbidden_chars" != x; then 15031 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15032 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15033 fi 15034 15035 15036 windows_path="$new_path" 15037 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15038 unix_path=`$CYGPATH -u "$windows_path"` 15039 new_path="$unix_path" 15040 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15041 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15042 new_path="$unix_path" 15043 fi 15044 15045 if test "x$path" != "x$new_path"; then 15046 BOOT_JDK="$new_path" 15047 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15048 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15049 fi 15050 15051 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15052 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15053 15054 else 15055 # We're on a posix platform. Hooray! :) 15056 path="$BOOT_JDK" 15057 15058 if test ! -f "$path" && test ! -d "$path"; then 15059 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 15060 fi 15061 15062 has_space=`$ECHO "$path" | $GREP " "` 15063 if test "x$has_space" != x; then 15064 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15065 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15066 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15067 fi 15068 fi 15069 15070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 15071 $as_echo_n "checking for Boot JDK... " >&6; } 15072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 15073 $as_echo "$BOOT_JDK" >&6; } 15074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 15075 $as_echo_n "checking Boot JDK version... " >&6; } 15076 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 15077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 15078 $as_echo "$BOOT_JDK_VERSION" >&6; } 15079 fi # end check jdk version 15080 fi # end check rt.jar 15081 fi # end check javac 15082 fi # end check java 15083 fi # end check boot jdk found 15084 fi 15085 15086 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 15087 15088 if test "x$BOOT_JDK_FOUND" = xno; then 15089 # Now execute the test 15090 15091 BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines" 15092 BOOT_JDK_SUFFIX="/Contents/Home" 15093 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 15094 if test "x$ALL_JDKS_FOUND" != x; then 15095 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 15096 15097 if test "x$BOOT_JDK_FOUND" = xno; then 15098 # Now execute the test 15099 15100 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 15101 if test -d "$BOOT_JDK"; then 15102 BOOT_JDK_FOUND=maybe 15103 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 15104 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 15105 fi 15106 15107 15108 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 15109 if test "x$BOOT_JDK_FOUND" = xmaybe; then 15110 # Do we have a bin/java? 15111 if test ! -x "$BOOT_JDK/bin/java"; then 15112 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 15113 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 15114 BOOT_JDK_FOUND=no 15115 else 15116 # Do we have a bin/javac? 15117 if test ! -x "$BOOT_JDK/bin/javac"; then 15118 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 15119 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 15120 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 15121 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 15122 BOOT_JDK_FOUND=no 15123 else 15124 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 15125 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 15126 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 15127 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 15128 BOOT_JDK_FOUND=no 15129 else 15130 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 15131 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 15132 15133 # Extra M4 quote needed to protect [] in grep expression. 15134 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 15135 if test "x$FOUND_VERSION_78" = x; then 15136 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 15137 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 15138 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 15139 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 15140 BOOT_JDK_FOUND=no 15141 else 15142 # We're done! :-) 15143 BOOT_JDK_FOUND=yes 15144 15145 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15146 15147 # Input might be given as Windows format, start by converting to 15148 # unix format. 15149 path="$BOOT_JDK" 15150 new_path=`$CYGPATH -u "$path"` 15151 15152 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15153 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15154 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15155 # "foo.exe" is OK but "foo" is an error. 15156 # 15157 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15158 # It is also a way to make sure we got the proper file name for the real test later on. 15159 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15160 if test "x$test_shortpath" = x; then 15161 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15162 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15163 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 15164 fi 15165 15166 # Call helper function which possibly converts this using DOS-style short mode. 15167 # If so, the updated path is stored in $new_path. 15168 15169 input_path="$new_path" 15170 # Check if we need to convert this using DOS-style short mode. If the path 15171 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15172 # take no chances and rewrite it. 15173 # Note: m4 eats our [], so we need to use [ and ] instead. 15174 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15175 if test "x$has_forbidden_chars" != x; then 15176 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15177 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15178 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15179 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15180 # Going to short mode and back again did indeed matter. Since short mode is 15181 # case insensitive, let's make it lowercase to improve readability. 15182 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15183 # Now convert it back to Unix-stile (cygpath) 15184 input_path=`$CYGPATH -u "$shortmode_path"` 15185 new_path="$input_path" 15186 fi 15187 fi 15188 15189 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15190 if test "x$test_cygdrive_prefix" = x; then 15191 # As a simple fix, exclude /usr/bin since it's not a real path. 15192 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15193 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15194 # a path prefixed by /cygdrive for fixpath to work. 15195 new_path="$CYGWIN_ROOT_PATH$input_path" 15196 fi 15197 fi 15198 15199 15200 if test "x$path" != "x$new_path"; then 15201 BOOT_JDK="$new_path" 15202 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15203 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15204 fi 15205 15206 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15207 15208 path="$BOOT_JDK" 15209 has_colon=`$ECHO $path | $GREP ^.:` 15210 new_path="$path" 15211 if test "x$has_colon" = x; then 15212 # Not in mixed or Windows style, start by that. 15213 new_path=`cmd //c echo $path` 15214 fi 15215 15216 15217 input_path="$new_path" 15218 # Check if we need to convert this using DOS-style short mode. If the path 15219 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15220 # take no chances and rewrite it. 15221 # Note: m4 eats our [], so we need to use [ and ] instead. 15222 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15223 if test "x$has_forbidden_chars" != x; then 15224 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15225 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15226 fi 15227 15228 15229 windows_path="$new_path" 15230 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15231 unix_path=`$CYGPATH -u "$windows_path"` 15232 new_path="$unix_path" 15233 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15234 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15235 new_path="$unix_path" 15236 fi 15237 15238 if test "x$path" != "x$new_path"; then 15239 BOOT_JDK="$new_path" 15240 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15241 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15242 fi 15243 15244 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15245 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15246 15247 else 15248 # We're on a posix platform. Hooray! :) 15249 path="$BOOT_JDK" 15250 15251 if test ! -f "$path" && test ! -d "$path"; then 15252 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 15253 fi 15254 15255 has_space=`$ECHO "$path" | $GREP " "` 15256 if test "x$has_space" != x; then 15257 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15258 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15259 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15260 fi 15261 fi 15262 15263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 15264 $as_echo_n "checking for Boot JDK... " >&6; } 15265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 15266 $as_echo "$BOOT_JDK" >&6; } 15267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 15268 $as_echo_n "checking Boot JDK version... " >&6; } 15269 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 15270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 15271 $as_echo "$BOOT_JDK_VERSION" >&6; } 15272 fi # end check jdk version 15273 fi # end check rt.jar 15274 fi # end check javac 15275 fi # end check java 15276 fi # end check boot jdk found 15277 fi 15278 15279 done 15280 fi 15281 15282 15283 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 15284 if test "x$BOOT_JDK_FOUND" = xmaybe; then 15285 # Do we have a bin/java? 15286 if test ! -x "$BOOT_JDK/bin/java"; then 15287 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 15288 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 15289 BOOT_JDK_FOUND=no 15290 else 15291 # Do we have a bin/javac? 15292 if test ! -x "$BOOT_JDK/bin/javac"; then 15293 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 15294 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 15295 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 15296 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 15297 BOOT_JDK_FOUND=no 15298 else 15299 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 15300 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 15301 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 15302 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 15303 BOOT_JDK_FOUND=no 15304 else 15305 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 15306 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 15307 15308 # Extra M4 quote needed to protect [] in grep expression. 15309 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 15310 if test "x$FOUND_VERSION_78" = x; then 15311 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 15312 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 15313 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 15314 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 15315 BOOT_JDK_FOUND=no 15316 else 15317 # We're done! :-) 15318 BOOT_JDK_FOUND=yes 15319 15320 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15321 15322 # Input might be given as Windows format, start by converting to 15323 # unix format. 15324 path="$BOOT_JDK" 15325 new_path=`$CYGPATH -u "$path"` 15326 15327 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15328 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15329 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15330 # "foo.exe" is OK but "foo" is an error. 15331 # 15332 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15333 # It is also a way to make sure we got the proper file name for the real test later on. 15334 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15335 if test "x$test_shortpath" = x; then 15336 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15337 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15338 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 15339 fi 15340 15341 # Call helper function which possibly converts this using DOS-style short mode. 15342 # If so, the updated path is stored in $new_path. 15343 15344 input_path="$new_path" 15345 # Check if we need to convert this using DOS-style short mode. If the path 15346 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15347 # take no chances and rewrite it. 15348 # Note: m4 eats our [], so we need to use [ and ] instead. 15349 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15350 if test "x$has_forbidden_chars" != x; then 15351 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15352 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15353 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15354 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15355 # Going to short mode and back again did indeed matter. Since short mode is 15356 # case insensitive, let's make it lowercase to improve readability. 15357 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15358 # Now convert it back to Unix-stile (cygpath) 15359 input_path=`$CYGPATH -u "$shortmode_path"` 15360 new_path="$input_path" 15361 fi 15362 fi 15363 15364 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15365 if test "x$test_cygdrive_prefix" = x; then 15366 # As a simple fix, exclude /usr/bin since it's not a real path. 15367 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15368 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15369 # a path prefixed by /cygdrive for fixpath to work. 15370 new_path="$CYGWIN_ROOT_PATH$input_path" 15371 fi 15372 fi 15373 15374 15375 if test "x$path" != "x$new_path"; then 15376 BOOT_JDK="$new_path" 15377 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15378 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15379 fi 15380 15381 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15382 15383 path="$BOOT_JDK" 15384 has_colon=`$ECHO $path | $GREP ^.:` 15385 new_path="$path" 15386 if test "x$has_colon" = x; then 15387 # Not in mixed or Windows style, start by that. 15388 new_path=`cmd //c echo $path` 15389 fi 15390 15391 15392 input_path="$new_path" 15393 # Check if we need to convert this using DOS-style short mode. If the path 15394 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15395 # take no chances and rewrite it. 15396 # Note: m4 eats our [], so we need to use [ and ] instead. 15397 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15398 if test "x$has_forbidden_chars" != x; then 15399 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15400 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15401 fi 15402 15403 15404 windows_path="$new_path" 15405 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15406 unix_path=`$CYGPATH -u "$windows_path"` 15407 new_path="$unix_path" 15408 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15409 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15410 new_path="$unix_path" 15411 fi 15412 15413 if test "x$path" != "x$new_path"; then 15414 BOOT_JDK="$new_path" 15415 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15416 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15417 fi 15418 15419 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15420 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15421 15422 else 15423 # We're on a posix platform. Hooray! :) 15424 path="$BOOT_JDK" 15425 15426 if test ! -f "$path" && test ! -d "$path"; then 15427 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 15428 fi 15429 15430 has_space=`$ECHO "$path" | $GREP " "` 15431 if test "x$has_space" != x; then 15432 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15433 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15434 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15435 fi 15436 fi 15437 15438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 15439 $as_echo_n "checking for Boot JDK... " >&6; } 15440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 15441 $as_echo "$BOOT_JDK" >&6; } 15442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 15443 $as_echo_n "checking Boot JDK version... " >&6; } 15444 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 15445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 15446 $as_echo "$BOOT_JDK_VERSION" >&6; } 15447 fi # end check jdk version 15448 fi # end check rt.jar 15449 fi # end check javac 15450 fi # end check java 15451 fi # end check boot jdk found 15452 fi 15453 15454 15455 if test "x$BOOT_JDK_FOUND" = xno; then 15456 # Now execute the test 15457 15458 BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines" 15459 BOOT_JDK_SUFFIX="/Contents/Home" 15460 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 15461 if test "x$ALL_JDKS_FOUND" != x; then 15462 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 15463 15464 if test "x$BOOT_JDK_FOUND" = xno; then 15465 # Now execute the test 15466 15467 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 15468 if test -d "$BOOT_JDK"; then 15469 BOOT_JDK_FOUND=maybe 15470 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 15471 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 15472 fi 15473 15474 15475 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 15476 if test "x$BOOT_JDK_FOUND" = xmaybe; then 15477 # Do we have a bin/java? 15478 if test ! -x "$BOOT_JDK/bin/java"; then 15479 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 15480 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 15481 BOOT_JDK_FOUND=no 15482 else 15483 # Do we have a bin/javac? 15484 if test ! -x "$BOOT_JDK/bin/javac"; then 15485 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 15486 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 15487 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 15488 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 15489 BOOT_JDK_FOUND=no 15490 else 15491 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 15492 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 15493 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 15494 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 15495 BOOT_JDK_FOUND=no 15496 else 15497 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 15498 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 15499 15500 # Extra M4 quote needed to protect [] in grep expression. 15501 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 15502 if test "x$FOUND_VERSION_78" = x; then 15503 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 15504 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 15505 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 15506 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 15507 BOOT_JDK_FOUND=no 15508 else 15509 # We're done! :-) 15510 BOOT_JDK_FOUND=yes 15511 15512 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15513 15514 # Input might be given as Windows format, start by converting to 15515 # unix format. 15516 path="$BOOT_JDK" 15517 new_path=`$CYGPATH -u "$path"` 15518 15519 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15520 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15521 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15522 # "foo.exe" is OK but "foo" is an error. 15523 # 15524 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15525 # It is also a way to make sure we got the proper file name for the real test later on. 15526 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15527 if test "x$test_shortpath" = x; then 15528 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15529 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15530 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 15531 fi 15532 15533 # Call helper function which possibly converts this using DOS-style short mode. 15534 # If so, the updated path is stored in $new_path. 15535 15536 input_path="$new_path" 15537 # Check if we need to convert this using DOS-style short mode. If the path 15538 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15539 # take no chances and rewrite it. 15540 # Note: m4 eats our [], so we need to use [ and ] instead. 15541 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15542 if test "x$has_forbidden_chars" != x; then 15543 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15544 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15545 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15546 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15547 # Going to short mode and back again did indeed matter. Since short mode is 15548 # case insensitive, let's make it lowercase to improve readability. 15549 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15550 # Now convert it back to Unix-stile (cygpath) 15551 input_path=`$CYGPATH -u "$shortmode_path"` 15552 new_path="$input_path" 15553 fi 15554 fi 15555 15556 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15557 if test "x$test_cygdrive_prefix" = x; then 15558 # As a simple fix, exclude /usr/bin since it's not a real path. 15559 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15560 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15561 # a path prefixed by /cygdrive for fixpath to work. 15562 new_path="$CYGWIN_ROOT_PATH$input_path" 15563 fi 15564 fi 15565 15566 15567 if test "x$path" != "x$new_path"; then 15568 BOOT_JDK="$new_path" 15569 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15570 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15571 fi 15572 15573 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15574 15575 path="$BOOT_JDK" 15576 has_colon=`$ECHO $path | $GREP ^.:` 15577 new_path="$path" 15578 if test "x$has_colon" = x; then 15579 # Not in mixed or Windows style, start by that. 15580 new_path=`cmd //c echo $path` 15581 fi 15582 15583 15584 input_path="$new_path" 15585 # Check if we need to convert this using DOS-style short mode. If the path 15586 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15587 # take no chances and rewrite it. 15588 # Note: m4 eats our [], so we need to use [ and ] instead. 15589 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15590 if test "x$has_forbidden_chars" != x; then 15591 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15592 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15593 fi 15594 15595 15596 windows_path="$new_path" 15597 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15598 unix_path=`$CYGPATH -u "$windows_path"` 15599 new_path="$unix_path" 15600 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15601 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15602 new_path="$unix_path" 15603 fi 15604 15605 if test "x$path" != "x$new_path"; then 15606 BOOT_JDK="$new_path" 15607 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15608 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15609 fi 15610 15611 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15612 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15613 15614 else 15615 # We're on a posix platform. Hooray! :) 15616 path="$BOOT_JDK" 15617 15618 if test ! -f "$path" && test ! -d "$path"; then 15619 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 15620 fi 15621 15622 has_space=`$ECHO "$path" | $GREP " "` 15623 if test "x$has_space" != x; then 15624 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15625 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15626 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15627 fi 15628 fi 15629 15630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 15631 $as_echo_n "checking for Boot JDK... " >&6; } 15632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 15633 $as_echo "$BOOT_JDK" >&6; } 15634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 15635 $as_echo_n "checking Boot JDK version... " >&6; } 15636 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 15637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 15638 $as_echo "$BOOT_JDK_VERSION" >&6; } 15639 fi # end check jdk version 15640 fi # end check rt.jar 15641 fi # end check javac 15642 fi # end check java 15643 fi # end check boot jdk found 15644 fi 15645 15646 done 15647 fi 15648 15649 15650 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 15651 if test "x$BOOT_JDK_FOUND" = xmaybe; then 15652 # Do we have a bin/java? 15653 if test ! -x "$BOOT_JDK/bin/java"; then 15654 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 15655 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 15656 BOOT_JDK_FOUND=no 15657 else 15658 # Do we have a bin/javac? 15659 if test ! -x "$BOOT_JDK/bin/javac"; then 15660 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 15661 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 15662 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 15663 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 15664 BOOT_JDK_FOUND=no 15665 else 15666 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 15667 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 15668 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 15669 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 15670 BOOT_JDK_FOUND=no 15671 else 15672 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 15673 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 15674 15675 # Extra M4 quote needed to protect [] in grep expression. 15676 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 15677 if test "x$FOUND_VERSION_78" = x; then 15678 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 15679 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 15680 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 15681 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 15682 BOOT_JDK_FOUND=no 15683 else 15684 # We're done! :-) 15685 BOOT_JDK_FOUND=yes 15686 15687 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15688 15689 # Input might be given as Windows format, start by converting to 15690 # unix format. 15691 path="$BOOT_JDK" 15692 new_path=`$CYGPATH -u "$path"` 15693 15694 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15695 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15696 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15697 # "foo.exe" is OK but "foo" is an error. 15698 # 15699 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15700 # It is also a way to make sure we got the proper file name for the real test later on. 15701 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15702 if test "x$test_shortpath" = x; then 15703 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15704 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15705 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 15706 fi 15707 15708 # Call helper function which possibly converts this using DOS-style short mode. 15709 # If so, the updated path is stored in $new_path. 15710 15711 input_path="$new_path" 15712 # Check if we need to convert this using DOS-style short mode. If the path 15713 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15714 # take no chances and rewrite it. 15715 # Note: m4 eats our [], so we need to use [ and ] instead. 15716 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15717 if test "x$has_forbidden_chars" != x; then 15718 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15719 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15720 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15721 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15722 # Going to short mode and back again did indeed matter. Since short mode is 15723 # case insensitive, let's make it lowercase to improve readability. 15724 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15725 # Now convert it back to Unix-stile (cygpath) 15726 input_path=`$CYGPATH -u "$shortmode_path"` 15727 new_path="$input_path" 15728 fi 15729 fi 15730 15731 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15732 if test "x$test_cygdrive_prefix" = x; then 15733 # As a simple fix, exclude /usr/bin since it's not a real path. 15734 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15735 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15736 # a path prefixed by /cygdrive for fixpath to work. 15737 new_path="$CYGWIN_ROOT_PATH$input_path" 15738 fi 15739 fi 15740 15741 15742 if test "x$path" != "x$new_path"; then 15743 BOOT_JDK="$new_path" 15744 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15745 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15746 fi 15747 15748 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15749 15750 path="$BOOT_JDK" 15751 has_colon=`$ECHO $path | $GREP ^.:` 15752 new_path="$path" 15753 if test "x$has_colon" = x; then 15754 # Not in mixed or Windows style, start by that. 15755 new_path=`cmd //c echo $path` 15756 fi 15757 15758 15759 input_path="$new_path" 15760 # Check if we need to convert this using DOS-style short mode. If the path 15761 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15762 # take no chances and rewrite it. 15763 # Note: m4 eats our [], so we need to use [ and ] instead. 15764 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15765 if test "x$has_forbidden_chars" != x; then 15766 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15767 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15768 fi 15769 15770 15771 windows_path="$new_path" 15772 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15773 unix_path=`$CYGPATH -u "$windows_path"` 15774 new_path="$unix_path" 15775 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15776 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15777 new_path="$unix_path" 15778 fi 15779 15780 if test "x$path" != "x$new_path"; then 15781 BOOT_JDK="$new_path" 15782 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15783 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15784 fi 15785 15786 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15787 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15788 15789 else 15790 # We're on a posix platform. Hooray! :) 15791 path="$BOOT_JDK" 15792 15793 if test ! -f "$path" && test ! -d "$path"; then 15794 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 15795 fi 15796 15797 has_space=`$ECHO "$path" | $GREP " "` 15798 if test "x$has_space" != x; then 15799 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15800 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15801 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15802 fi 15803 fi 15804 15805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 15806 $as_echo_n "checking for Boot JDK... " >&6; } 15807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 15808 $as_echo "$BOOT_JDK" >&6; } 15809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 15810 $as_echo_n "checking Boot JDK version... " >&6; } 15811 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 15812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 15813 $as_echo "$BOOT_JDK_VERSION" >&6; } 15814 fi # end check jdk version 15815 fi # end check rt.jar 15816 fi # end check javac 15817 fi # end check java 15818 fi # end check boot jdk found 15819 fi 15820 15821 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 15822 15823 if test "x$BOOT_JDK_FOUND" = xno; then 15824 # Now execute the test 15825 15826 BOOT_JDK_PREFIX="/usr/lib/jvm" 15827 BOOT_JDK_SUFFIX="" 15828 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 15829 if test "x$ALL_JDKS_FOUND" != x; then 15830 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 15831 15832 if test "x$BOOT_JDK_FOUND" = xno; then 15833 # Now execute the test 15834 15835 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 15836 if test -d "$BOOT_JDK"; then 15837 BOOT_JDK_FOUND=maybe 15838 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 15839 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 15840 fi 15841 15842 15843 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 15844 if test "x$BOOT_JDK_FOUND" = xmaybe; then 15845 # Do we have a bin/java? 15846 if test ! -x "$BOOT_JDK/bin/java"; then 15847 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 15848 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 15849 BOOT_JDK_FOUND=no 15850 else 15851 # Do we have a bin/javac? 15852 if test ! -x "$BOOT_JDK/bin/javac"; then 15853 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 15854 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 15855 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 15856 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 15857 BOOT_JDK_FOUND=no 15858 else 15859 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 15860 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 15861 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 15862 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 15863 BOOT_JDK_FOUND=no 15864 else 15865 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 15866 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 15867 15868 # Extra M4 quote needed to protect [] in grep expression. 15869 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 15870 if test "x$FOUND_VERSION_78" = x; then 15871 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 15872 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 15873 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 15874 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 15875 BOOT_JDK_FOUND=no 15876 else 15877 # We're done! :-) 15878 BOOT_JDK_FOUND=yes 15879 15880 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15881 15882 # Input might be given as Windows format, start by converting to 15883 # unix format. 15884 path="$BOOT_JDK" 15885 new_path=`$CYGPATH -u "$path"` 15886 15887 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15888 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15889 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15890 # "foo.exe" is OK but "foo" is an error. 15891 # 15892 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15893 # It is also a way to make sure we got the proper file name for the real test later on. 15894 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15895 if test "x$test_shortpath" = x; then 15896 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15897 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15898 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 15899 fi 15900 15901 # Call helper function which possibly converts this using DOS-style short mode. 15902 # If so, the updated path is stored in $new_path. 15903 15904 input_path="$new_path" 15905 # Check if we need to convert this using DOS-style short mode. If the path 15906 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15907 # take no chances and rewrite it. 15908 # Note: m4 eats our [], so we need to use [ and ] instead. 15909 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15910 if test "x$has_forbidden_chars" != x; then 15911 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15912 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15913 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15914 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15915 # Going to short mode and back again did indeed matter. Since short mode is 15916 # case insensitive, let's make it lowercase to improve readability. 15917 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15918 # Now convert it back to Unix-stile (cygpath) 15919 input_path=`$CYGPATH -u "$shortmode_path"` 15920 new_path="$input_path" 15921 fi 15922 fi 15923 15924 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15925 if test "x$test_cygdrive_prefix" = x; then 15926 # As a simple fix, exclude /usr/bin since it's not a real path. 15927 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15928 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15929 # a path prefixed by /cygdrive for fixpath to work. 15930 new_path="$CYGWIN_ROOT_PATH$input_path" 15931 fi 15932 fi 15933 15934 15935 if test "x$path" != "x$new_path"; then 15936 BOOT_JDK="$new_path" 15937 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15938 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15939 fi 15940 15941 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15942 15943 path="$BOOT_JDK" 15944 has_colon=`$ECHO $path | $GREP ^.:` 15945 new_path="$path" 15946 if test "x$has_colon" = x; then 15947 # Not in mixed or Windows style, start by that. 15948 new_path=`cmd //c echo $path` 15949 fi 15950 15951 15952 input_path="$new_path" 15953 # Check if we need to convert this using DOS-style short mode. If the path 15954 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15955 # take no chances and rewrite it. 15956 # Note: m4 eats our [], so we need to use [ and ] instead. 15957 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15958 if test "x$has_forbidden_chars" != x; then 15959 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15960 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15961 fi 15962 15963 15964 windows_path="$new_path" 15965 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15966 unix_path=`$CYGPATH -u "$windows_path"` 15967 new_path="$unix_path" 15968 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15969 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15970 new_path="$unix_path" 15971 fi 15972 15973 if test "x$path" != "x$new_path"; then 15974 BOOT_JDK="$new_path" 15975 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15976 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15977 fi 15978 15979 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15980 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15981 15982 else 15983 # We're on a posix platform. Hooray! :) 15984 path="$BOOT_JDK" 15985 15986 if test ! -f "$path" && test ! -d "$path"; then 15987 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 15988 fi 15989 15990 has_space=`$ECHO "$path" | $GREP " "` 15991 if test "x$has_space" != x; then 15992 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15993 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15994 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15995 fi 15996 fi 15997 15998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 15999 $as_echo_n "checking for Boot JDK... " >&6; } 16000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 16001 $as_echo "$BOOT_JDK" >&6; } 16002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 16003 $as_echo_n "checking Boot JDK version... " >&6; } 16004 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 16005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 16006 $as_echo "$BOOT_JDK_VERSION" >&6; } 16007 fi # end check jdk version 16008 fi # end check rt.jar 16009 fi # end check javac 16010 fi # end check java 16011 fi # end check boot jdk found 16012 fi 16013 16014 done 16015 fi 16016 16017 16018 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 16019 if test "x$BOOT_JDK_FOUND" = xmaybe; then 16020 # Do we have a bin/java? 16021 if test ! -x "$BOOT_JDK/bin/java"; then 16022 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 16023 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 16024 BOOT_JDK_FOUND=no 16025 else 16026 # Do we have a bin/javac? 16027 if test ! -x "$BOOT_JDK/bin/javac"; then 16028 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 16029 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 16030 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 16031 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 16032 BOOT_JDK_FOUND=no 16033 else 16034 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 16035 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 16036 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 16037 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 16038 BOOT_JDK_FOUND=no 16039 else 16040 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 16041 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 16042 16043 # Extra M4 quote needed to protect [] in grep expression. 16044 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 16045 if test "x$FOUND_VERSION_78" = x; then 16046 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 16047 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 16048 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 16049 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 16050 BOOT_JDK_FOUND=no 16051 else 16052 # We're done! :-) 16053 BOOT_JDK_FOUND=yes 16054 16055 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16056 16057 # Input might be given as Windows format, start by converting to 16058 # unix format. 16059 path="$BOOT_JDK" 16060 new_path=`$CYGPATH -u "$path"` 16061 16062 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16063 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16064 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16065 # "foo.exe" is OK but "foo" is an error. 16066 # 16067 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16068 # It is also a way to make sure we got the proper file name for the real test later on. 16069 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16070 if test "x$test_shortpath" = x; then 16071 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 16072 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 16073 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 16074 fi 16075 16076 # Call helper function which possibly converts this using DOS-style short mode. 16077 # If so, the updated path is stored in $new_path. 16078 16079 input_path="$new_path" 16080 # Check if we need to convert this using DOS-style short mode. If the path 16081 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16082 # take no chances and rewrite it. 16083 # Note: m4 eats our [], so we need to use [ and ] instead. 16084 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16085 if test "x$has_forbidden_chars" != x; then 16086 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16087 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16088 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16089 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16090 # Going to short mode and back again did indeed matter. Since short mode is 16091 # case insensitive, let's make it lowercase to improve readability. 16092 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16093 # Now convert it back to Unix-stile (cygpath) 16094 input_path=`$CYGPATH -u "$shortmode_path"` 16095 new_path="$input_path" 16096 fi 16097 fi 16098 16099 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16100 if test "x$test_cygdrive_prefix" = x; then 16101 # As a simple fix, exclude /usr/bin since it's not a real path. 16102 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16103 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16104 # a path prefixed by /cygdrive for fixpath to work. 16105 new_path="$CYGWIN_ROOT_PATH$input_path" 16106 fi 16107 fi 16108 16109 16110 if test "x$path" != "x$new_path"; then 16111 BOOT_JDK="$new_path" 16112 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 16113 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 16114 fi 16115 16116 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16117 16118 path="$BOOT_JDK" 16119 has_colon=`$ECHO $path | $GREP ^.:` 16120 new_path="$path" 16121 if test "x$has_colon" = x; then 16122 # Not in mixed or Windows style, start by that. 16123 new_path=`cmd //c echo $path` 16124 fi 16125 16126 16127 input_path="$new_path" 16128 # Check if we need to convert this using DOS-style short mode. If the path 16129 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16130 # take no chances and rewrite it. 16131 # Note: m4 eats our [], so we need to use [ and ] instead. 16132 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16133 if test "x$has_forbidden_chars" != x; then 16134 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16135 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16136 fi 16137 16138 16139 windows_path="$new_path" 16140 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16141 unix_path=`$CYGPATH -u "$windows_path"` 16142 new_path="$unix_path" 16143 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16144 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16145 new_path="$unix_path" 16146 fi 16147 16148 if test "x$path" != "x$new_path"; then 16149 BOOT_JDK="$new_path" 16150 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 16151 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 16152 fi 16153 16154 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16155 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16156 16157 else 16158 # We're on a posix platform. Hooray! :) 16159 path="$BOOT_JDK" 16160 16161 if test ! -f "$path" && test ! -d "$path"; then 16162 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 16163 fi 16164 16165 has_space=`$ECHO "$path" | $GREP " "` 16166 if test "x$has_space" != x; then 16167 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 16168 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 16169 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16170 fi 16171 fi 16172 16173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 16174 $as_echo_n "checking for Boot JDK... " >&6; } 16175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 16176 $as_echo "$BOOT_JDK" >&6; } 16177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 16178 $as_echo_n "checking Boot JDK version... " >&6; } 16179 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 16180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 16181 $as_echo "$BOOT_JDK_VERSION" >&6; } 16182 fi # end check jdk version 16183 fi # end check rt.jar 16184 fi # end check javac 16185 fi # end check java 16186 fi # end check boot jdk found 16187 fi 16188 16189 fi 16190 16191 16192 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 16193 if test "x$BOOT_JDK_FOUND" = xmaybe; then 16194 # Do we have a bin/java? 16195 if test ! -x "$BOOT_JDK/bin/java"; then 16196 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 16197 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 16198 BOOT_JDK_FOUND=no 16199 else 16200 # Do we have a bin/javac? 16201 if test ! -x "$BOOT_JDK/bin/javac"; then 16202 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 16203 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 16204 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 16205 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 16206 BOOT_JDK_FOUND=no 16207 else 16208 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 16209 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 16210 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 16211 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 16212 BOOT_JDK_FOUND=no 16213 else 16214 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 16215 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 16216 16217 # Extra M4 quote needed to protect [] in grep expression. 16218 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 16219 if test "x$FOUND_VERSION_78" = x; then 16220 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 16221 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 16222 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 16223 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 16224 BOOT_JDK_FOUND=no 16225 else 16226 # We're done! :-) 16227 BOOT_JDK_FOUND=yes 16228 16229 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16230 16231 # Input might be given as Windows format, start by converting to 16232 # unix format. 16233 path="$BOOT_JDK" 16234 new_path=`$CYGPATH -u "$path"` 16235 16236 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16237 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16238 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16239 # "foo.exe" is OK but "foo" is an error. 16240 # 16241 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16242 # It is also a way to make sure we got the proper file name for the real test later on. 16243 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16244 if test "x$test_shortpath" = x; then 16245 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 16246 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 16247 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 16248 fi 16249 16250 # Call helper function which possibly converts this using DOS-style short mode. 16251 # If so, the updated path is stored in $new_path. 16252 16253 input_path="$new_path" 16254 # Check if we need to convert this using DOS-style short mode. If the path 16255 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16256 # take no chances and rewrite it. 16257 # Note: m4 eats our [], so we need to use [ and ] instead. 16258 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16259 if test "x$has_forbidden_chars" != x; then 16260 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16261 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16262 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16263 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16264 # Going to short mode and back again did indeed matter. Since short mode is 16265 # case insensitive, let's make it lowercase to improve readability. 16266 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16267 # Now convert it back to Unix-stile (cygpath) 16268 input_path=`$CYGPATH -u "$shortmode_path"` 16269 new_path="$input_path" 16270 fi 16271 fi 16272 16273 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16274 if test "x$test_cygdrive_prefix" = x; then 16275 # As a simple fix, exclude /usr/bin since it's not a real path. 16276 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16277 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16278 # a path prefixed by /cygdrive for fixpath to work. 16279 new_path="$CYGWIN_ROOT_PATH$input_path" 16280 fi 16281 fi 16282 16283 16284 if test "x$path" != "x$new_path"; then 16285 BOOT_JDK="$new_path" 16286 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 16287 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 16288 fi 16289 16290 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16291 16292 path="$BOOT_JDK" 16293 has_colon=`$ECHO $path | $GREP ^.:` 16294 new_path="$path" 16295 if test "x$has_colon" = x; then 16296 # Not in mixed or Windows style, start by that. 16297 new_path=`cmd //c echo $path` 16298 fi 16299 16300 16301 input_path="$new_path" 16302 # Check if we need to convert this using DOS-style short mode. If the path 16303 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16304 # take no chances and rewrite it. 16305 # Note: m4 eats our [], so we need to use [ and ] instead. 16306 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16307 if test "x$has_forbidden_chars" != x; then 16308 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16309 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16310 fi 16311 16312 16313 windows_path="$new_path" 16314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16315 unix_path=`$CYGPATH -u "$windows_path"` 16316 new_path="$unix_path" 16317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16318 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16319 new_path="$unix_path" 16320 fi 16321 16322 if test "x$path" != "x$new_path"; then 16323 BOOT_JDK="$new_path" 16324 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 16325 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 16326 fi 16327 16328 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16329 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16330 16331 else 16332 # We're on a posix platform. Hooray! :) 16333 path="$BOOT_JDK" 16334 16335 if test ! -f "$path" && test ! -d "$path"; then 16336 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 16337 fi 16338 16339 has_space=`$ECHO "$path" | $GREP " "` 16340 if test "x$has_space" != x; then 16341 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 16342 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 16343 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16344 fi 16345 fi 16346 16347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 16348 $as_echo_n "checking for Boot JDK... " >&6; } 16349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 16350 $as_echo "$BOOT_JDK" >&6; } 16351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 16352 $as_echo_n "checking Boot JDK version... " >&6; } 16353 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 16354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 16355 $as_echo "$BOOT_JDK_VERSION" >&6; } 16356 fi # end check jdk version 16357 fi # end check rt.jar 16358 fi # end check javac 16359 fi # end check java 16360 fi # end check boot jdk found 16361 fi 16362 16363 16364 # If we haven't found anything yet, we've truly lost. Give up. 16365 if test "x$BOOT_JDK_FOUND" = xno; then 16366 16367 # Print a helpful message on how to acquire the necessary build dependency. 16368 # openjdk is the help tag: freetyp2, cups, pulse, alsa etc 16369 MISSING_DEPENDENCY=openjdk 16370 PKGHANDLER_COMMAND= 16371 16372 case $PKGHANDLER in 16373 apt-get) 16374 apt_help $MISSING_DEPENDENCY ;; 16375 yum) 16376 yum_help $MISSING_DEPENDENCY ;; 16377 port) 16378 port_help $MISSING_DEPENDENCY ;; 16379 pkgutil) 16380 pkgutil_help $MISSING_DEPENDENCY ;; 16381 pkgadd) 16382 pkgadd_help $MISSING_DEPENDENCY ;; 16383 * ) 16384 break ;; 16385 esac 16386 16387 if test "x$PKGHANDLER_COMMAND" != x; then 16388 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 16389 fi 16390 16391 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5 16392 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;} 16393 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5 16394 $as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;} 16395 as_fn_error $? "Cannot continue" "$LINENO" 5 16396 fi 16397 16398 # Setup proper paths for what we found 16399 BOOT_RTJAR="$BOOT_JDK/jre/lib/rt.jar" 16400 if test ! -f "$BOOT_RTJAR"; then 16401 # On MacOSX it is called classes.jar 16402 BOOT_RTJAR="$BOOT_JDK/../Classes/classes.jar" 16403 if test -f "$BOOT_RTJAR"; then 16404 # Remove the .. 16405 BOOT_RTJAR="`cd ${BOOT_RTJAR%/*} && pwd`/${BOOT_RTJAR##*/}" 16406 fi 16407 fi 16408 BOOT_TOOLSJAR="$BOOT_JDK/lib/tools.jar" 16409 BOOT_JDK="$BOOT_JDK" 16410 16411 16412 16413 16414 # Setup tools from the Boot JDK. 16415 16416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 16417 $as_echo_n "checking for java in Boot JDK... " >&6; } 16418 JAVA=$BOOT_JDK/bin/java 16419 if test ! -x $JAVA; then 16420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 16421 $as_echo "not found" >&6; } 16422 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 16423 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 16424 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 16425 fi 16426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 16427 $as_echo "ok" >&6; } 16428 16429 16430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 16431 $as_echo_n "checking for javac in Boot JDK... " >&6; } 16432 JAVAC=$BOOT_JDK/bin/javac 16433 if test ! -x $JAVAC; then 16434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 16435 $as_echo "not found" >&6; } 16436 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 16437 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 16438 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 16439 fi 16440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 16441 $as_echo "ok" >&6; } 16442 16443 16444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 16445 $as_echo_n "checking for javah in Boot JDK... " >&6; } 16446 JAVAH=$BOOT_JDK/bin/javah 16447 if test ! -x $JAVAH; then 16448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 16449 $as_echo "not found" >&6; } 16450 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 16451 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 16452 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 16453 fi 16454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 16455 $as_echo "ok" >&6; } 16456 16457 16458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javap in Boot JDK" >&5 16459 $as_echo_n "checking for javap in Boot JDK... " >&6; } 16460 JAVAP=$BOOT_JDK/bin/javap 16461 if test ! -x $JAVAP; then 16462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 16463 $as_echo "not found" >&6; } 16464 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 16465 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 16466 as_fn_error $? "Could not find javap in the Boot JDK" "$LINENO" 5 16467 fi 16468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 16469 $as_echo "ok" >&6; } 16470 16471 16472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 16473 $as_echo_n "checking for jar in Boot JDK... " >&6; } 16474 JAR=$BOOT_JDK/bin/jar 16475 if test ! -x $JAR; then 16476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 16477 $as_echo "not found" >&6; } 16478 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 16479 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 16480 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 16481 fi 16482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 16483 $as_echo "ok" >&6; } 16484 16485 16486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rmic in Boot JDK" >&5 16487 $as_echo_n "checking for rmic in Boot JDK... " >&6; } 16488 RMIC=$BOOT_JDK/bin/rmic 16489 if test ! -x $RMIC; then 16490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 16491 $as_echo "not found" >&6; } 16492 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 16493 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 16494 as_fn_error $? "Could not find rmic in the Boot JDK" "$LINENO" 5 16495 fi 16496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 16497 $as_echo "ok" >&6; } 16498 16499 16500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5 16501 $as_echo_n "checking for native2ascii in Boot JDK... " >&6; } 16502 NATIVE2ASCII=$BOOT_JDK/bin/native2ascii 16503 if test ! -x $NATIVE2ASCII; then 16504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 16505 $as_echo "not found" >&6; } 16506 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 16507 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 16508 as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5 16509 fi 16510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 16511 $as_echo "ok" >&6; } 16512 16513 16514 # Finally, set some other options... 16515 16516 # When compiling code to be executed by the Boot JDK, force jdk7 compatibility. 16517 BOOT_JDK_SOURCETARGET="-source 7 -target 7" 16518 16519 16520 16521 16522 ############################################################################## 16523 # 16524 # Specify options for anything that is run with the Boot JDK. 16525 # 16526 16527 # Check whether --with-boot-jdk-jvmargs was given. 16528 if test "${with_boot_jdk_jvmargs+set}" = set; then : 16529 withval=$with_boot_jdk_jvmargs; 16530 fi 16531 16532 16533 if test "x$with_boot_jdk_jvmargs" = x; then 16534 # Not all JVM:s accept the same arguments on the command line. 16535 # OpenJDK specific increase in thread stack for JDK build, 16536 # well more specifically, when running javac. 16537 if test "x$BUILD_NUM_BITS" = x32; then 16538 STACK_SIZE=768 16539 else 16540 # Running Javac on a JVM on a 64-bit machine, the stack takes more space 16541 # since 64-bit pointers are pushed on the stach. Apparently, we need 16542 # to increase the stack space when javacing the JDK.... 16543 STACK_SIZE=1536 16544 fi 16545 16546 # Minimum amount of heap memory. 16547 16548 # Test if -Xms64M is a valid argument to $JAVA (often is $JAVA passed as $JAVA) 16549 # If so, then append -Xms64M to boot_jdk_jvmargs 16550 FOUND_WARN=`$JAVA -Xms64M -version 2>&1 | grep -i warn` 16551 FOUND_VERSION=`$JAVA -Xms64M -version 2>&1 | grep " version \""` 16552 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 16553 boot_jdk_jvmargs="$boot_jdk_jvmargs -Xms64M" 16554 fi 16555 16556 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 16557 # Why does macosx need more heap? Its the huge JDK batch. 16558 16559 # Test if -Xmx1600M is a valid argument to $JAVA (often is $JAVA passed as $JAVA) 16560 # If so, then append -Xmx1600M to boot_jdk_jvmargs 16561 FOUND_WARN=`$JAVA -Xmx1600M -version 2>&1 | grep -i warn` 16562 FOUND_VERSION=`$JAVA -Xmx1600M -version 2>&1 | grep " version \""` 16563 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 16564 boot_jdk_jvmargs="$boot_jdk_jvmargs -Xmx1600M" 16565 fi 16566 16567 else 16568 16569 # Test if -Xmx1100M is a valid argument to $JAVA (often is $JAVA passed as $JAVA) 16570 # If so, then append -Xmx1100M to boot_jdk_jvmargs 16571 FOUND_WARN=`$JAVA -Xmx1100M -version 2>&1 | grep -i warn` 16572 FOUND_VERSION=`$JAVA -Xmx1100M -version 2>&1 | grep " version \""` 16573 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 16574 boot_jdk_jvmargs="$boot_jdk_jvmargs -Xmx1100M" 16575 fi 16576 16577 fi 16578 # When is adding -client something that speeds up the JVM? 16579 # ADD_JVM_ARG_IF_OK([-client],boot_jdk_jvmargs,[$JAVA]) 16580 16581 # Test if -XX:PermSize=32m is a valid argument to $JAVA (often is $JAVA passed as $JAVA) 16582 # If so, then append -XX:PermSize=32m to boot_jdk_jvmargs 16583 FOUND_WARN=`$JAVA -XX:PermSize=32m -version 2>&1 | grep -i warn` 16584 FOUND_VERSION=`$JAVA -XX:PermSize=32m -version 2>&1 | grep " version \""` 16585 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 16586 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:PermSize=32m" 16587 fi 16588 16589 16590 # Test if -XX:MaxPermSize=160m is a valid argument to $JAVA (often is $JAVA passed as $JAVA) 16591 # If so, then append -XX:MaxPermSize=160m to boot_jdk_jvmargs 16592 FOUND_WARN=`$JAVA -XX:MaxPermSize=160m -version 2>&1 | grep -i warn` 16593 FOUND_VERSION=`$JAVA -XX:MaxPermSize=160m -version 2>&1 | grep " version \""` 16594 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 16595 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:MaxPermSize=160m" 16596 fi 16597 16598 16599 # Test if -XX:ThreadStackSize=$STACK_SIZE is a valid argument to $JAVA (often is $JAVA passed as $JAVA) 16600 # If so, then append -XX:ThreadStackSize=$STACK_SIZE to boot_jdk_jvmargs 16601 FOUND_WARN=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1 | grep -i warn` 16602 FOUND_VERSION=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1 | grep " version \""` 16603 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 16604 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:ThreadStackSize=$STACK_SIZE" 16605 fi 16606 16607 # Disable special log output when a debug build is used as Boot JDK... 16608 16609 # Test if -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput is a valid argument to $JAVA (often is $JAVA passed as $JAVA) 16610 # If so, then append -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput to boot_jdk_jvmargs 16611 FOUND_WARN=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1 | grep -i warn` 16612 FOUND_VERSION=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1 | grep " version \""` 16613 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 16614 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" 16615 fi 16616 16617 fi 16618 16619 BOOT_JDK_JVMARGS=$boot_jdk_jvmargs 16620 16621 16622 16623 ############################################################################### 16624 # 16625 # Configure the sources to use. We can add or override individual directories. 16626 # 16627 ############################################################################### 16628 16629 16630 16631 # Where are the sources. Any of these can be overridden 16632 # using --with-override-corba and the likes. 16633 LANGTOOLS_TOPDIR="$SRC_ROOT/langtools" 16634 CORBA_TOPDIR="$SRC_ROOT/corba" 16635 JAXP_TOPDIR="$SRC_ROOT/jaxp" 16636 JAXWS_TOPDIR="$SRC_ROOT/jaxws" 16637 HOTSPOT_TOPDIR="$SRC_ROOT/hotspot" 16638 NASHORN_TOPDIR="$SRC_ROOT/nashorn" 16639 JDK_TOPDIR="$SRC_ROOT/jdk" 16640 16641 16642 16643 16644 16645 16646 16647 16648 16649 16650 ############################################################################### 16651 # 16652 # Pickup additional source for a component from outside of the source root 16653 # or override source for a component. 16654 # 16655 16656 # Check whether --with-add-source-root was given. 16657 if test "${with_add_source_root+set}" = set; then : 16658 withval=$with_add_source_root; 16659 fi 16660 16661 16662 16663 # Check whether --with-override-source-root was given. 16664 if test "${with_override_source_root+set}" = set; then : 16665 withval=$with_override_source_root; 16666 fi 16667 16668 16669 16670 # Check whether --with-adds-and-overrides was given. 16671 if test "${with_adds_and_overrides+set}" = set; then : 16672 withval=$with_adds_and_overrides; 16673 fi 16674 16675 16676 if test "x$with_adds_and_overrides" != x; then 16677 with_add_source_root="$with_adds_and_overrides/adds" 16678 with_override_source_root="$with_adds_and_overrides/overrides" 16679 fi 16680 16681 if test "x$with_add_source_root" != x; then 16682 if ! test -d $with_add_source_root; then 16683 as_fn_error $? "Trying to use a non-existant add-source-root $with_add_source_root" "$LINENO" 5 16684 fi 16685 CURDIR="$PWD" 16686 cd "$with_add_source_root" 16687 ADD_SRC_ROOT="`pwd`" 16688 cd "$CURDIR" 16689 # Verify that the addon source root does not have any root makefiles. 16690 # If it does, then it is usually an error, prevent this. 16691 if test -f $with_add_source_root/langtools/makefiles/Makefile || \ 16692 test -f $with_add_source_root/langtools/make/Makefile; then 16693 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 16694 fi 16695 if test -f $with_add_source_root/corba/makefiles/Makefile || \ 16696 test -f $with_add_source_root/corba/make/Makefile; then 16697 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 16698 fi 16699 if test -f $with_add_source_root/jaxp/makefiles/Makefile || \ 16700 test -f $with_add_source_root/jaxp/make/Makefile; then 16701 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 16702 fi 16703 if test -f $with_add_source_root/jaxws/makefiles/Makefile || \ 16704 test -f $with_add_source_root/jaxws/make/Makefile; then 16705 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 16706 fi 16707 if test -f $with_add_source_root/hotspot/makefiles/Makefile || \ 16708 test -f $with_add_source_root/hotspot/make/Makefile; then 16709 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 16710 fi 16711 if test -f $with_add_source_root/jdk/makefiles/Makefile || \ 16712 test -f $with_add_source_root/jdk/make/Makefile; then 16713 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 16714 fi 16715 fi 16716 16717 16718 if test "x$with_override_source_root" != x; then 16719 if ! test -d $with_override_source_root; then 16720 as_fn_error $? "Trying to use a non-existant override-source-root $with_override_source_root" "$LINENO" 5 16721 fi 16722 CURDIR="$PWD" 16723 cd "$with_override_source_root" 16724 OVERRIDE_SRC_ROOT="`pwd`" 16725 cd "$CURDIR" 16726 if test -f $with_override_source_root/langtools/makefiles/Makefile || \ 16727 test -f $with_override_source_root/langtools/make/Makefile; then 16728 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 16729 fi 16730 if test -f $with_override_source_root/corba/makefiles/Makefile || \ 16731 test -f $with_override_source_root/corba/make/Makefile; then 16732 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 16733 fi 16734 if test -f $with_override_source_root/jaxp/makefiles/Makefile || \ 16735 test -f $with_override_source_root/jaxp/make/Makefile; then 16736 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 16737 fi 16738 if test -f $with_override_source_root/jaxws/makefiles/Makefile || \ 16739 test -f $with_override_source_root/jaxws/make/Makefile; then 16740 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 16741 fi 16742 if test -f $with_override_source_root/hotspot/makefiles/Makefile || \ 16743 test -f $with_override_source_root/hotspot/make/Makefile; then 16744 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 16745 fi 16746 if test -f $with_override_source_root/jdk/makefiles/Makefile || \ 16747 test -f $with_override_source_root/jdk/make/Makefile; then 16748 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 16749 fi 16750 fi 16751 16752 16753 ############################################################################### 16754 # 16755 # Override a repo completely, this is used for example when you have 3 small 16756 # development sandboxes of the langtools sources and want to avoid having 3 full 16757 # OpenJDK sources checked out on disk. 16758 # 16759 # Assuming that the 3 langtools sandboxes are located here: 16760 # /home/fredrik/sandbox1/langtools 16761 # /home/fredrik/sandbox2/langtools 16762 # /home/fredrik/sandbox3/langtools 16763 # 16764 # From the source root you create build subdirs manually: 16765 # mkdir -p build1 build2 build3 16766 # in each build directory run: 16767 # (cd build1 && ../configure --with-override-langtools=/home/fredrik/sandbox1 && make) 16768 # (cd build2 && ../configure --with-override-langtools=/home/fredrik/sandbox2 && make) 16769 # (cd build3 && ../configure --with-override-langtools=/home/fredrik/sandbox3 && make) 16770 # 16771 16772 16773 # Check whether --with-override-langtools was given. 16774 if test "${with_override_langtools+set}" = set; then : 16775 withval=$with_override_langtools; 16776 fi 16777 16778 16779 16780 # Check whether --with-override-corba was given. 16781 if test "${with_override_corba+set}" = set; then : 16782 withval=$with_override_corba; 16783 fi 16784 16785 16786 16787 # Check whether --with-override-jaxp was given. 16788 if test "${with_override_jaxp+set}" = set; then : 16789 withval=$with_override_jaxp; 16790 fi 16791 16792 16793 16794 # Check whether --with-override-jaxws was given. 16795 if test "${with_override_jaxws+set}" = set; then : 16796 withval=$with_override_jaxws; 16797 fi 16798 16799 16800 16801 # Check whether --with-override-hotspot was given. 16802 if test "${with_override_hotspot+set}" = set; then : 16803 withval=$with_override_hotspot; 16804 fi 16805 16806 16807 16808 # Check whether --with-override-jdk was given. 16809 if test "${with_override_jdk+set}" = set; then : 16810 withval=$with_override_jdk; 16811 fi 16812 16813 16814 if test "x$with_override_langtools" != x; then 16815 CURDIR="$PWD" 16816 cd "$with_override_langtools" 16817 LANGTOOLS_TOPDIR="`pwd`" 16818 cd "$CURDIR" 16819 if ! test -f $LANGTOOLS_TOPDIR/makefiles/Makefile; then 16820 as_fn_error $? "You have to override langtools with a full langtools repo!" "$LINENO" 5 16821 fi 16822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if langtools should be overridden" >&5 16823 $as_echo_n "checking if langtools should be overridden... " >&6; } 16824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $LANGTOOLS_TOPDIR" >&5 16825 $as_echo "yes with $LANGTOOLS_TOPDIR" >&6; } 16826 fi 16827 if test "x$with_override_corba" != x; then 16828 CURDIR="$PWD" 16829 cd "$with_override_corba" 16830 CORBA_TOPDIR="`pwd`" 16831 cd "$CURDIR" 16832 if ! test -f $CORBA_TOPDIR/makefiles/Makefile; then 16833 as_fn_error $? "You have to override corba with a full corba repo!" "$LINENO" 5 16834 fi 16835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if corba should be overridden" >&5 16836 $as_echo_n "checking if corba should be overridden... " >&6; } 16837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $CORBA_TOPDIR" >&5 16838 $as_echo "yes with $CORBA_TOPDIR" >&6; } 16839 fi 16840 if test "x$with_override_jaxp" != x; then 16841 CURDIR="$PWD" 16842 cd "$with_override_jaxp" 16843 JAXP_TOPDIR="`pwd`" 16844 cd "$CURDIR" 16845 if ! test -f $JAXP_TOPDIR/makefiles/Makefile; then 16846 as_fn_error $? "You have to override jaxp with a full jaxp repo!" "$LINENO" 5 16847 fi 16848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxp should be overridden" >&5 16849 $as_echo_n "checking if jaxp should be overridden... " >&6; } 16850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXP_TOPDIR" >&5 16851 $as_echo "yes with $JAXP_TOPDIR" >&6; } 16852 fi 16853 if test "x$with_override_jaxws" != x; then 16854 CURDIR="$PWD" 16855 cd "$with_override_jaxws" 16856 JAXWS_TOPDIR="`pwd`" 16857 cd "$CURDIR" 16858 if ! test -f $JAXWS_TOPDIR/makefiles/Makefile; then 16859 as_fn_error $? "You have to override jaxws with a full jaxws repo!" "$LINENO" 5 16860 fi 16861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxws should be overridden" >&5 16862 $as_echo_n "checking if jaxws should be overridden... " >&6; } 16863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXWS_TOPDIR" >&5 16864 $as_echo "yes with $JAXWS_TOPDIR" >&6; } 16865 fi 16866 if test "x$with_override_hotspot" != x; then 16867 CURDIR="$PWD" 16868 cd "$with_override_hotspot" 16869 HOTSPOT_TOPDIR="`pwd`" 16870 cd "$CURDIR" 16871 if ! test -f $HOTSPOT_TOPDIR/make/Makefile && \ 16872 ! test -f $HOTSPOT_TOPDIR/makefiles/Makefile; then 16873 as_fn_error $? "You have to override hotspot with a full hotspot repo!" "$LINENO" 5 16874 fi 16875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be overridden" >&5 16876 $as_echo_n "checking if hotspot should be overridden... " >&6; } 16877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $HOTSPOT_TOPDIR" >&5 16878 $as_echo "yes with $HOTSPOT_TOPDIR" >&6; } 16879 fi 16880 if test "x$with_override_nashorn" != x; then 16881 CURDIR="$PWD" 16882 cd "$with_override_nashorn" 16883 NASHORN_TOPDIR="`pwd`" 16884 cd "$CURDIR" 16885 if ! test -f $NASHORN_TOPDIR/makefiles/BuildNashorn.gmk; then 16886 as_fn_error $? "You have to override nashorn with a full nashorn repo!" "$LINENO" 5 16887 fi 16888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nashorn should be overridden" >&5 16889 $as_echo_n "checking if nashorn should be overridden... " >&6; } 16890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $NASHORN_TOPDIR" >&5 16891 $as_echo "yes with $NASHORN_TOPDIR" >&6; } 16892 fi 16893 if test "x$with_override_jdk" != x; then 16894 CURDIR="$PWD" 16895 cd "$with_override_jdk" 16896 JDK_TOPDIR="`pwd`" 16897 cd "$CURDIR" 16898 if ! test -f $JDK_TOPDIR/makefiles/Makefile; then 16899 as_fn_error $? "You have to override JDK with a full JDK repo!" "$LINENO" 5 16900 fi 16901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if JDK should be overridden" >&5 16902 $as_echo_n "checking if JDK should be overridden... " >&6; } 16903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JDK_TOPDIR" >&5 16904 $as_echo "yes with $JDK_TOPDIR" >&6; } 16905 fi 16906 16907 16908 16909 BUILD_OUTPUT="$OUTPUT_ROOT" 16910 16911 16912 HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist" 16913 BUILD_HOTSPOT=true 16914 16915 16916 16917 # Check whether --with-import-hotspot was given. 16918 if test "${with_import_hotspot+set}" = set; then : 16919 withval=$with_import_hotspot; 16920 fi 16921 16922 if test "x$with_import_hotspot" != x; then 16923 CURDIR="$PWD" 16924 cd "$with_import_hotspot" 16925 HOTSPOT_DIST="`pwd`" 16926 cd "$CURDIR" 16927 if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then 16928 as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5 16929 fi 16930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5 16931 $as_echo_n "checking if hotspot should be imported... " >&6; } 16932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5 16933 $as_echo "yes from $HOTSPOT_DIST" >&6; } 16934 BUILD_HOTSPOT=false 16935 fi 16936 16937 JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk" 16938 16939 16940 ############################################################################### 16941 # 16942 # Setup the toolchain (compilers etc), i.e. the tools that need to be 16943 # cross-compilation aware. 16944 # 16945 ############################################################################### 16946 16947 16948 ############################################################################### 16949 # 16950 # Configure the development tool paths and potential sysroot. 16951 # 16952 ac_ext=cpp 16953 ac_cpp='$CXXCPP $CPPFLAGS' 16954 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 16955 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 16956 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 16957 16958 16959 # The option used to specify the target .o,.a or .so file. 16960 # When compiling, how to specify the to be created object file. 16961 CC_OUT_OPTION='-o$(SPACE)' 16962 # When linking, how to specify the to be created executable. 16963 EXE_OUT_OPTION='-o$(SPACE)' 16964 # When linking, how to specify the to be created dynamically linkable library. 16965 LD_OUT_OPTION='-o$(SPACE)' 16966 # When archiving, how to specify the to be create static archive for object files. 16967 AR_OUT_OPTION='rcs$(SPACE)' 16968 16969 16970 16971 16972 16973 # Locate the actual tools 16974 16975 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16976 16977 # Store path to cygwin link.exe to help excluding it when searching for 16978 # VS linker. This must be done before changing the PATH when looking for VS. 16979 # Extract the first word of "link", so it can be a program name with args. 16980 set dummy link; ac_word=$2 16981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 16982 $as_echo_n "checking for $ac_word... " >&6; } 16983 if ${ac_cv_path_CYGWIN_LINK+:} false; then : 16984 $as_echo_n "(cached) " >&6 16985 else 16986 case $CYGWIN_LINK in 16987 [\\/]* | ?:[\\/]*) 16988 ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path. 16989 ;; 16990 *) 16991 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 16992 for as_dir in $PATH 16993 do 16994 IFS=$as_save_IFS 16995 test -z "$as_dir" && as_dir=. 16996 for ac_exec_ext in '' $ac_executable_extensions; do 16997 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 16998 ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext" 16999 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17000 break 2 17001 fi 17002 done 17003 done 17004 IFS=$as_save_IFS 17005 17006 ;; 17007 esac 17008 fi 17009 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK 17010 if test -n "$CYGWIN_LINK"; then 17011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5 17012 $as_echo "$CYGWIN_LINK" >&6; } 17013 else 17014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17015 $as_echo "no" >&6; } 17016 fi 17017 17018 17019 if test "x$CYGWIN_LINK" != x; then 17020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5 17021 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; } 17022 "$CYGWIN_LINK" --version > /dev/null 17023 if test $? -eq 0 ; then 17024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 17025 $as_echo "yes" >&6; } 17026 else 17027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17028 $as_echo "no" >&6; } 17029 # This might be the VS linker. Don't exclude it later on. 17030 CYGWIN_LINK="" 17031 fi 17032 fi 17033 17034 # First-hand choice is to locate and run the vsvars bat file. 17035 17036 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 17037 VCVARSFILE="vc/bin/vcvars32.bat" 17038 else 17039 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 17040 fi 17041 17042 VS_ENV_CMD="" 17043 VS_ENV_ARGS="" 17044 if test "x$with_toolsdir" != x; then 17045 17046 if test "x$VS_ENV_CMD" = x; then 17047 VS100BASE="$with_toolsdir/../.." 17048 METHOD="--with-tools-dir" 17049 17050 windows_path="$VS100BASE" 17051 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17052 unix_path=`$CYGPATH -u "$windows_path"` 17053 VS100BASE="$unix_path" 17054 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17055 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17056 VS100BASE="$unix_path" 17057 fi 17058 17059 if test -d "$VS100BASE"; then 17060 if test -f "$VS100BASE/$VCVARSFILE"; then 17061 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 17062 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 17063 VS_ENV_CMD="$VS100BASE/$VCVARSFILE" 17064 else 17065 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 17066 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 17067 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 17068 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 17069 fi 17070 fi 17071 fi 17072 17073 fi 17074 17075 if test "x$with_toolsdir" != x && test "x$VS_ENV_CMD" = x; then 17076 # Having specified an argument which is incorrect will produce an instant failure; 17077 # we should not go on looking 17078 { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&5 17079 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&6;} 17080 { $as_echo "$as_me:${as_lineno-$LINENO}: Please point to the VC/bin directory within the Visual Studio installation" >&5 17081 $as_echo "$as_me: Please point to the VC/bin directory within the Visual Studio installation" >&6;} 17082 as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5 17083 fi 17084 17085 if test "x$ProgramW6432" != x; then 17086 17087 if test "x$VS_ENV_CMD" = x; then 17088 WIN_SDK_BASE="$ProgramW6432/Microsoft SDKs/Windows/v7.1/Bin" 17089 METHOD="well-known name" 17090 17091 windows_path="$WIN_SDK_BASE" 17092 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17093 unix_path=`$CYGPATH -u "$windows_path"` 17094 WIN_SDK_BASE="$unix_path" 17095 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17096 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17097 WIN_SDK_BASE="$unix_path" 17098 fi 17099 17100 if test -d "$WIN_SDK_BASE"; then 17101 # There have been cases of partial or broken SDK installations. A missing 17102 # lib dir is not going to work. 17103 if test ! -d "$WIN_SDK_BASE/../lib"; then 17104 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17105 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17106 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 17107 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 17108 elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then 17109 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17110 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17111 VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd" 17112 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 17113 VS_ENV_ARGS="/x86" 17114 else 17115 VS_ENV_ARGS="/x64" 17116 fi 17117 else 17118 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17119 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17120 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 17121 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 17122 fi 17123 fi 17124 fi 17125 17126 fi 17127 if test "x$PROGRAMW6432" != x; then 17128 17129 if test "x$VS_ENV_CMD" = x; then 17130 WIN_SDK_BASE="$PROGRAMW6432/Microsoft SDKs/Windows/v7.1/Bin" 17131 METHOD="well-known name" 17132 17133 windows_path="$WIN_SDK_BASE" 17134 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17135 unix_path=`$CYGPATH -u "$windows_path"` 17136 WIN_SDK_BASE="$unix_path" 17137 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17138 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17139 WIN_SDK_BASE="$unix_path" 17140 fi 17141 17142 if test -d "$WIN_SDK_BASE"; then 17143 # There have been cases of partial or broken SDK installations. A missing 17144 # lib dir is not going to work. 17145 if test ! -d "$WIN_SDK_BASE/../lib"; then 17146 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17147 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17148 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 17149 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 17150 elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then 17151 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17152 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17153 VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd" 17154 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 17155 VS_ENV_ARGS="/x86" 17156 else 17157 VS_ENV_ARGS="/x64" 17158 fi 17159 else 17160 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17161 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17162 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 17163 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 17164 fi 17165 fi 17166 fi 17167 17168 fi 17169 if test "x$PROGRAMFILES" != x; then 17170 17171 if test "x$VS_ENV_CMD" = x; then 17172 WIN_SDK_BASE="$PROGRAMFILES/Microsoft SDKs/Windows/v7.1/Bin" 17173 METHOD="well-known name" 17174 17175 windows_path="$WIN_SDK_BASE" 17176 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17177 unix_path=`$CYGPATH -u "$windows_path"` 17178 WIN_SDK_BASE="$unix_path" 17179 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17180 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17181 WIN_SDK_BASE="$unix_path" 17182 fi 17183 17184 if test -d "$WIN_SDK_BASE"; then 17185 # There have been cases of partial or broken SDK installations. A missing 17186 # lib dir is not going to work. 17187 if test ! -d "$WIN_SDK_BASE/../lib"; then 17188 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17189 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17190 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 17191 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 17192 elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then 17193 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17194 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17195 VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd" 17196 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 17197 VS_ENV_ARGS="/x86" 17198 else 17199 VS_ENV_ARGS="/x64" 17200 fi 17201 else 17202 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17203 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17204 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 17205 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 17206 fi 17207 fi 17208 fi 17209 17210 fi 17211 17212 if test "x$VS_ENV_CMD" = x; then 17213 WIN_SDK_BASE="C:/Program Files/Microsoft SDKs/Windows/v7.1/Bin" 17214 METHOD="well-known name" 17215 17216 windows_path="$WIN_SDK_BASE" 17217 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17218 unix_path=`$CYGPATH -u "$windows_path"` 17219 WIN_SDK_BASE="$unix_path" 17220 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17221 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17222 WIN_SDK_BASE="$unix_path" 17223 fi 17224 17225 if test -d "$WIN_SDK_BASE"; then 17226 # There have been cases of partial or broken SDK installations. A missing 17227 # lib dir is not going to work. 17228 if test ! -d "$WIN_SDK_BASE/../lib"; then 17229 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17230 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17231 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 17232 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 17233 elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then 17234 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17235 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17236 VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd" 17237 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 17238 VS_ENV_ARGS="/x86" 17239 else 17240 VS_ENV_ARGS="/x64" 17241 fi 17242 else 17243 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17244 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17245 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 17246 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 17247 fi 17248 fi 17249 fi 17250 17251 17252 if test "x$VS_ENV_CMD" = x; then 17253 WIN_SDK_BASE="C:/Program Files (x86)/Microsoft SDKs/Windows/v7.1/Bin" 17254 METHOD="well-known name" 17255 17256 windows_path="$WIN_SDK_BASE" 17257 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17258 unix_path=`$CYGPATH -u "$windows_path"` 17259 WIN_SDK_BASE="$unix_path" 17260 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17261 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17262 WIN_SDK_BASE="$unix_path" 17263 fi 17264 17265 if test -d "$WIN_SDK_BASE"; then 17266 # There have been cases of partial or broken SDK installations. A missing 17267 # lib dir is not going to work. 17268 if test ! -d "$WIN_SDK_BASE/../lib"; then 17269 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17270 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17271 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 17272 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 17273 elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then 17274 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17275 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17276 VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd" 17277 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 17278 VS_ENV_ARGS="/x86" 17279 else 17280 VS_ENV_ARGS="/x64" 17281 fi 17282 else 17283 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 17284 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 17285 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 17286 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 17287 fi 17288 fi 17289 fi 17290 17291 17292 if test "x$VS100COMNTOOLS" != x; then 17293 17294 if test "x$VS_ENV_CMD" = x; then 17295 VS100BASE="$VS100COMNTOOLS/../.." 17296 METHOD="VS100COMNTOOLS variable" 17297 17298 windows_path="$VS100BASE" 17299 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17300 unix_path=`$CYGPATH -u "$windows_path"` 17301 VS100BASE="$unix_path" 17302 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17303 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17304 VS100BASE="$unix_path" 17305 fi 17306 17307 if test -d "$VS100BASE"; then 17308 if test -f "$VS100BASE/$VCVARSFILE"; then 17309 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 17310 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 17311 VS_ENV_CMD="$VS100BASE/$VCVARSFILE" 17312 else 17313 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 17314 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 17315 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 17316 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 17317 fi 17318 fi 17319 fi 17320 17321 fi 17322 if test "x$PROGRAMFILES" != x; then 17323 17324 if test "x$VS_ENV_CMD" = x; then 17325 VS100BASE="$PROGRAMFILES/Microsoft Visual Studio 10.0" 17326 METHOD="well-known name" 17327 17328 windows_path="$VS100BASE" 17329 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17330 unix_path=`$CYGPATH -u "$windows_path"` 17331 VS100BASE="$unix_path" 17332 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17333 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17334 VS100BASE="$unix_path" 17335 fi 17336 17337 if test -d "$VS100BASE"; then 17338 if test -f "$VS100BASE/$VCVARSFILE"; then 17339 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 17340 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 17341 VS_ENV_CMD="$VS100BASE/$VCVARSFILE" 17342 else 17343 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 17344 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 17345 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 17346 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 17347 fi 17348 fi 17349 fi 17350 17351 fi 17352 17353 if test "x$VS_ENV_CMD" = x; then 17354 VS100BASE="C:/Program Files/Microsoft Visual Studio 10.0" 17355 METHOD="well-known name" 17356 17357 windows_path="$VS100BASE" 17358 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17359 unix_path=`$CYGPATH -u "$windows_path"` 17360 VS100BASE="$unix_path" 17361 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17362 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17363 VS100BASE="$unix_path" 17364 fi 17365 17366 if test -d "$VS100BASE"; then 17367 if test -f "$VS100BASE/$VCVARSFILE"; then 17368 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 17369 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 17370 VS_ENV_CMD="$VS100BASE/$VCVARSFILE" 17371 else 17372 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 17373 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 17374 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 17375 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 17376 fi 17377 fi 17378 fi 17379 17380 17381 if test "x$VS_ENV_CMD" = x; then 17382 VS100BASE="C:/Program Files (x86)/Microsoft Visual Studio 10.0" 17383 METHOD="well-known name" 17384 17385 windows_path="$VS100BASE" 17386 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17387 unix_path=`$CYGPATH -u "$windows_path"` 17388 VS100BASE="$unix_path" 17389 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17390 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17391 VS100BASE="$unix_path" 17392 fi 17393 17394 if test -d "$VS100BASE"; then 17395 if test -f "$VS100BASE/$VCVARSFILE"; then 17396 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 17397 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 17398 VS_ENV_CMD="$VS100BASE/$VCVARSFILE" 17399 else 17400 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 17401 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 17402 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 17403 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 17404 fi 17405 fi 17406 fi 17407 17408 17409 if test "x$VS_ENV_CMD" != x; then 17410 # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file. 17411 17412 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17413 17414 # First separate the path from the arguments. This will split at the first 17415 # space. 17416 complete="$VS_ENV_CMD" 17417 path="${complete%% *}" 17418 tmp="$complete EOL" 17419 arguments="${tmp#* }" 17420 17421 # Input might be given as Windows format, start by converting to 17422 # unix format. 17423 new_path=`$CYGPATH -u "$path"` 17424 17425 # Now try to locate executable using which 17426 new_path=`$WHICH "$new_path" 2> /dev/null` 17427 # bat and cmd files are not always considered executable in cygwin causing which 17428 # to not find them 17429 if test "x$new_path" = x \ 17430 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17431 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17432 new_path=`$CYGPATH -u "$path"` 17433 fi 17434 if test "x$new_path" = x; then 17435 # Oops. Which didn't find the executable. 17436 # The splitting of arguments from the executable at a space might have been incorrect, 17437 # since paths with space are more likely in Windows. Give it another try with the whole 17438 # argument. 17439 path="$complete" 17440 arguments="EOL" 17441 new_path=`$CYGPATH -u "$path"` 17442 new_path=`$WHICH "$new_path" 2> /dev/null` 17443 # bat and cmd files are not always considered executable in cygwin causing which 17444 # to not find them 17445 if test "x$new_path" = x \ 17446 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17447 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17448 new_path=`$CYGPATH -u "$path"` 17449 fi 17450 if test "x$new_path" = x; then 17451 # It's still not found. Now this is an unrecoverable error. 17452 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 17453 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 17454 has_space=`$ECHO "$complete" | $GREP " "` 17455 if test "x$has_space" != x; then 17456 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17457 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17458 fi 17459 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 17460 fi 17461 fi 17462 17463 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17464 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17465 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17466 # "foo.exe" is OK but "foo" is an error. 17467 # 17468 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17469 # It is also a way to make sure we got the proper file name for the real test later on. 17470 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17471 if test "x$test_shortpath" = x; then 17472 # Short path failed, file does not exist as specified. 17473 # Try adding .exe or .cmd 17474 if test -f "${new_path}.exe"; then 17475 input_to_shortpath="${new_path}.exe" 17476 elif test -f "${new_path}.cmd"; then 17477 input_to_shortpath="${new_path}.cmd" 17478 else 17479 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5 17480 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;} 17481 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 17482 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 17483 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 17484 fi 17485 else 17486 input_to_shortpath="$new_path" 17487 fi 17488 17489 # Call helper function which possibly converts this using DOS-style short mode. 17490 # If so, the updated path is stored in $new_path. 17491 new_path="$input_to_shortpath" 17492 17493 input_path="$input_to_shortpath" 17494 # Check if we need to convert this using DOS-style short mode. If the path 17495 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17496 # take no chances and rewrite it. 17497 # Note: m4 eats our [], so we need to use [ and ] instead. 17498 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17499 if test "x$has_forbidden_chars" != x; then 17500 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17501 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17502 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17503 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17504 # Going to short mode and back again did indeed matter. Since short mode is 17505 # case insensitive, let's make it lowercase to improve readability. 17506 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17507 # Now convert it back to Unix-stile (cygpath) 17508 input_path=`$CYGPATH -u "$shortmode_path"` 17509 new_path="$input_path" 17510 fi 17511 fi 17512 17513 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17514 if test "x$test_cygdrive_prefix" = x; then 17515 # As a simple fix, exclude /usr/bin since it's not a real path. 17516 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 17517 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17518 # a path prefixed by /cygdrive for fixpath to work. 17519 new_path="$CYGWIN_ROOT_PATH$input_path" 17520 fi 17521 fi 17522 17523 # remove trailing .exe if any 17524 new_path="${new_path/%.exe/}" 17525 17526 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17527 17528 # First separate the path from the arguments. This will split at the first 17529 # space. 17530 complete="$VS_ENV_CMD" 17531 path="${complete%% *}" 17532 tmp="$complete EOL" 17533 arguments="${tmp#* }" 17534 17535 # Input might be given as Windows format, start by converting to 17536 # unix format. 17537 new_path="$path" 17538 17539 windows_path="$new_path" 17540 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17541 unix_path=`$CYGPATH -u "$windows_path"` 17542 new_path="$unix_path" 17543 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17544 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17545 new_path="$unix_path" 17546 fi 17547 17548 17549 # Now try to locate executable using which 17550 new_path=`$WHICH "$new_path" 2> /dev/null` 17551 17552 if test "x$new_path" = x; then 17553 # Oops. Which didn't find the executable. 17554 # The splitting of arguments from the executable at a space might have been incorrect, 17555 # since paths with space are more likely in Windows. Give it another try with the whole 17556 # argument. 17557 path="$complete" 17558 arguments="EOL" 17559 new_path="$path" 17560 17561 windows_path="$new_path" 17562 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17563 unix_path=`$CYGPATH -u "$windows_path"` 17564 new_path="$unix_path" 17565 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17566 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17567 new_path="$unix_path" 17568 fi 17569 17570 17571 new_path=`$WHICH "$new_path" 2> /dev/null` 17572 17573 if test "x$new_path" = x; then 17574 # It's still not found. Now this is an unrecoverable error. 17575 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 17576 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 17577 has_space=`$ECHO "$complete" | $GREP " "` 17578 if test "x$has_space" != x; then 17579 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17580 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17581 fi 17582 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 17583 fi 17584 fi 17585 17586 # Now new_path has a complete unix path to the binary 17587 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 17588 # Keep paths in /bin as-is, but remove trailing .exe if any 17589 new_path="${new_path/%.exe/}" 17590 # Do not save /bin paths to all_fixpath_prefixes! 17591 else 17592 # Not in mixed or Windows style, start by that. 17593 new_path=`cmd //c echo $new_path` 17594 17595 input_path="$new_path" 17596 # Check if we need to convert this using DOS-style short mode. If the path 17597 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17598 # take no chances and rewrite it. 17599 # Note: m4 eats our [], so we need to use [ and ] instead. 17600 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17601 if test "x$has_forbidden_chars" != x; then 17602 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17603 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17604 fi 17605 17606 # Output is in $new_path 17607 17608 windows_path="$new_path" 17609 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17610 unix_path=`$CYGPATH -u "$windows_path"` 17611 new_path="$unix_path" 17612 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17613 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17614 new_path="$unix_path" 17615 fi 17616 17617 # remove trailing .exe if any 17618 new_path="${new_path/%.exe/}" 17619 17620 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17621 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17622 fi 17623 17624 else 17625 # We're on a posix platform. Hooray! :) 17626 # First separate the path from the arguments. This will split at the first 17627 # space. 17628 complete="$VS_ENV_CMD" 17629 path="${complete%% *}" 17630 tmp="$complete EOL" 17631 arguments="${tmp#* }" 17632 17633 # Cannot rely on the command "which" here since it doesn't always work. 17634 is_absolute_path=`$ECHO "$path" | $GREP ^/` 17635 if test -z "$is_absolute_path"; then 17636 # Path to executable is not absolute. Find it. 17637 IFS_save="$IFS" 17638 IFS=: 17639 for p in $PATH; do 17640 if test -f "$p/$path" && test -x "$p/$path"; then 17641 new_path="$p/$path" 17642 break 17643 fi 17644 done 17645 IFS="$IFS_save" 17646 else 17647 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving VS_ENV_CMD (as $path) failed, using $path directly." >&5 17648 $as_echo "$as_me: Resolving VS_ENV_CMD (as $path) failed, using $path directly." >&6;} 17649 new_path="$path" 17650 fi 17651 17652 if test "x$new_path" = x; then 17653 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 17654 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 17655 has_space=`$ECHO "$complete" | $GREP " "` 17656 if test "x$has_space" != x; then 17657 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 17658 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 17659 fi 17660 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 17661 fi 17662 fi 17663 17664 # Now join together the path and the arguments once again 17665 if test "x$arguments" != xEOL; then 17666 new_complete="$new_path ${arguments% *}" 17667 else 17668 new_complete="$new_path" 17669 fi 17670 17671 if test "x$complete" != "x$new_complete"; then 17672 VS_ENV_CMD="$new_complete" 17673 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5 17674 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;} 17675 fi 17676 17677 17678 # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat 17679 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5 17680 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;} 17681 cd $OUTPUT_ROOT 17682 # FIXME: The code betweeen ---- was inlined from a separate script and is not properly adapted 17683 # to autoconf standards. 17684 17685 #---- 17686 17687 # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment) 17688 # but calculate the difference in Cygwin environment before/after running it and then 17689 # apply the diff. 17690 17691 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 17692 _vs10varsall=`cygpath -a -m -s "$VS_ENV_CMD"` 17693 _dosvs10varsall=`cygpath -a -w -s $_vs10varsall` 17694 _dosbash=`cygpath -a -w -s \`which bash\`.*` 17695 else 17696 _dosvs10varsall=`cmd //c echo $VS_ENV_CMD` 17697 _dosbash=`cmd //c echo \`which bash\`` 17698 fi 17699 17700 # generate the set of exported vars before/after the vs10 setup 17701 $ECHO "@echo off" > localdevenvtmp.bat 17702 $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export0" >> localdevenvtmp.bat 17703 $ECHO "call $_dosvs10varsall $VS_ENV_ARGS" >> localdevenvtmp.bat 17704 $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export1" >> localdevenvtmp.bat 17705 17706 # Now execute the newly created bat file. 17707 # The | cat is to stop SetEnv.Cmd to mess with system colors on msys 17708 cmd /c localdevenvtmp.bat | cat 17709 17710 # apply the diff (less some non-vs10 vars named by "!") 17711 $SORT localdevenvtmp.export0 | $GREP -v "!" > localdevenvtmp.export0.sort 17712 $SORT localdevenvtmp.export1 | $GREP -v "!" > localdevenvtmp.export1.sort 17713 $COMM -1 -3 localdevenvtmp.export0.sort localdevenvtmp.export1.sort > localdevenv.sh 17714 17715 # cleanup 17716 $RM localdevenvtmp* 17717 #---- 17718 cd $CURDIR 17719 if test ! -s $OUTPUT_ROOT/localdevenv.sh; then 17720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17721 $as_echo "no" >&6; } 17722 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5 17723 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;} 17724 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 17725 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 17726 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 17727 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 17728 as_fn_error $? "Cannot continue" "$LINENO" 5 17729 fi 17730 17731 # Now set all paths and other env variables. This will allow the rest of 17732 # the configure script to find and run the compiler in the proper way. 17733 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5 17734 $as_echo "$as_me: Setting extracted environment variables" >&6;} 17735 . $OUTPUT_ROOT/localdevenv.sh 17736 else 17737 # We did not find a vsvars bat file, let's hope we are run from a VS command prompt. 17738 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5 17739 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;} 17740 fi 17741 17742 # At this point, we should have corrent variables in the environment, or we can't continue. 17743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5 17744 $as_echo_n "checking for Visual Studio variables... " >&6; } 17745 17746 if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x || test "x$WINDOWSSDKDIR" != x; then 17747 if test "x$INCLUDE" = x || test "x$LIB" = x; then 17748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5 17749 $as_echo "present but broken" >&6; } 17750 as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5 17751 else 17752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 17753 $as_echo "ok" >&6; } 17754 # Remove any trailing \ from INCLUDE and LIB to avoid trouble in spec.gmk. 17755 VS_INCLUDE=`$ECHO "$INCLUDE" | $SED 's/\\\\$//'` 17756 VS_LIB=`$ECHO "$LIB" | $SED 's/\\\\$//'` 17757 VS_PATH="$PATH" 17758 17759 17760 17761 fi 17762 else 17763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 17764 $as_echo "not found" >&6; } 17765 17766 if test "x$VS_ENV_CMD" = x; then 17767 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5 17768 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;} 17769 { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5 17770 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;} 17771 else 17772 { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5 17773 $as_echo "$as_me: Running the extraction script failed." >&6;} 17774 fi 17775 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 17776 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 17777 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 17778 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 17779 as_fn_error $? "Cannot continue" "$LINENO" 5 17780 fi 17781 17782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5 17783 $as_echo_n "checking for msvcr100.dll... " >&6; } 17784 17785 # Check whether --with-msvcr-dll was given. 17786 if test "${with_msvcr_dll+set}" = set; then : 17787 withval=$with_msvcr_dll; 17788 fi 17789 17790 if test "x$with_msvcr_dll" != x; then 17791 MSVCR_DLL="$with_msvcr_dll" 17792 else 17793 if test "x$VCINSTALLDIR" != x; then 17794 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 17795 MSVCR_DLL=`find "$VCINSTALLDIR" -name msvcr100.dll | grep x64 | head --lines 1` 17796 else 17797 MSVCR_DLL=`find "$VCINSTALLDIR" -name msvcr100.dll | grep x86 | grep -v ia64 | grep -v x64 | head --lines 1` 17798 if test "x$MSVCR_DLL" = x; then 17799 MSVCR_DLL=`find "$VCINSTALLDIR" -name msvcr100.dll | head --lines 1` 17800 fi 17801 fi 17802 if test "x$MSVCR_DLL" != x; then 17803 { $as_echo "$as_me:${as_lineno-$LINENO}: msvcr100.dll found in VCINSTALLDIR: $VCINSTALLDIR" >&5 17804 $as_echo "$as_me: msvcr100.dll found in VCINSTALLDIR: $VCINSTALLDIR" >&6;} 17805 else 17806 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: msvcr100.dll not found in VCINSTALLDIR: $VCINSTALLDIR" >&5 17807 $as_echo "$as_me: Warning: msvcr100.dll not found in VCINSTALLDIR: $VCINSTALLDIR" >&6;} 17808 fi 17809 fi 17810 if test "x$MSVCR_DLL" = x; then 17811 if test -f "$SYSTEMROOT/system32/msvcr100.dll"; then 17812 { $as_echo "$as_me:${as_lineno-$LINENO}: msvcr100.dll found in $SYSTEMROOT/system32" >&5 17813 $as_echo "$as_me: msvcr100.dll found in $SYSTEMROOT/system32" >&6;} 17814 MSVCR_DLL="$SYSTEMROOT/system32/msvcr100.dll" 17815 fi 17816 fi 17817 fi 17818 if test "x$MSVCR_DLL" = x; then 17819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17820 $as_echo "no" >&6; } 17821 as_fn_error $? "Could not find msvcr100.dll !" "$LINENO" 5 17822 fi 17823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5 17824 $as_echo "$MSVCR_DLL" >&6; } 17825 17826 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17827 17828 # Input might be given as Windows format, start by converting to 17829 # unix format. 17830 path="$MSVCR_DLL" 17831 new_path=`$CYGPATH -u "$path"` 17832 17833 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17834 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17835 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17836 # "foo.exe" is OK but "foo" is an error. 17837 # 17838 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17839 # It is also a way to make sure we got the proper file name for the real test later on. 17840 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17841 if test "x$test_shortpath" = x; then 17842 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5 17843 $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;} 17844 as_fn_error $? "Cannot locate the the path of MSVCR_DLL" "$LINENO" 5 17845 fi 17846 17847 # Call helper function which possibly converts this using DOS-style short mode. 17848 # If so, the updated path is stored in $new_path. 17849 17850 input_path="$new_path" 17851 # Check if we need to convert this using DOS-style short mode. If the path 17852 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17853 # take no chances and rewrite it. 17854 # Note: m4 eats our [], so we need to use [ and ] instead. 17855 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17856 if test "x$has_forbidden_chars" != x; then 17857 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17858 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17859 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17860 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17861 # Going to short mode and back again did indeed matter. Since short mode is 17862 # case insensitive, let's make it lowercase to improve readability. 17863 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17864 # Now convert it back to Unix-stile (cygpath) 17865 input_path=`$CYGPATH -u "$shortmode_path"` 17866 new_path="$input_path" 17867 fi 17868 fi 17869 17870 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17871 if test "x$test_cygdrive_prefix" = x; then 17872 # As a simple fix, exclude /usr/bin since it's not a real path. 17873 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17874 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17875 # a path prefixed by /cygdrive for fixpath to work. 17876 new_path="$CYGWIN_ROOT_PATH$input_path" 17877 fi 17878 fi 17879 17880 17881 if test "x$path" != "x$new_path"; then 17882 MSVCR_DLL="$new_path" 17883 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5 17884 $as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;} 17885 fi 17886 17887 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17888 17889 path="$MSVCR_DLL" 17890 has_colon=`$ECHO $path | $GREP ^.:` 17891 new_path="$path" 17892 if test "x$has_colon" = x; then 17893 # Not in mixed or Windows style, start by that. 17894 new_path=`cmd //c echo $path` 17895 fi 17896 17897 17898 input_path="$new_path" 17899 # Check if we need to convert this using DOS-style short mode. If the path 17900 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17901 # take no chances and rewrite it. 17902 # Note: m4 eats our [], so we need to use [ and ] instead. 17903 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17904 if test "x$has_forbidden_chars" != x; then 17905 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17906 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17907 fi 17908 17909 17910 windows_path="$new_path" 17911 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17912 unix_path=`$CYGPATH -u "$windows_path"` 17913 new_path="$unix_path" 17914 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17915 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17916 new_path="$unix_path" 17917 fi 17918 17919 if test "x$path" != "x$new_path"; then 17920 MSVCR_DLL="$new_path" 17921 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5 17922 $as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;} 17923 fi 17924 17925 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17926 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17927 17928 else 17929 # We're on a posix platform. Hooray! :) 17930 path="$MSVCR_DLL" 17931 17932 if test ! -f "$path" && test ! -d "$path"; then 17933 as_fn_error $? "The path of MSVCR_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 17934 fi 17935 17936 has_space=`$ECHO "$path" | $GREP " "` 17937 if test "x$has_space" != x; then 17938 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5 17939 $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;} 17940 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17941 fi 17942 fi 17943 17944 17945 17946 17947 # Check whether --with-dxsdk was given. 17948 if test "${with_dxsdk+set}" = set; then : 17949 withval=$with_dxsdk; 17950 fi 17951 17952 17953 # Check whether --with-dxsdk-lib was given. 17954 if test "${with_dxsdk_lib+set}" = set; then : 17955 withval=$with_dxsdk_lib; 17956 fi 17957 17958 17959 # Check whether --with-dxsdk-include was given. 17960 if test "${with_dxsdk_include+set}" = set; then : 17961 withval=$with_dxsdk_include; 17962 fi 17963 17964 17965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DirectX SDK" >&5 17966 $as_echo_n "checking for DirectX SDK... " >&6; } 17967 17968 if test "x$with_dxsdk" != x; then 17969 dxsdk_path="$with_dxsdk" 17970 elif test "x$DXSDK_DIR" != x; then 17971 dxsdk_path="$DXSDK_DIR" 17972 elif test -d "C:/DXSDK"; then 17973 dxsdk_path="C:/DXSDK" 17974 else 17975 as_fn_error $? "Could not find the DirectX SDK" "$LINENO" 5 17976 fi 17977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dxsdk_path" >&5 17978 $as_echo "$dxsdk_path" >&6; } 17979 17980 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17981 17982 # Input might be given as Windows format, start by converting to 17983 # unix format. 17984 path="$dxsdk_path" 17985 new_path=`$CYGPATH -u "$path"` 17986 17987 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17988 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17989 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17990 # "foo.exe" is OK but "foo" is an error. 17991 # 17992 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17993 # It is also a way to make sure we got the proper file name for the real test later on. 17994 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17995 if test "x$test_shortpath" = x; then 17996 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&5 17997 $as_echo "$as_me: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&6;} 17998 as_fn_error $? "Cannot locate the the path of dxsdk_path" "$LINENO" 5 17999 fi 18000 18001 # Call helper function which possibly converts this using DOS-style short mode. 18002 # If so, the updated path is stored in $new_path. 18003 18004 input_path="$new_path" 18005 # Check if we need to convert this using DOS-style short mode. If the path 18006 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18007 # take no chances and rewrite it. 18008 # Note: m4 eats our [], so we need to use [ and ] instead. 18009 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18010 if test "x$has_forbidden_chars" != x; then 18011 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18012 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18013 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18014 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18015 # Going to short mode and back again did indeed matter. Since short mode is 18016 # case insensitive, let's make it lowercase to improve readability. 18017 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18018 # Now convert it back to Unix-stile (cygpath) 18019 input_path=`$CYGPATH -u "$shortmode_path"` 18020 new_path="$input_path" 18021 fi 18022 fi 18023 18024 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18025 if test "x$test_cygdrive_prefix" = x; then 18026 # As a simple fix, exclude /usr/bin since it's not a real path. 18027 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 18028 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18029 # a path prefixed by /cygdrive for fixpath to work. 18030 new_path="$CYGWIN_ROOT_PATH$input_path" 18031 fi 18032 fi 18033 18034 18035 if test "x$path" != "x$new_path"; then 18036 dxsdk_path="$new_path" 18037 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting dxsdk_path to \"$new_path\"" >&5 18038 $as_echo "$as_me: Rewriting dxsdk_path to \"$new_path\"" >&6;} 18039 fi 18040 18041 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18042 18043 path="$dxsdk_path" 18044 has_colon=`$ECHO $path | $GREP ^.:` 18045 new_path="$path" 18046 if test "x$has_colon" = x; then 18047 # Not in mixed or Windows style, start by that. 18048 new_path=`cmd //c echo $path` 18049 fi 18050 18051 18052 input_path="$new_path" 18053 # Check if we need to convert this using DOS-style short mode. If the path 18054 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18055 # take no chances and rewrite it. 18056 # Note: m4 eats our [], so we need to use [ and ] instead. 18057 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18058 if test "x$has_forbidden_chars" != x; then 18059 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18060 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18061 fi 18062 18063 18064 windows_path="$new_path" 18065 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18066 unix_path=`$CYGPATH -u "$windows_path"` 18067 new_path="$unix_path" 18068 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18069 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18070 new_path="$unix_path" 18071 fi 18072 18073 if test "x$path" != "x$new_path"; then 18074 dxsdk_path="$new_path" 18075 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting dxsdk_path to \"$new_path\"" >&5 18076 $as_echo "$as_me: Rewriting dxsdk_path to \"$new_path\"" >&6;} 18077 fi 18078 18079 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18080 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18081 18082 else 18083 # We're on a posix platform. Hooray! :) 18084 path="$dxsdk_path" 18085 18086 if test ! -f "$path" && test ! -d "$path"; then 18087 as_fn_error $? "The path of dxsdk_path, which resolves as \"$path\", is not found." "$LINENO" 5 18088 fi 18089 18090 has_space=`$ECHO "$path" | $GREP " "` 18091 if test "x$has_space" != x; then 18092 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&5 18093 $as_echo "$as_me: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&6;} 18094 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 18095 fi 18096 fi 18097 18098 18099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DirectX SDK lib dir" >&5 18100 $as_echo_n "checking for DirectX SDK lib dir... " >&6; } 18101 if test "x$with_dxsdk_lib" != x; then 18102 DXSDK_LIB_PATH="$with_dxsdk_lib" 18103 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 18104 DXSDK_LIB_PATH="$dxsdk_path/Lib/x64" 18105 else 18106 DXSDK_LIB_PATH="$dxsdk_path/Lib" 18107 fi 18108 # dsound.lib is linked to in jsoundds 18109 if test ! -f "$DXSDK_LIB_PATH/dsound.lib"; then 18110 as_fn_error $? "Invalid DirectX SDK lib dir" "$LINENO" 5 18111 fi 18112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DXSDK_LIB_PATH" >&5 18113 $as_echo "$DXSDK_LIB_PATH" >&6; } 18114 18115 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18116 18117 # Input might be given as Windows format, start by converting to 18118 # unix format. 18119 path="$DXSDK_LIB_PATH" 18120 new_path=`$CYGPATH -u "$path"` 18121 18122 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18123 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18124 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18125 # "foo.exe" is OK but "foo" is an error. 18126 # 18127 # This test is therefore slightly more accurate than "test -f" to check for file precense. 18128 # It is also a way to make sure we got the proper file name for the real test later on. 18129 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18130 if test "x$test_shortpath" = x; then 18131 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&5 18132 $as_echo "$as_me: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 18133 as_fn_error $? "Cannot locate the the path of DXSDK_LIB_PATH" "$LINENO" 5 18134 fi 18135 18136 # Call helper function which possibly converts this using DOS-style short mode. 18137 # If so, the updated path is stored in $new_path. 18138 18139 input_path="$new_path" 18140 # Check if we need to convert this using DOS-style short mode. If the path 18141 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18142 # take no chances and rewrite it. 18143 # Note: m4 eats our [], so we need to use [ and ] instead. 18144 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18145 if test "x$has_forbidden_chars" != x; then 18146 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18147 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18148 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18149 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18150 # Going to short mode and back again did indeed matter. Since short mode is 18151 # case insensitive, let's make it lowercase to improve readability. 18152 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18153 # Now convert it back to Unix-stile (cygpath) 18154 input_path=`$CYGPATH -u "$shortmode_path"` 18155 new_path="$input_path" 18156 fi 18157 fi 18158 18159 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18160 if test "x$test_cygdrive_prefix" = x; then 18161 # As a simple fix, exclude /usr/bin since it's not a real path. 18162 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 18163 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18164 # a path prefixed by /cygdrive for fixpath to work. 18165 new_path="$CYGWIN_ROOT_PATH$input_path" 18166 fi 18167 fi 18168 18169 18170 if test "x$path" != "x$new_path"; then 18171 DXSDK_LIB_PATH="$new_path" 18172 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&5 18173 $as_echo "$as_me: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&6;} 18174 fi 18175 18176 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18177 18178 path="$DXSDK_LIB_PATH" 18179 has_colon=`$ECHO $path | $GREP ^.:` 18180 new_path="$path" 18181 if test "x$has_colon" = x; then 18182 # Not in mixed or Windows style, start by that. 18183 new_path=`cmd //c echo $path` 18184 fi 18185 18186 18187 input_path="$new_path" 18188 # Check if we need to convert this using DOS-style short mode. If the path 18189 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18190 # take no chances and rewrite it. 18191 # Note: m4 eats our [], so we need to use [ and ] instead. 18192 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18193 if test "x$has_forbidden_chars" != x; then 18194 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18195 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18196 fi 18197 18198 18199 windows_path="$new_path" 18200 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18201 unix_path=`$CYGPATH -u "$windows_path"` 18202 new_path="$unix_path" 18203 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18204 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18205 new_path="$unix_path" 18206 fi 18207 18208 if test "x$path" != "x$new_path"; then 18209 DXSDK_LIB_PATH="$new_path" 18210 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&5 18211 $as_echo "$as_me: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&6;} 18212 fi 18213 18214 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18215 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18216 18217 else 18218 # We're on a posix platform. Hooray! :) 18219 path="$DXSDK_LIB_PATH" 18220 18221 if test ! -f "$path" && test ! -d "$path"; then 18222 as_fn_error $? "The path of DXSDK_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 18223 fi 18224 18225 has_space=`$ECHO "$path" | $GREP " "` 18226 if test "x$has_space" != x; then 18227 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&5 18228 $as_echo "$as_me: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 18229 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 18230 fi 18231 fi 18232 18233 18234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DirectX SDK include dir" >&5 18235 $as_echo_n "checking for DirectX SDK include dir... " >&6; } 18236 if test "x$with_dxsdk_include" != x; then 18237 DXSDK_INCLUDE_PATH="$with_dxsdk_include" 18238 else 18239 DXSDK_INCLUDE_PATH="$dxsdk_path/Include" 18240 fi 18241 # dsound.h is included in jsoundds 18242 if test ! -f "$DXSDK_INCLUDE_PATH/dsound.h"; then 18243 as_fn_error $? "Invalid DirectX SDK lib dir" "$LINENO" 5 18244 fi 18245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DXSDK_INCLUDE_PATH" >&5 18246 $as_echo "$DXSDK_INCLUDE_PATH" >&6; } 18247 18248 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18249 18250 # Input might be given as Windows format, start by converting to 18251 # unix format. 18252 path="$DXSDK_INCLUDE_PATH" 18253 new_path=`$CYGPATH -u "$path"` 18254 18255 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18256 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18257 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18258 # "foo.exe" is OK but "foo" is an error. 18259 # 18260 # This test is therefore slightly more accurate than "test -f" to check for file precense. 18261 # It is also a way to make sure we got the proper file name for the real test later on. 18262 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18263 if test "x$test_shortpath" = x; then 18264 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 18265 $as_echo "$as_me: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 18266 as_fn_error $? "Cannot locate the the path of DXSDK_INCLUDE_PATH" "$LINENO" 5 18267 fi 18268 18269 # Call helper function which possibly converts this using DOS-style short mode. 18270 # If so, the updated path is stored in $new_path. 18271 18272 input_path="$new_path" 18273 # Check if we need to convert this using DOS-style short mode. If the path 18274 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18275 # take no chances and rewrite it. 18276 # Note: m4 eats our [], so we need to use [ and ] instead. 18277 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18278 if test "x$has_forbidden_chars" != x; then 18279 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18280 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18281 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18282 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18283 # Going to short mode and back again did indeed matter. Since short mode is 18284 # case insensitive, let's make it lowercase to improve readability. 18285 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18286 # Now convert it back to Unix-stile (cygpath) 18287 input_path=`$CYGPATH -u "$shortmode_path"` 18288 new_path="$input_path" 18289 fi 18290 fi 18291 18292 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18293 if test "x$test_cygdrive_prefix" = x; then 18294 # As a simple fix, exclude /usr/bin since it's not a real path. 18295 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 18296 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18297 # a path prefixed by /cygdrive for fixpath to work. 18298 new_path="$CYGWIN_ROOT_PATH$input_path" 18299 fi 18300 fi 18301 18302 18303 if test "x$path" != "x$new_path"; then 18304 DXSDK_INCLUDE_PATH="$new_path" 18305 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&5 18306 $as_echo "$as_me: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&6;} 18307 fi 18308 18309 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18310 18311 path="$DXSDK_INCLUDE_PATH" 18312 has_colon=`$ECHO $path | $GREP ^.:` 18313 new_path="$path" 18314 if test "x$has_colon" = x; then 18315 # Not in mixed or Windows style, start by that. 18316 new_path=`cmd //c echo $path` 18317 fi 18318 18319 18320 input_path="$new_path" 18321 # Check if we need to convert this using DOS-style short mode. If the path 18322 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18323 # take no chances and rewrite it. 18324 # Note: m4 eats our [], so we need to use [ and ] instead. 18325 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18326 if test "x$has_forbidden_chars" != x; then 18327 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18328 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18329 fi 18330 18331 18332 windows_path="$new_path" 18333 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18334 unix_path=`$CYGPATH -u "$windows_path"` 18335 new_path="$unix_path" 18336 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18337 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18338 new_path="$unix_path" 18339 fi 18340 18341 if test "x$path" != "x$new_path"; then 18342 DXSDK_INCLUDE_PATH="$new_path" 18343 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&5 18344 $as_echo "$as_me: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&6;} 18345 fi 18346 18347 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18348 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18349 18350 else 18351 # We're on a posix platform. Hooray! :) 18352 path="$DXSDK_INCLUDE_PATH" 18353 18354 if test ! -f "$path" && test ! -d "$path"; then 18355 as_fn_error $? "The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 18356 fi 18357 18358 has_space=`$ECHO "$path" | $GREP " "` 18359 if test "x$has_space" != x; then 18360 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 18361 $as_echo "$as_me: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 18362 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 18363 fi 18364 fi 18365 18366 18367 18368 18369 LDFLAGS_JDK="$LDFLAGS_JDK -libpath:$DXSDK_LIB_PATH" 18370 18371 fi 18372 18373 18374 18375 # If --build AND --host is set, then the configure script will find any 18376 # cross compilation tools in the PATH. Cross compilation tools 18377 # follows the cross compilation standard where they are prefixed with ${host}. 18378 # For example the binary i686-sun-solaris2.10-gcc 18379 # will cross compile for i686-sun-solaris2.10 18380 # If neither of build and host is not set, then build=host and the 18381 # default compiler found in the path will be used. 18382 # Setting only --host, does not seem to be really supported. 18383 # Please set both --build and --host if you want to cross compile. 18384 18385 if test "x$COMPILE_TYPE" = "xcross"; then 18386 # Now we to find a C/C++ compiler that can build executables for the build 18387 # platform. We can't use the AC_PROG_CC macro, since it can only be used 18388 # once. Also, we need to do this before adding a tools dir to the path, 18389 # otherwise we might pick up cross-compilers which don't use standard naming. 18390 # Otherwise, we'll set the BUILD_tools to the native tools, but that'll have 18391 # to wait until they are properly discovered. 18392 for ac_prog in cl cc gcc 18393 do 18394 # Extract the first word of "$ac_prog", so it can be a program name with args. 18395 set dummy $ac_prog; ac_word=$2 18396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18397 $as_echo_n "checking for $ac_word... " >&6; } 18398 if ${ac_cv_path_BUILD_CC+:} false; then : 18399 $as_echo_n "(cached) " >&6 18400 else 18401 case $BUILD_CC in 18402 [\\/]* | ?:[\\/]*) 18403 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 18404 ;; 18405 *) 18406 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18407 for as_dir in $PATH 18408 do 18409 IFS=$as_save_IFS 18410 test -z "$as_dir" && as_dir=. 18411 for ac_exec_ext in '' $ac_executable_extensions; do 18412 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 18413 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 18414 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18415 break 2 18416 fi 18417 done 18418 done 18419 IFS=$as_save_IFS 18420 18421 ;; 18422 esac 18423 fi 18424 BUILD_CC=$ac_cv_path_BUILD_CC 18425 if test -n "$BUILD_CC"; then 18426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 18427 $as_echo "$BUILD_CC" >&6; } 18428 else 18429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18430 $as_echo "no" >&6; } 18431 fi 18432 18433 18434 test -n "$BUILD_CC" && break 18435 done 18436 18437 18438 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18439 18440 # First separate the path from the arguments. This will split at the first 18441 # space. 18442 complete="$BUILD_CC" 18443 path="${complete%% *}" 18444 tmp="$complete EOL" 18445 arguments="${tmp#* }" 18446 18447 # Input might be given as Windows format, start by converting to 18448 # unix format. 18449 new_path=`$CYGPATH -u "$path"` 18450 18451 # Now try to locate executable using which 18452 new_path=`$WHICH "$new_path" 2> /dev/null` 18453 # bat and cmd files are not always considered executable in cygwin causing which 18454 # to not find them 18455 if test "x$new_path" = x \ 18456 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18457 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18458 new_path=`$CYGPATH -u "$path"` 18459 fi 18460 if test "x$new_path" = x; then 18461 # Oops. Which didn't find the executable. 18462 # The splitting of arguments from the executable at a space might have been incorrect, 18463 # since paths with space are more likely in Windows. Give it another try with the whole 18464 # argument. 18465 path="$complete" 18466 arguments="EOL" 18467 new_path=`$CYGPATH -u "$path"` 18468 new_path=`$WHICH "$new_path" 2> /dev/null` 18469 # bat and cmd files are not always considered executable in cygwin causing which 18470 # to not find them 18471 if test "x$new_path" = x \ 18472 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18473 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18474 new_path=`$CYGPATH -u "$path"` 18475 fi 18476 if test "x$new_path" = x; then 18477 # It's still not found. Now this is an unrecoverable error. 18478 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 18479 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 18480 has_space=`$ECHO "$complete" | $GREP " "` 18481 if test "x$has_space" != x; then 18482 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18483 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18484 fi 18485 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 18486 fi 18487 fi 18488 18489 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18490 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18491 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18492 # "foo.exe" is OK but "foo" is an error. 18493 # 18494 # This test is therefore slightly more accurate than "test -f" to check for file precense. 18495 # It is also a way to make sure we got the proper file name for the real test later on. 18496 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18497 if test "x$test_shortpath" = x; then 18498 # Short path failed, file does not exist as specified. 18499 # Try adding .exe or .cmd 18500 if test -f "${new_path}.exe"; then 18501 input_to_shortpath="${new_path}.exe" 18502 elif test -f "${new_path}.cmd"; then 18503 input_to_shortpath="${new_path}.cmd" 18504 else 18505 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5 18506 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;} 18507 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18508 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18509 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 18510 fi 18511 else 18512 input_to_shortpath="$new_path" 18513 fi 18514 18515 # Call helper function which possibly converts this using DOS-style short mode. 18516 # If so, the updated path is stored in $new_path. 18517 new_path="$input_to_shortpath" 18518 18519 input_path="$input_to_shortpath" 18520 # Check if we need to convert this using DOS-style short mode. If the path 18521 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18522 # take no chances and rewrite it. 18523 # Note: m4 eats our [], so we need to use [ and ] instead. 18524 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18525 if test "x$has_forbidden_chars" != x; then 18526 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18527 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18528 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18529 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18530 # Going to short mode and back again did indeed matter. Since short mode is 18531 # case insensitive, let's make it lowercase to improve readability. 18532 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18533 # Now convert it back to Unix-stile (cygpath) 18534 input_path=`$CYGPATH -u "$shortmode_path"` 18535 new_path="$input_path" 18536 fi 18537 fi 18538 18539 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18540 if test "x$test_cygdrive_prefix" = x; then 18541 # As a simple fix, exclude /usr/bin since it's not a real path. 18542 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18543 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18544 # a path prefixed by /cygdrive for fixpath to work. 18545 new_path="$CYGWIN_ROOT_PATH$input_path" 18546 fi 18547 fi 18548 18549 # remove trailing .exe if any 18550 new_path="${new_path/%.exe/}" 18551 18552 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18553 18554 # First separate the path from the arguments. This will split at the first 18555 # space. 18556 complete="$BUILD_CC" 18557 path="${complete%% *}" 18558 tmp="$complete EOL" 18559 arguments="${tmp#* }" 18560 18561 # Input might be given as Windows format, start by converting to 18562 # unix format. 18563 new_path="$path" 18564 18565 windows_path="$new_path" 18566 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18567 unix_path=`$CYGPATH -u "$windows_path"` 18568 new_path="$unix_path" 18569 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18570 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18571 new_path="$unix_path" 18572 fi 18573 18574 18575 # Now try to locate executable using which 18576 new_path=`$WHICH "$new_path" 2> /dev/null` 18577 18578 if test "x$new_path" = x; then 18579 # Oops. Which didn't find the executable. 18580 # The splitting of arguments from the executable at a space might have been incorrect, 18581 # since paths with space are more likely in Windows. Give it another try with the whole 18582 # argument. 18583 path="$complete" 18584 arguments="EOL" 18585 new_path="$path" 18586 18587 windows_path="$new_path" 18588 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18589 unix_path=`$CYGPATH -u "$windows_path"` 18590 new_path="$unix_path" 18591 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18592 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18593 new_path="$unix_path" 18594 fi 18595 18596 18597 new_path=`$WHICH "$new_path" 2> /dev/null` 18598 18599 if test "x$new_path" = x; then 18600 # It's still not found. Now this is an unrecoverable error. 18601 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 18602 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 18603 has_space=`$ECHO "$complete" | $GREP " "` 18604 if test "x$has_space" != x; then 18605 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18606 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18607 fi 18608 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 18609 fi 18610 fi 18611 18612 # Now new_path has a complete unix path to the binary 18613 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18614 # Keep paths in /bin as-is, but remove trailing .exe if any 18615 new_path="${new_path/%.exe/}" 18616 # Do not save /bin paths to all_fixpath_prefixes! 18617 else 18618 # Not in mixed or Windows style, start by that. 18619 new_path=`cmd //c echo $new_path` 18620 18621 input_path="$new_path" 18622 # Check if we need to convert this using DOS-style short mode. If the path 18623 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18624 # take no chances and rewrite it. 18625 # Note: m4 eats our [], so we need to use [ and ] instead. 18626 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18627 if test "x$has_forbidden_chars" != x; then 18628 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18629 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18630 fi 18631 18632 # Output is in $new_path 18633 18634 windows_path="$new_path" 18635 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18636 unix_path=`$CYGPATH -u "$windows_path"` 18637 new_path="$unix_path" 18638 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18639 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18640 new_path="$unix_path" 18641 fi 18642 18643 # remove trailing .exe if any 18644 new_path="${new_path/%.exe/}" 18645 18646 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18647 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18648 fi 18649 18650 else 18651 # We're on a posix platform. Hooray! :) 18652 # First separate the path from the arguments. This will split at the first 18653 # space. 18654 complete="$BUILD_CC" 18655 path="${complete%% *}" 18656 tmp="$complete EOL" 18657 arguments="${tmp#* }" 18658 18659 # Cannot rely on the command "which" here since it doesn't always work. 18660 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18661 if test -z "$is_absolute_path"; then 18662 # Path to executable is not absolute. Find it. 18663 IFS_save="$IFS" 18664 IFS=: 18665 for p in $PATH; do 18666 if test -f "$p/$path" && test -x "$p/$path"; then 18667 new_path="$p/$path" 18668 break 18669 fi 18670 done 18671 IFS="$IFS_save" 18672 else 18673 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving BUILD_CC (as $path) failed, using $path directly." >&5 18674 $as_echo "$as_me: Resolving BUILD_CC (as $path) failed, using $path directly." >&6;} 18675 new_path="$path" 18676 fi 18677 18678 if test "x$new_path" = x; then 18679 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 18680 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 18681 has_space=`$ECHO "$complete" | $GREP " "` 18682 if test "x$has_space" != x; then 18683 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18684 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18685 fi 18686 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 18687 fi 18688 fi 18689 18690 # Now join together the path and the arguments once again 18691 if test "x$arguments" != xEOL; then 18692 new_complete="$new_path ${arguments% *}" 18693 else 18694 new_complete="$new_path" 18695 fi 18696 18697 if test "x$complete" != "x$new_complete"; then 18698 BUILD_CC="$new_complete" 18699 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5 18700 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;} 18701 fi 18702 18703 for ac_prog in cl CC g++ 18704 do 18705 # Extract the first word of "$ac_prog", so it can be a program name with args. 18706 set dummy $ac_prog; ac_word=$2 18707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18708 $as_echo_n "checking for $ac_word... " >&6; } 18709 if ${ac_cv_path_BUILD_CXX+:} false; then : 18710 $as_echo_n "(cached) " >&6 18711 else 18712 case $BUILD_CXX in 18713 [\\/]* | ?:[\\/]*) 18714 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 18715 ;; 18716 *) 18717 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18718 for as_dir in $PATH 18719 do 18720 IFS=$as_save_IFS 18721 test -z "$as_dir" && as_dir=. 18722 for ac_exec_ext in '' $ac_executable_extensions; do 18723 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 18724 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 18725 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18726 break 2 18727 fi 18728 done 18729 done 18730 IFS=$as_save_IFS 18731 18732 ;; 18733 esac 18734 fi 18735 BUILD_CXX=$ac_cv_path_BUILD_CXX 18736 if test -n "$BUILD_CXX"; then 18737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 18738 $as_echo "$BUILD_CXX" >&6; } 18739 else 18740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18741 $as_echo "no" >&6; } 18742 fi 18743 18744 18745 test -n "$BUILD_CXX" && break 18746 done 18747 18748 18749 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18750 18751 # First separate the path from the arguments. This will split at the first 18752 # space. 18753 complete="$BUILD_CXX" 18754 path="${complete%% *}" 18755 tmp="$complete EOL" 18756 arguments="${tmp#* }" 18757 18758 # Input might be given as Windows format, start by converting to 18759 # unix format. 18760 new_path=`$CYGPATH -u "$path"` 18761 18762 # Now try to locate executable using which 18763 new_path=`$WHICH "$new_path" 2> /dev/null` 18764 # bat and cmd files are not always considered executable in cygwin causing which 18765 # to not find them 18766 if test "x$new_path" = x \ 18767 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18768 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18769 new_path=`$CYGPATH -u "$path"` 18770 fi 18771 if test "x$new_path" = x; then 18772 # Oops. Which didn't find the executable. 18773 # The splitting of arguments from the executable at a space might have been incorrect, 18774 # since paths with space are more likely in Windows. Give it another try with the whole 18775 # argument. 18776 path="$complete" 18777 arguments="EOL" 18778 new_path=`$CYGPATH -u "$path"` 18779 new_path=`$WHICH "$new_path" 2> /dev/null` 18780 # bat and cmd files are not always considered executable in cygwin causing which 18781 # to not find them 18782 if test "x$new_path" = x \ 18783 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18784 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18785 new_path=`$CYGPATH -u "$path"` 18786 fi 18787 if test "x$new_path" = x; then 18788 # It's still not found. Now this is an unrecoverable error. 18789 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 18790 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 18791 has_space=`$ECHO "$complete" | $GREP " "` 18792 if test "x$has_space" != x; then 18793 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18794 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18795 fi 18796 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 18797 fi 18798 fi 18799 18800 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18801 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18802 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18803 # "foo.exe" is OK but "foo" is an error. 18804 # 18805 # This test is therefore slightly more accurate than "test -f" to check for file precense. 18806 # It is also a way to make sure we got the proper file name for the real test later on. 18807 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18808 if test "x$test_shortpath" = x; then 18809 # Short path failed, file does not exist as specified. 18810 # Try adding .exe or .cmd 18811 if test -f "${new_path}.exe"; then 18812 input_to_shortpath="${new_path}.exe" 18813 elif test -f "${new_path}.cmd"; then 18814 input_to_shortpath="${new_path}.cmd" 18815 else 18816 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5 18817 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;} 18818 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18819 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18820 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 18821 fi 18822 else 18823 input_to_shortpath="$new_path" 18824 fi 18825 18826 # Call helper function which possibly converts this using DOS-style short mode. 18827 # If so, the updated path is stored in $new_path. 18828 new_path="$input_to_shortpath" 18829 18830 input_path="$input_to_shortpath" 18831 # Check if we need to convert this using DOS-style short mode. If the path 18832 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18833 # take no chances and rewrite it. 18834 # Note: m4 eats our [], so we need to use [ and ] instead. 18835 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18836 if test "x$has_forbidden_chars" != x; then 18837 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18838 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18839 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18840 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18841 # Going to short mode and back again did indeed matter. Since short mode is 18842 # case insensitive, let's make it lowercase to improve readability. 18843 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18844 # Now convert it back to Unix-stile (cygpath) 18845 input_path=`$CYGPATH -u "$shortmode_path"` 18846 new_path="$input_path" 18847 fi 18848 fi 18849 18850 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18851 if test "x$test_cygdrive_prefix" = x; then 18852 # As a simple fix, exclude /usr/bin since it's not a real path. 18853 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18854 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18855 # a path prefixed by /cygdrive for fixpath to work. 18856 new_path="$CYGWIN_ROOT_PATH$input_path" 18857 fi 18858 fi 18859 18860 # remove trailing .exe if any 18861 new_path="${new_path/%.exe/}" 18862 18863 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18864 18865 # First separate the path from the arguments. This will split at the first 18866 # space. 18867 complete="$BUILD_CXX" 18868 path="${complete%% *}" 18869 tmp="$complete EOL" 18870 arguments="${tmp#* }" 18871 18872 # Input might be given as Windows format, start by converting to 18873 # unix format. 18874 new_path="$path" 18875 18876 windows_path="$new_path" 18877 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18878 unix_path=`$CYGPATH -u "$windows_path"` 18879 new_path="$unix_path" 18880 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18881 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18882 new_path="$unix_path" 18883 fi 18884 18885 18886 # Now try to locate executable using which 18887 new_path=`$WHICH "$new_path" 2> /dev/null` 18888 18889 if test "x$new_path" = x; then 18890 # Oops. Which didn't find the executable. 18891 # The splitting of arguments from the executable at a space might have been incorrect, 18892 # since paths with space are more likely in Windows. Give it another try with the whole 18893 # argument. 18894 path="$complete" 18895 arguments="EOL" 18896 new_path="$path" 18897 18898 windows_path="$new_path" 18899 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18900 unix_path=`$CYGPATH -u "$windows_path"` 18901 new_path="$unix_path" 18902 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18903 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18904 new_path="$unix_path" 18905 fi 18906 18907 18908 new_path=`$WHICH "$new_path" 2> /dev/null` 18909 18910 if test "x$new_path" = x; then 18911 # It's still not found. Now this is an unrecoverable error. 18912 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 18913 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 18914 has_space=`$ECHO "$complete" | $GREP " "` 18915 if test "x$has_space" != x; then 18916 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18917 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18918 fi 18919 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 18920 fi 18921 fi 18922 18923 # Now new_path has a complete unix path to the binary 18924 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18925 # Keep paths in /bin as-is, but remove trailing .exe if any 18926 new_path="${new_path/%.exe/}" 18927 # Do not save /bin paths to all_fixpath_prefixes! 18928 else 18929 # Not in mixed or Windows style, start by that. 18930 new_path=`cmd //c echo $new_path` 18931 18932 input_path="$new_path" 18933 # Check if we need to convert this using DOS-style short mode. If the path 18934 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18935 # take no chances and rewrite it. 18936 # Note: m4 eats our [], so we need to use [ and ] instead. 18937 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18938 if test "x$has_forbidden_chars" != x; then 18939 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18940 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18941 fi 18942 18943 # Output is in $new_path 18944 18945 windows_path="$new_path" 18946 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18947 unix_path=`$CYGPATH -u "$windows_path"` 18948 new_path="$unix_path" 18949 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18950 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18951 new_path="$unix_path" 18952 fi 18953 18954 # remove trailing .exe if any 18955 new_path="${new_path/%.exe/}" 18956 18957 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18958 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18959 fi 18960 18961 else 18962 # We're on a posix platform. Hooray! :) 18963 # First separate the path from the arguments. This will split at the first 18964 # space. 18965 complete="$BUILD_CXX" 18966 path="${complete%% *}" 18967 tmp="$complete EOL" 18968 arguments="${tmp#* }" 18969 18970 # Cannot rely on the command "which" here since it doesn't always work. 18971 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18972 if test -z "$is_absolute_path"; then 18973 # Path to executable is not absolute. Find it. 18974 IFS_save="$IFS" 18975 IFS=: 18976 for p in $PATH; do 18977 if test -f "$p/$path" && test -x "$p/$path"; then 18978 new_path="$p/$path" 18979 break 18980 fi 18981 done 18982 IFS="$IFS_save" 18983 else 18984 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving BUILD_CXX (as $path) failed, using $path directly." >&5 18985 $as_echo "$as_me: Resolving BUILD_CXX (as $path) failed, using $path directly." >&6;} 18986 new_path="$path" 18987 fi 18988 18989 if test "x$new_path" = x; then 18990 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 18991 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 18992 has_space=`$ECHO "$complete" | $GREP " "` 18993 if test "x$has_space" != x; then 18994 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18995 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18996 fi 18997 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 18998 fi 18999 fi 19000 19001 # Now join together the path and the arguments once again 19002 if test "x$arguments" != xEOL; then 19003 new_complete="$new_path ${arguments% *}" 19004 else 19005 new_complete="$new_path" 19006 fi 19007 19008 if test "x$complete" != "x$new_complete"; then 19009 BUILD_CXX="$new_complete" 19010 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5 19011 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;} 19012 fi 19013 19014 # Extract the first word of "ld", so it can be a program name with args. 19015 set dummy ld; ac_word=$2 19016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19017 $as_echo_n "checking for $ac_word... " >&6; } 19018 if ${ac_cv_path_BUILD_LD+:} false; then : 19019 $as_echo_n "(cached) " >&6 19020 else 19021 case $BUILD_LD in 19022 [\\/]* | ?:[\\/]*) 19023 ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path. 19024 ;; 19025 *) 19026 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19027 for as_dir in $PATH 19028 do 19029 IFS=$as_save_IFS 19030 test -z "$as_dir" && as_dir=. 19031 for ac_exec_ext in '' $ac_executable_extensions; do 19032 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 19033 ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext" 19034 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19035 break 2 19036 fi 19037 done 19038 done 19039 IFS=$as_save_IFS 19040 19041 ;; 19042 esac 19043 fi 19044 BUILD_LD=$ac_cv_path_BUILD_LD 19045 if test -n "$BUILD_LD"; then 19046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5 19047 $as_echo "$BUILD_LD" >&6; } 19048 else 19049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19050 $as_echo "no" >&6; } 19051 fi 19052 19053 19054 19055 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19056 19057 # First separate the path from the arguments. This will split at the first 19058 # space. 19059 complete="$BUILD_LD" 19060 path="${complete%% *}" 19061 tmp="$complete EOL" 19062 arguments="${tmp#* }" 19063 19064 # Input might be given as Windows format, start by converting to 19065 # unix format. 19066 new_path=`$CYGPATH -u "$path"` 19067 19068 # Now try to locate executable using which 19069 new_path=`$WHICH "$new_path" 2> /dev/null` 19070 # bat and cmd files are not always considered executable in cygwin causing which 19071 # to not find them 19072 if test "x$new_path" = x \ 19073 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19074 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19075 new_path=`$CYGPATH -u "$path"` 19076 fi 19077 if test "x$new_path" = x; then 19078 # Oops. Which didn't find the executable. 19079 # The splitting of arguments from the executable at a space might have been incorrect, 19080 # since paths with space are more likely in Windows. Give it another try with the whole 19081 # argument. 19082 path="$complete" 19083 arguments="EOL" 19084 new_path=`$CYGPATH -u "$path"` 19085 new_path=`$WHICH "$new_path" 2> /dev/null` 19086 # bat and cmd files are not always considered executable in cygwin causing which 19087 # to not find them 19088 if test "x$new_path" = x \ 19089 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19090 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19091 new_path=`$CYGPATH -u "$path"` 19092 fi 19093 if test "x$new_path" = x; then 19094 # It's still not found. Now this is an unrecoverable error. 19095 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5 19096 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;} 19097 has_space=`$ECHO "$complete" | $GREP " "` 19098 if test "x$has_space" != x; then 19099 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19100 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19101 fi 19102 as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5 19103 fi 19104 fi 19105 19106 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19107 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19108 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19109 # "foo.exe" is OK but "foo" is an error. 19110 # 19111 # This test is therefore slightly more accurate than "test -f" to check for file precense. 19112 # It is also a way to make sure we got the proper file name for the real test later on. 19113 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19114 if test "x$test_shortpath" = x; then 19115 # Short path failed, file does not exist as specified. 19116 # Try adding .exe or .cmd 19117 if test -f "${new_path}.exe"; then 19118 input_to_shortpath="${new_path}.exe" 19119 elif test -f "${new_path}.cmd"; then 19120 input_to_shortpath="${new_path}.cmd" 19121 else 19122 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&5 19123 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&6;} 19124 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19125 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19126 as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5 19127 fi 19128 else 19129 input_to_shortpath="$new_path" 19130 fi 19131 19132 # Call helper function which possibly converts this using DOS-style short mode. 19133 # If so, the updated path is stored in $new_path. 19134 new_path="$input_to_shortpath" 19135 19136 input_path="$input_to_shortpath" 19137 # Check if we need to convert this using DOS-style short mode. If the path 19138 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19139 # take no chances and rewrite it. 19140 # Note: m4 eats our [], so we need to use [ and ] instead. 19141 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19142 if test "x$has_forbidden_chars" != x; then 19143 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19144 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19145 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19146 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19147 # Going to short mode and back again did indeed matter. Since short mode is 19148 # case insensitive, let's make it lowercase to improve readability. 19149 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19150 # Now convert it back to Unix-stile (cygpath) 19151 input_path=`$CYGPATH -u "$shortmode_path"` 19152 new_path="$input_path" 19153 fi 19154 fi 19155 19156 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19157 if test "x$test_cygdrive_prefix" = x; then 19158 # As a simple fix, exclude /usr/bin since it's not a real path. 19159 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19160 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19161 # a path prefixed by /cygdrive for fixpath to work. 19162 new_path="$CYGWIN_ROOT_PATH$input_path" 19163 fi 19164 fi 19165 19166 # remove trailing .exe if any 19167 new_path="${new_path/%.exe/}" 19168 19169 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19170 19171 # First separate the path from the arguments. This will split at the first 19172 # space. 19173 complete="$BUILD_LD" 19174 path="${complete%% *}" 19175 tmp="$complete EOL" 19176 arguments="${tmp#* }" 19177 19178 # Input might be given as Windows format, start by converting to 19179 # unix format. 19180 new_path="$path" 19181 19182 windows_path="$new_path" 19183 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19184 unix_path=`$CYGPATH -u "$windows_path"` 19185 new_path="$unix_path" 19186 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19187 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19188 new_path="$unix_path" 19189 fi 19190 19191 19192 # Now try to locate executable using which 19193 new_path=`$WHICH "$new_path" 2> /dev/null` 19194 19195 if test "x$new_path" = x; then 19196 # Oops. Which didn't find the executable. 19197 # The splitting of arguments from the executable at a space might have been incorrect, 19198 # since paths with space are more likely in Windows. Give it another try with the whole 19199 # argument. 19200 path="$complete" 19201 arguments="EOL" 19202 new_path="$path" 19203 19204 windows_path="$new_path" 19205 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19206 unix_path=`$CYGPATH -u "$windows_path"` 19207 new_path="$unix_path" 19208 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19209 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19210 new_path="$unix_path" 19211 fi 19212 19213 19214 new_path=`$WHICH "$new_path" 2> /dev/null` 19215 19216 if test "x$new_path" = x; then 19217 # It's still not found. Now this is an unrecoverable error. 19218 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5 19219 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;} 19220 has_space=`$ECHO "$complete" | $GREP " "` 19221 if test "x$has_space" != x; then 19222 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19223 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19224 fi 19225 as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5 19226 fi 19227 fi 19228 19229 # Now new_path has a complete unix path to the binary 19230 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19231 # Keep paths in /bin as-is, but remove trailing .exe if any 19232 new_path="${new_path/%.exe/}" 19233 # Do not save /bin paths to all_fixpath_prefixes! 19234 else 19235 # Not in mixed or Windows style, start by that. 19236 new_path=`cmd //c echo $new_path` 19237 19238 input_path="$new_path" 19239 # Check if we need to convert this using DOS-style short mode. If the path 19240 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19241 # take no chances and rewrite it. 19242 # Note: m4 eats our [], so we need to use [ and ] instead. 19243 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19244 if test "x$has_forbidden_chars" != x; then 19245 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19246 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19247 fi 19248 19249 # Output is in $new_path 19250 19251 windows_path="$new_path" 19252 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19253 unix_path=`$CYGPATH -u "$windows_path"` 19254 new_path="$unix_path" 19255 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19256 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19257 new_path="$unix_path" 19258 fi 19259 19260 # remove trailing .exe if any 19261 new_path="${new_path/%.exe/}" 19262 19263 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19264 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19265 fi 19266 19267 else 19268 # We're on a posix platform. Hooray! :) 19269 # First separate the path from the arguments. This will split at the first 19270 # space. 19271 complete="$BUILD_LD" 19272 path="${complete%% *}" 19273 tmp="$complete EOL" 19274 arguments="${tmp#* }" 19275 19276 # Cannot rely on the command "which" here since it doesn't always work. 19277 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19278 if test -z "$is_absolute_path"; then 19279 # Path to executable is not absolute. Find it. 19280 IFS_save="$IFS" 19281 IFS=: 19282 for p in $PATH; do 19283 if test -f "$p/$path" && test -x "$p/$path"; then 19284 new_path="$p/$path" 19285 break 19286 fi 19287 done 19288 IFS="$IFS_save" 19289 else 19290 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving BUILD_LD (as $path) failed, using $path directly." >&5 19291 $as_echo "$as_me: Resolving BUILD_LD (as $path) failed, using $path directly." >&6;} 19292 new_path="$path" 19293 fi 19294 19295 if test "x$new_path" = x; then 19296 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5 19297 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;} 19298 has_space=`$ECHO "$complete" | $GREP " "` 19299 if test "x$has_space" != x; then 19300 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19301 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19302 fi 19303 as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5 19304 fi 19305 fi 19306 19307 # Now join together the path and the arguments once again 19308 if test "x$arguments" != xEOL; then 19309 new_complete="$new_path ${arguments% *}" 19310 else 19311 new_complete="$new_path" 19312 fi 19313 19314 if test "x$complete" != "x$new_complete"; then 19315 BUILD_LD="$new_complete" 19316 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_LD to \"$new_complete\"" >&5 19317 $as_echo "$as_me: Rewriting BUILD_LD to \"$new_complete\"" >&6;} 19318 fi 19319 19320 fi 19321 19322 19323 19324 19325 # If a devkit is found on the builddeps server, then prepend its path to the 19326 # PATH variable. If there are cross compilers available in the devkit, these 19327 # will be found by AC_PROG_CC et al. 19328 DEVKIT= 19329 19330 19331 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 19332 # Source the builddeps file again, to make sure it uses the latest variables! 19333 . $builddepsfile 19334 # Look for a target and build machine specific resource! 19335 eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}} 19336 if test "x$resource" = x; then 19337 # Ok, lets instead look for a target specific resource 19338 eval resource=\${builddep_devkit_TARGET_${rewritten_target_var}} 19339 fi 19340 if test "x$resource" = x; then 19341 # Ok, lets instead look for a build specific resource 19342 eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}} 19343 fi 19344 if test "x$resource" = x; then 19345 # Ok, lets instead look for a generic resource 19346 # (The devkit comes from M4 and not the shell, thus no need for eval here.) 19347 resource=${builddep_devkit} 19348 fi 19349 if test "x$resource" != x; then 19350 { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for devkit" >&5 19351 $as_echo "$as_me: Using builddeps $resource for devkit" >&6;} 19352 # If the resource in the builddeps.conf file is an existing directory, 19353 # for example /java/linux/cups 19354 if test -d ${resource}; then 19355 depdir=${resource} 19356 else 19357 19358 # devkit is for example mymodule 19359 # $resource is for example libs/general/libmymod_1_2_3.zip 19360 # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps 19361 # $with_builddeps_dir is for example /localhome/builddeps 19362 # depdir is the name of the variable into which we store the depdir, eg MYMOD 19363 # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and 19364 # unzip into the directory: /localhome/builddeps/libmymod_1_2_3 19365 filename=`basename $resource` 19366 filebase=`echo $filename | sed 's/\.[^\.]*$//'` 19367 filebase=${filename%%.*} 19368 extension=${filename#*.} 19369 installdir=$with_builddeps_dir/$filebase 19370 if test ! -f $installdir/$filename.unpacked; then 19371 { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&5 19372 $as_echo "$as_me: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&6;} 19373 if test ! -d $installdir; then 19374 mkdir -p $installdir 19375 fi 19376 if test ! -d $installdir; then 19377 as_fn_error $? "Could not create directory $installdir" "$LINENO" 5 19378 fi 19379 tmpfile=`mktemp $installdir/devkit.XXXXXXXXX` 19380 touch $tmpfile 19381 if test ! -f $tmpfile; then 19382 as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5 19383 fi 19384 19385 # $with_builddeps_server/$resource is the ftp://abuilddeps.server.com/libs/cups.zip 19386 # $tmpfile is the local file name for the downloaded file. 19387 VALID_TOOL=no 19388 if test "x$BDEPS_FTP" = xwget; then 19389 VALID_TOOL=yes 19390 wget -O $tmpfile $with_builddeps_server/$resource 19391 fi 19392 if test "x$BDEPS_FTP" = xlftp; then 19393 VALID_TOOL=yes 19394 lftp -c "get $with_builddeps_server/$resource -o $tmpfile" 19395 fi 19396 if test "x$BDEPS_FTP" = xftp; then 19397 VALID_TOOL=yes 19398 FTPSERVER=`echo $with_builddeps_server/$resource | cut -f 3 -d '/'` 19399 FTPPATH=`echo $with_builddeps_server/$resource | cut -f 4- -d '/'` 19400 FTPUSERPWD=${FTPSERVER%%@*} 19401 if test "x$FTPSERVER" != "x$FTPUSERPWD"; then 19402 FTPUSER=${userpwd%%:*} 19403 FTPPWD=${userpwd#*@} 19404 FTPSERVER=${FTPSERVER#*@} 19405 else 19406 FTPUSER=ftp 19407 FTPPWD=ftp 19408 fi 19409 # the "pass" command does not work on some 19410 # ftp clients (read ftp.exe) but if it works, 19411 # passive mode is better! 19412 (\ 19413 echo "user $FTPUSER $FTPPWD" ;\ 19414 echo "pass" ;\ 19415 echo "bin" ;\ 19416 echo "get $FTPPATH $tmpfile" ;\ 19417 ) | ftp -in $FTPSERVER 19418 fi 19419 if test "x$VALID_TOOL" != xyes; then 19420 as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5 19421 fi 19422 19423 mv $tmpfile $installdir/$filename 19424 if test ! -s $installdir/$filename; then 19425 as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5 19426 fi 19427 case "$extension" in 19428 zip) echo "Unzipping $installdir/$filename..." 19429 (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked) 19430 ;; 19431 tar.gz) echo "Untaring $installdir/$filename..." 19432 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 19433 ;; 19434 tgz) echo "Untaring $installdir/$filename..." 19435 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 19436 ;; 19437 *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5 19438 ;; 19439 esac 19440 fi 19441 if test -f $installdir/$filename.unpacked; then 19442 depdir=$installdir 19443 fi 19444 19445 fi 19446 # Source the builddeps file again, because in the previous command, the depdir 19447 # was updated to point at the current build dependency install directory. 19448 . $builddepsfile 19449 # Now extract variables from the builddeps.conf files. 19450 theroot=${builddep_devkit_ROOT} 19451 thecflags=${builddep_devkit_CFLAGS} 19452 thelibs=${builddep_devkit_LIBS} 19453 if test "x$depdir" = x; then 19454 as_fn_error $? "Could not download build dependency devkit" "$LINENO" 5 19455 fi 19456 DEVKIT=$depdir 19457 if test "x$theroot" != x; then 19458 DEVKIT="$theroot" 19459 fi 19460 if test "x$thecflags" != x; then 19461 DEVKIT_CFLAGS="$thecflags" 19462 fi 19463 if test "x$thelibs" != x; then 19464 DEVKIT_LIBS="$thelibs" 19465 fi 19466 # Found devkit 19467 PATH="$DEVKIT/bin:$PATH" 19468 SYS_ROOT="$DEVKIT/${rewritten_target}/sys-root" 19469 if test "x$x_includes" = "xNONE"; then 19470 x_includes="$SYS_ROOT/usr/include/X11" 19471 fi 19472 if test "x$x_libraries" = "xNONE"; then 19473 x_libraries="$SYS_ROOT/usr/lib" 19474 fi 19475 19476 19477 fi 19478 19479 fi 19480 19481 19482 if test "x$SYS_ROOT" != "x/" ; then 19483 CFLAGS="--sysroot=$SYS_ROOT $CFLAGS" 19484 CXXFLAGS="--sysroot=$SYS_ROOT $CXXFLAGS" 19485 OBJCFLAGS="--sysroot=$SYS_ROOT $OBJCFLAGS" 19486 OBJCXXFLAGS="--sysroot=$SYS_ROOT $OBJCFLAGS" 19487 CPPFLAGS="--sysroot=$SYS_ROOT $CPPFLAGS" 19488 LDFLAGS="--sysroot=$SYS_ROOT $LDFLAGS" 19489 fi 19490 19491 # Store the CFLAGS etal passed to the configure script. 19492 ORG_CFLAGS="$CFLAGS" 19493 ORG_CXXFLAGS="$CXXFLAGS" 19494 ORG_OBJCFLAGS="$OBJCFLAGS" 19495 19496 # autoconf magic only relies on PATH, so update it if tools dir is specified 19497 OLD_PATH="$PATH" 19498 if test "x$TOOLS_DIR" != x; then 19499 PATH=$TOOLS_DIR:$PATH 19500 fi 19501 19502 19503 ### Locate C compiler (CC) 19504 19505 # On windows, only cl.exe is supported. 19506 # On Solaris, cc is preferred to gcc. 19507 # Elsewhere, gcc is preferred to cc. 19508 19509 if test "x$CC" != x; then 19510 COMPILER_CHECK_LIST="$CC" 19511 elif test "x$OPENJDK_TARGET_OS" = "xwindows"; then 19512 COMPILER_CHECK_LIST="cl" 19513 elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 19514 COMPILER_CHECK_LIST="cc gcc" 19515 else 19516 COMPILER_CHECK_LIST="gcc cc" 19517 fi 19518 19519 19520 COMPILER_NAME=C 19521 19522 CC= 19523 # If TOOLS_DIR is set, check for all compiler names in there first 19524 # before checking the rest of the PATH. 19525 if test -n "$TOOLS_DIR"; then 19526 PATH_save="$PATH" 19527 PATH="$TOOLS_DIR" 19528 for ac_prog in $COMPILER_CHECK_LIST 19529 do 19530 # Extract the first word of "$ac_prog", so it can be a program name with args. 19531 set dummy $ac_prog; ac_word=$2 19532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19533 $as_echo_n "checking for $ac_word... " >&6; } 19534 if ${ac_cv_path_TOOLS_DIR_CC+:} false; then : 19535 $as_echo_n "(cached) " >&6 19536 else 19537 case $TOOLS_DIR_CC in 19538 [\\/]* | ?:[\\/]*) 19539 ac_cv_path_TOOLS_DIR_CC="$TOOLS_DIR_CC" # Let the user override the test with a path. 19540 ;; 19541 *) 19542 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19543 for as_dir in $PATH 19544 do 19545 IFS=$as_save_IFS 19546 test -z "$as_dir" && as_dir=. 19547 for ac_exec_ext in '' $ac_executable_extensions; do 19548 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 19549 ac_cv_path_TOOLS_DIR_CC="$as_dir/$ac_word$ac_exec_ext" 19550 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19551 break 2 19552 fi 19553 done 19554 done 19555 IFS=$as_save_IFS 19556 19557 ;; 19558 esac 19559 fi 19560 TOOLS_DIR_CC=$ac_cv_path_TOOLS_DIR_CC 19561 if test -n "$TOOLS_DIR_CC"; then 19562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CC" >&5 19563 $as_echo "$TOOLS_DIR_CC" >&6; } 19564 else 19565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19566 $as_echo "no" >&6; } 19567 fi 19568 19569 19570 test -n "$TOOLS_DIR_CC" && break 19571 done 19572 19573 CC=$TOOLS_DIR_CC 19574 PATH="$PATH_save" 19575 fi 19576 19577 # AC_PATH_PROGS can't be run multiple times with the same variable, 19578 # so create a new name for this run. 19579 if test "x$CC" = x; then 19580 for ac_prog in $COMPILER_CHECK_LIST 19581 do 19582 # Extract the first word of "$ac_prog", so it can be a program name with args. 19583 set dummy $ac_prog; ac_word=$2 19584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19585 $as_echo_n "checking for $ac_word... " >&6; } 19586 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 19587 $as_echo_n "(cached) " >&6 19588 else 19589 case $POTENTIAL_CC in 19590 [\\/]* | ?:[\\/]*) 19591 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 19592 ;; 19593 *) 19594 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19595 for as_dir in $PATH 19596 do 19597 IFS=$as_save_IFS 19598 test -z "$as_dir" && as_dir=. 19599 for ac_exec_ext in '' $ac_executable_extensions; do 19600 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 19601 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 19602 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19603 break 2 19604 fi 19605 done 19606 done 19607 IFS=$as_save_IFS 19608 19609 ;; 19610 esac 19611 fi 19612 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 19613 if test -n "$POTENTIAL_CC"; then 19614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 19615 $as_echo "$POTENTIAL_CC" >&6; } 19616 else 19617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19618 $as_echo "no" >&6; } 19619 fi 19620 19621 19622 test -n "$POTENTIAL_CC" && break 19623 done 19624 19625 CC=$POTENTIAL_CC 19626 fi 19627 19628 if test "x$CC" = x; then 19629 19630 # Print a helpful message on how to acquire the necessary build dependency. 19631 # devkit is the help tag: freetyp2, cups, pulse, alsa etc 19632 MISSING_DEPENDENCY=devkit 19633 PKGHANDLER_COMMAND= 19634 19635 case $PKGHANDLER in 19636 apt-get) 19637 apt_help $MISSING_DEPENDENCY ;; 19638 yum) 19639 yum_help $MISSING_DEPENDENCY ;; 19640 port) 19641 port_help $MISSING_DEPENDENCY ;; 19642 pkgutil) 19643 pkgutil_help $MISSING_DEPENDENCY ;; 19644 pkgadd) 19645 pkgadd_help $MISSING_DEPENDENCY ;; 19646 * ) 19647 break ;; 19648 esac 19649 19650 if test "x$PKGHANDLER_COMMAND" != x; then 19651 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 19652 fi 19653 19654 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 19655 fi 19656 19657 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19658 19659 # First separate the path from the arguments. This will split at the first 19660 # space. 19661 complete="$CC" 19662 path="${complete%% *}" 19663 tmp="$complete EOL" 19664 arguments="${tmp#* }" 19665 19666 # Input might be given as Windows format, start by converting to 19667 # unix format. 19668 new_path=`$CYGPATH -u "$path"` 19669 19670 # Now try to locate executable using which 19671 new_path=`$WHICH "$new_path" 2> /dev/null` 19672 # bat and cmd files are not always considered executable in cygwin causing which 19673 # to not find them 19674 if test "x$new_path" = x \ 19675 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19676 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19677 new_path=`$CYGPATH -u "$path"` 19678 fi 19679 if test "x$new_path" = x; then 19680 # Oops. Which didn't find the executable. 19681 # The splitting of arguments from the executable at a space might have been incorrect, 19682 # since paths with space are more likely in Windows. Give it another try with the whole 19683 # argument. 19684 path="$complete" 19685 arguments="EOL" 19686 new_path=`$CYGPATH -u "$path"` 19687 new_path=`$WHICH "$new_path" 2> /dev/null` 19688 # bat and cmd files are not always considered executable in cygwin causing which 19689 # to not find them 19690 if test "x$new_path" = x \ 19691 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19692 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19693 new_path=`$CYGPATH -u "$path"` 19694 fi 19695 if test "x$new_path" = x; then 19696 # It's still not found. Now this is an unrecoverable error. 19697 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 19698 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 19699 has_space=`$ECHO "$complete" | $GREP " "` 19700 if test "x$has_space" != x; then 19701 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19702 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19703 fi 19704 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 19705 fi 19706 fi 19707 19708 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19709 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19710 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19711 # "foo.exe" is OK but "foo" is an error. 19712 # 19713 # This test is therefore slightly more accurate than "test -f" to check for file precense. 19714 # It is also a way to make sure we got the proper file name for the real test later on. 19715 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19716 if test "x$test_shortpath" = x; then 19717 # Short path failed, file does not exist as specified. 19718 # Try adding .exe or .cmd 19719 if test -f "${new_path}.exe"; then 19720 input_to_shortpath="${new_path}.exe" 19721 elif test -f "${new_path}.cmd"; then 19722 input_to_shortpath="${new_path}.cmd" 19723 else 19724 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5 19725 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;} 19726 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19727 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19728 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 19729 fi 19730 else 19731 input_to_shortpath="$new_path" 19732 fi 19733 19734 # Call helper function which possibly converts this using DOS-style short mode. 19735 # If so, the updated path is stored in $new_path. 19736 new_path="$input_to_shortpath" 19737 19738 input_path="$input_to_shortpath" 19739 # Check if we need to convert this using DOS-style short mode. If the path 19740 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19741 # take no chances and rewrite it. 19742 # Note: m4 eats our [], so we need to use [ and ] instead. 19743 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19744 if test "x$has_forbidden_chars" != x; then 19745 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19746 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19747 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19748 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19749 # Going to short mode and back again did indeed matter. Since short mode is 19750 # case insensitive, let's make it lowercase to improve readability. 19751 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19752 # Now convert it back to Unix-stile (cygpath) 19753 input_path=`$CYGPATH -u "$shortmode_path"` 19754 new_path="$input_path" 19755 fi 19756 fi 19757 19758 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19759 if test "x$test_cygdrive_prefix" = x; then 19760 # As a simple fix, exclude /usr/bin since it's not a real path. 19761 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19762 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19763 # a path prefixed by /cygdrive for fixpath to work. 19764 new_path="$CYGWIN_ROOT_PATH$input_path" 19765 fi 19766 fi 19767 19768 # remove trailing .exe if any 19769 new_path="${new_path/%.exe/}" 19770 19771 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19772 19773 # First separate the path from the arguments. This will split at the first 19774 # space. 19775 complete="$CC" 19776 path="${complete%% *}" 19777 tmp="$complete EOL" 19778 arguments="${tmp#* }" 19779 19780 # Input might be given as Windows format, start by converting to 19781 # unix format. 19782 new_path="$path" 19783 19784 windows_path="$new_path" 19785 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19786 unix_path=`$CYGPATH -u "$windows_path"` 19787 new_path="$unix_path" 19788 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19789 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19790 new_path="$unix_path" 19791 fi 19792 19793 19794 # Now try to locate executable using which 19795 new_path=`$WHICH "$new_path" 2> /dev/null` 19796 19797 if test "x$new_path" = x; then 19798 # Oops. Which didn't find the executable. 19799 # The splitting of arguments from the executable at a space might have been incorrect, 19800 # since paths with space are more likely in Windows. Give it another try with the whole 19801 # argument. 19802 path="$complete" 19803 arguments="EOL" 19804 new_path="$path" 19805 19806 windows_path="$new_path" 19807 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19808 unix_path=`$CYGPATH -u "$windows_path"` 19809 new_path="$unix_path" 19810 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19811 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19812 new_path="$unix_path" 19813 fi 19814 19815 19816 new_path=`$WHICH "$new_path" 2> /dev/null` 19817 19818 if test "x$new_path" = x; then 19819 # It's still not found. Now this is an unrecoverable error. 19820 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 19821 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 19822 has_space=`$ECHO "$complete" | $GREP " "` 19823 if test "x$has_space" != x; then 19824 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19825 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19826 fi 19827 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 19828 fi 19829 fi 19830 19831 # Now new_path has a complete unix path to the binary 19832 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19833 # Keep paths in /bin as-is, but remove trailing .exe if any 19834 new_path="${new_path/%.exe/}" 19835 # Do not save /bin paths to all_fixpath_prefixes! 19836 else 19837 # Not in mixed or Windows style, start by that. 19838 new_path=`cmd //c echo $new_path` 19839 19840 input_path="$new_path" 19841 # Check if we need to convert this using DOS-style short mode. If the path 19842 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19843 # take no chances and rewrite it. 19844 # Note: m4 eats our [], so we need to use [ and ] instead. 19845 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19846 if test "x$has_forbidden_chars" != x; then 19847 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19848 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19849 fi 19850 19851 # Output is in $new_path 19852 19853 windows_path="$new_path" 19854 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19855 unix_path=`$CYGPATH -u "$windows_path"` 19856 new_path="$unix_path" 19857 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19858 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19859 new_path="$unix_path" 19860 fi 19861 19862 # remove trailing .exe if any 19863 new_path="${new_path/%.exe/}" 19864 19865 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19866 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19867 fi 19868 19869 else 19870 # We're on a posix platform. Hooray! :) 19871 # First separate the path from the arguments. This will split at the first 19872 # space. 19873 complete="$CC" 19874 path="${complete%% *}" 19875 tmp="$complete EOL" 19876 arguments="${tmp#* }" 19877 19878 # Cannot rely on the command "which" here since it doesn't always work. 19879 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19880 if test -z "$is_absolute_path"; then 19881 # Path to executable is not absolute. Find it. 19882 IFS_save="$IFS" 19883 IFS=: 19884 for p in $PATH; do 19885 if test -f "$p/$path" && test -x "$p/$path"; then 19886 new_path="$p/$path" 19887 break 19888 fi 19889 done 19890 IFS="$IFS_save" 19891 else 19892 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CC (as $path) failed, using $path directly." >&5 19893 $as_echo "$as_me: Resolving CC (as $path) failed, using $path directly." >&6;} 19894 new_path="$path" 19895 fi 19896 19897 if test "x$new_path" = x; then 19898 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 19899 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 19900 has_space=`$ECHO "$complete" | $GREP " "` 19901 if test "x$has_space" != x; then 19902 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19903 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19904 fi 19905 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 19906 fi 19907 fi 19908 19909 # Now join together the path and the arguments once again 19910 if test "x$arguments" != xEOL; then 19911 new_complete="$new_path ${arguments% *}" 19912 else 19913 new_complete="$new_path" 19914 fi 19915 19916 if test "x$complete" != "x$new_complete"; then 19917 CC="$new_complete" 19918 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5 19919 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;} 19920 fi 19921 19922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5 19923 $as_echo_n "checking resolved symbolic links for CC... " >&6; } 19924 TEST_COMPILER="$CC" 19925 19926 if test "x$OPENJDK_BUILD_OS" != xwindows; then 19927 # Follow a chain of symbolic links. Use readlink 19928 # where it exists, else fall back to horribly 19929 # complicated shell code. 19930 if test "x$READLINK_TESTED" != yes; then 19931 # On MacOSX there is a readlink tool with a different 19932 # purpose than the GNU readlink tool. Check the found readlink. 19933 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 19934 if test "x$ISGNU" = x; then 19935 # A readlink that we do not know how to use. 19936 # Are there other non-GNU readlinks out there? 19937 READLINK_TESTED=yes 19938 READLINK= 19939 fi 19940 fi 19941 19942 if test "x$READLINK" != x; then 19943 TEST_COMPILER=`$READLINK -f $TEST_COMPILER` 19944 else 19945 # Save the current directory for restoring afterwards 19946 STARTDIR=$PWD 19947 COUNTER=0 19948 sym_link_dir=`$DIRNAME $TEST_COMPILER` 19949 sym_link_file=`$BASENAME $TEST_COMPILER` 19950 # Use the system pwd and not the shell builtin to resolve directory symlinks 19951 cd $sym_link_dir 19952 cd `$THEPWDCMD` 19953 sym_link_dir=`$THEPWDCMD` 19954 # Resolve file symlinks 19955 while test $COUNTER -lt 20; do 19956 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 19957 if test "x$ISLINK" == x; then 19958 # This is not a symbolic link! We are done! 19959 break 19960 fi 19961 # Again resolve directory symlinks since the target of the just found 19962 # link could be in a different directory 19963 cd `$DIRNAME $ISLINK` 19964 sym_link_dir=`$THEPWDCMD` 19965 sym_link_file=`$BASENAME $ISLINK` 19966 let COUNTER=COUNTER+1 19967 done 19968 cd $STARTDIR 19969 TEST_COMPILER=$sym_link_dir/$sym_link_file 19970 fi 19971 fi 19972 19973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5 19974 $as_echo "$TEST_COMPILER" >&6; } 19975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CC is disguised ccache" >&5 19976 $as_echo_n "checking if CC is disguised ccache... " >&6; } 19977 19978 COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"` 19979 if test "x$COMPILER_BASENAME" = "xccache"; then 19980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5 19981 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; } 19982 # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache. 19983 # We want to control ccache invocation ourselves, so ignore this cc and try 19984 # searching again. 19985 19986 # Remove the path to the fake ccache cc from the PATH 19987 RETRY_COMPILER_SAVED_PATH="$PATH" 19988 COMPILER_DIRNAME=`$DIRNAME $CC` 19989 PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`" 19990 19991 # Try again looking for our compiler 19992 if test -n "$ac_tool_prefix"; then 19993 for ac_prog in $COMPILER_CHECK_LIST 19994 do 19995 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 19996 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 19997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19998 $as_echo_n "checking for $ac_word... " >&6; } 19999 if ${ac_cv_prog_PROPER_COMPILER_CC+:} false; then : 20000 $as_echo_n "(cached) " >&6 20001 else 20002 if test -n "$PROPER_COMPILER_CC"; then 20003 ac_cv_prog_PROPER_COMPILER_CC="$PROPER_COMPILER_CC" # Let the user override the test. 20004 else 20005 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20006 for as_dir in $PATH 20007 do 20008 IFS=$as_save_IFS 20009 test -z "$as_dir" && as_dir=. 20010 for ac_exec_ext in '' $ac_executable_extensions; do 20011 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 20012 ac_cv_prog_PROPER_COMPILER_CC="$ac_tool_prefix$ac_prog" 20013 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20014 break 2 20015 fi 20016 done 20017 done 20018 IFS=$as_save_IFS 20019 20020 fi 20021 fi 20022 PROPER_COMPILER_CC=$ac_cv_prog_PROPER_COMPILER_CC 20023 if test -n "$PROPER_COMPILER_CC"; then 20024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5 20025 $as_echo "$PROPER_COMPILER_CC" >&6; } 20026 else 20027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20028 $as_echo "no" >&6; } 20029 fi 20030 20031 20032 test -n "$PROPER_COMPILER_CC" && break 20033 done 20034 fi 20035 if test -z "$PROPER_COMPILER_CC"; then 20036 ac_ct_PROPER_COMPILER_CC=$PROPER_COMPILER_CC 20037 for ac_prog in $COMPILER_CHECK_LIST 20038 do 20039 # Extract the first word of "$ac_prog", so it can be a program name with args. 20040 set dummy $ac_prog; ac_word=$2 20041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20042 $as_echo_n "checking for $ac_word... " >&6; } 20043 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CC+:} false; then : 20044 $as_echo_n "(cached) " >&6 20045 else 20046 if test -n "$ac_ct_PROPER_COMPILER_CC"; then 20047 ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_ct_PROPER_COMPILER_CC" # Let the user override the test. 20048 else 20049 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20050 for as_dir in $PATH 20051 do 20052 IFS=$as_save_IFS 20053 test -z "$as_dir" && as_dir=. 20054 for ac_exec_ext in '' $ac_executable_extensions; do 20055 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 20056 ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_prog" 20057 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20058 break 2 20059 fi 20060 done 20061 done 20062 IFS=$as_save_IFS 20063 20064 fi 20065 fi 20066 ac_ct_PROPER_COMPILER_CC=$ac_cv_prog_ac_ct_PROPER_COMPILER_CC 20067 if test -n "$ac_ct_PROPER_COMPILER_CC"; then 20068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CC" >&5 20069 $as_echo "$ac_ct_PROPER_COMPILER_CC" >&6; } 20070 else 20071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20072 $as_echo "no" >&6; } 20073 fi 20074 20075 20076 test -n "$ac_ct_PROPER_COMPILER_CC" && break 20077 done 20078 20079 if test "x$ac_ct_PROPER_COMPILER_CC" = x; then 20080 PROPER_COMPILER_CC="" 20081 else 20082 case $cross_compiling:$ac_tool_warned in 20083 yes:) 20084 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 20085 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 20086 ac_tool_warned=yes ;; 20087 esac 20088 PROPER_COMPILER_CC=$ac_ct_PROPER_COMPILER_CC 20089 fi 20090 fi 20091 20092 20093 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20094 20095 # First separate the path from the arguments. This will split at the first 20096 # space. 20097 complete="$PROPER_COMPILER_CC" 20098 path="${complete%% *}" 20099 tmp="$complete EOL" 20100 arguments="${tmp#* }" 20101 20102 # Input might be given as Windows format, start by converting to 20103 # unix format. 20104 new_path=`$CYGPATH -u "$path"` 20105 20106 # Now try to locate executable using which 20107 new_path=`$WHICH "$new_path" 2> /dev/null` 20108 # bat and cmd files are not always considered executable in cygwin causing which 20109 # to not find them 20110 if test "x$new_path" = x \ 20111 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20112 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20113 new_path=`$CYGPATH -u "$path"` 20114 fi 20115 if test "x$new_path" = x; then 20116 # Oops. Which didn't find the executable. 20117 # The splitting of arguments from the executable at a space might have been incorrect, 20118 # since paths with space are more likely in Windows. Give it another try with the whole 20119 # argument. 20120 path="$complete" 20121 arguments="EOL" 20122 new_path=`$CYGPATH -u "$path"` 20123 new_path=`$WHICH "$new_path" 2> /dev/null` 20124 # bat and cmd files are not always considered executable in cygwin causing which 20125 # to not find them 20126 if test "x$new_path" = x \ 20127 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20128 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20129 new_path=`$CYGPATH -u "$path"` 20130 fi 20131 if test "x$new_path" = x; then 20132 # It's still not found. Now this is an unrecoverable error. 20133 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5 20134 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;} 20135 has_space=`$ECHO "$complete" | $GREP " "` 20136 if test "x$has_space" != x; then 20137 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20138 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20139 fi 20140 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 20141 fi 20142 fi 20143 20144 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20145 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20146 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20147 # "foo.exe" is OK but "foo" is an error. 20148 # 20149 # This test is therefore slightly more accurate than "test -f" to check for file precense. 20150 # It is also a way to make sure we got the proper file name for the real test later on. 20151 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20152 if test "x$test_shortpath" = x; then 20153 # Short path failed, file does not exist as specified. 20154 # Try adding .exe or .cmd 20155 if test -f "${new_path}.exe"; then 20156 input_to_shortpath="${new_path}.exe" 20157 elif test -f "${new_path}.cmd"; then 20158 input_to_shortpath="${new_path}.cmd" 20159 else 20160 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&5 20161 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&6;} 20162 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20163 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20164 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 20165 fi 20166 else 20167 input_to_shortpath="$new_path" 20168 fi 20169 20170 # Call helper function which possibly converts this using DOS-style short mode. 20171 # If so, the updated path is stored in $new_path. 20172 new_path="$input_to_shortpath" 20173 20174 input_path="$input_to_shortpath" 20175 # Check if we need to convert this using DOS-style short mode. If the path 20176 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20177 # take no chances and rewrite it. 20178 # Note: m4 eats our [], so we need to use [ and ] instead. 20179 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20180 if test "x$has_forbidden_chars" != x; then 20181 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20182 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20183 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20184 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20185 # Going to short mode and back again did indeed matter. Since short mode is 20186 # case insensitive, let's make it lowercase to improve readability. 20187 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20188 # Now convert it back to Unix-stile (cygpath) 20189 input_path=`$CYGPATH -u "$shortmode_path"` 20190 new_path="$input_path" 20191 fi 20192 fi 20193 20194 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20195 if test "x$test_cygdrive_prefix" = x; then 20196 # As a simple fix, exclude /usr/bin since it's not a real path. 20197 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20198 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20199 # a path prefixed by /cygdrive for fixpath to work. 20200 new_path="$CYGWIN_ROOT_PATH$input_path" 20201 fi 20202 fi 20203 20204 # remove trailing .exe if any 20205 new_path="${new_path/%.exe/}" 20206 20207 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20208 20209 # First separate the path from the arguments. This will split at the first 20210 # space. 20211 complete="$PROPER_COMPILER_CC" 20212 path="${complete%% *}" 20213 tmp="$complete EOL" 20214 arguments="${tmp#* }" 20215 20216 # Input might be given as Windows format, start by converting to 20217 # unix format. 20218 new_path="$path" 20219 20220 windows_path="$new_path" 20221 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20222 unix_path=`$CYGPATH -u "$windows_path"` 20223 new_path="$unix_path" 20224 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20225 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20226 new_path="$unix_path" 20227 fi 20228 20229 20230 # Now try to locate executable using which 20231 new_path=`$WHICH "$new_path" 2> /dev/null` 20232 20233 if test "x$new_path" = x; then 20234 # Oops. Which didn't find the executable. 20235 # The splitting of arguments from the executable at a space might have been incorrect, 20236 # since paths with space are more likely in Windows. Give it another try with the whole 20237 # argument. 20238 path="$complete" 20239 arguments="EOL" 20240 new_path="$path" 20241 20242 windows_path="$new_path" 20243 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20244 unix_path=`$CYGPATH -u "$windows_path"` 20245 new_path="$unix_path" 20246 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20247 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20248 new_path="$unix_path" 20249 fi 20250 20251 20252 new_path=`$WHICH "$new_path" 2> /dev/null` 20253 20254 if test "x$new_path" = x; then 20255 # It's still not found. Now this is an unrecoverable error. 20256 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5 20257 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;} 20258 has_space=`$ECHO "$complete" | $GREP " "` 20259 if test "x$has_space" != x; then 20260 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20261 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20262 fi 20263 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 20264 fi 20265 fi 20266 20267 # Now new_path has a complete unix path to the binary 20268 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20269 # Keep paths in /bin as-is, but remove trailing .exe if any 20270 new_path="${new_path/%.exe/}" 20271 # Do not save /bin paths to all_fixpath_prefixes! 20272 else 20273 # Not in mixed or Windows style, start by that. 20274 new_path=`cmd //c echo $new_path` 20275 20276 input_path="$new_path" 20277 # Check if we need to convert this using DOS-style short mode. If the path 20278 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20279 # take no chances and rewrite it. 20280 # Note: m4 eats our [], so we need to use [ and ] instead. 20281 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20282 if test "x$has_forbidden_chars" != x; then 20283 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20284 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20285 fi 20286 20287 # Output is in $new_path 20288 20289 windows_path="$new_path" 20290 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20291 unix_path=`$CYGPATH -u "$windows_path"` 20292 new_path="$unix_path" 20293 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20294 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20295 new_path="$unix_path" 20296 fi 20297 20298 # remove trailing .exe if any 20299 new_path="${new_path/%.exe/}" 20300 20301 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20302 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20303 fi 20304 20305 else 20306 # We're on a posix platform. Hooray! :) 20307 # First separate the path from the arguments. This will split at the first 20308 # space. 20309 complete="$PROPER_COMPILER_CC" 20310 path="${complete%% *}" 20311 tmp="$complete EOL" 20312 arguments="${tmp#* }" 20313 20314 # Cannot rely on the command "which" here since it doesn't always work. 20315 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20316 if test -z "$is_absolute_path"; then 20317 # Path to executable is not absolute. Find it. 20318 IFS_save="$IFS" 20319 IFS=: 20320 for p in $PATH; do 20321 if test -f "$p/$path" && test -x "$p/$path"; then 20322 new_path="$p/$path" 20323 break 20324 fi 20325 done 20326 IFS="$IFS_save" 20327 else 20328 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving PROPER_COMPILER_CC (as $path) failed, using $path directly." >&5 20329 $as_echo "$as_me: Resolving PROPER_COMPILER_CC (as $path) failed, using $path directly." >&6;} 20330 new_path="$path" 20331 fi 20332 20333 if test "x$new_path" = x; then 20334 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5 20335 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;} 20336 has_space=`$ECHO "$complete" | $GREP " "` 20337 if test "x$has_space" != x; then 20338 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20339 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20340 fi 20341 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 20342 fi 20343 fi 20344 20345 # Now join together the path and the arguments once again 20346 if test "x$arguments" != xEOL; then 20347 new_complete="$new_path ${arguments% *}" 20348 else 20349 new_complete="$new_path" 20350 fi 20351 20352 if test "x$complete" != "x$new_complete"; then 20353 PROPER_COMPILER_CC="$new_complete" 20354 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&5 20355 $as_echo "$as_me: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&6;} 20356 fi 20357 20358 PATH="$RETRY_COMPILER_SAVED_PATH" 20359 20360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CC" >&5 20361 $as_echo_n "checking for resolved symbolic links for CC... " >&6; } 20362 20363 if test "x$OPENJDK_BUILD_OS" != xwindows; then 20364 # Follow a chain of symbolic links. Use readlink 20365 # where it exists, else fall back to horribly 20366 # complicated shell code. 20367 if test "x$READLINK_TESTED" != yes; then 20368 # On MacOSX there is a readlink tool with a different 20369 # purpose than the GNU readlink tool. Check the found readlink. 20370 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 20371 if test "x$ISGNU" = x; then 20372 # A readlink that we do not know how to use. 20373 # Are there other non-GNU readlinks out there? 20374 READLINK_TESTED=yes 20375 READLINK= 20376 fi 20377 fi 20378 20379 if test "x$READLINK" != x; then 20380 PROPER_COMPILER_CC=`$READLINK -f $PROPER_COMPILER_CC` 20381 else 20382 # Save the current directory for restoring afterwards 20383 STARTDIR=$PWD 20384 COUNTER=0 20385 sym_link_dir=`$DIRNAME $PROPER_COMPILER_CC` 20386 sym_link_file=`$BASENAME $PROPER_COMPILER_CC` 20387 # Use the system pwd and not the shell builtin to resolve directory symlinks 20388 cd $sym_link_dir 20389 cd `$THEPWDCMD` 20390 sym_link_dir=`$THEPWDCMD` 20391 # Resolve file symlinks 20392 while test $COUNTER -lt 20; do 20393 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 20394 if test "x$ISLINK" == x; then 20395 # This is not a symbolic link! We are done! 20396 break 20397 fi 20398 # Again resolve directory symlinks since the target of the just found 20399 # link could be in a different directory 20400 cd `$DIRNAME $ISLINK` 20401 sym_link_dir=`$THEPWDCMD` 20402 sym_link_file=`$BASENAME $ISLINK` 20403 let COUNTER=COUNTER+1 20404 done 20405 cd $STARTDIR 20406 PROPER_COMPILER_CC=$sym_link_dir/$sym_link_file 20407 fi 20408 fi 20409 20410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5 20411 $as_echo "$PROPER_COMPILER_CC" >&6; } 20412 CC="$PROPER_COMPILER_CC" 20413 else 20414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CC" >&5 20415 $as_echo "no, keeping CC" >&6; } 20416 CC="$TEST_COMPILER" 20417 fi 20418 20419 COMPILER=$CC 20420 COMPILER_NAME=$COMPILER_NAME 20421 20422 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 20423 # Make sure we use the Sun Studio compiler and not gcc on Solaris, which won't work 20424 COMPILER_VERSION_TEST=`$COMPILER -V 2>&1 | $HEAD -n 1` 20425 $ECHO $COMPILER_VERSION_TEST | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 20426 if test $? -ne 0; then 20427 GCC_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1` 20428 20429 { $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 20430 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required Sun Studio compiler." >&6;} 20431 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&5 20432 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&6;} 20433 as_fn_error $? "Sun Studio compiler is required. Try setting --with-tools-dir." "$LINENO" 5 20434 else 20435 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/p"` 20436 COMPILER_VENDOR="Sun Studio" 20437 fi 20438 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 20439 # First line typically looks something like: 20440 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.30319.01 for 80x86 20441 COMPILER_VERSION_TEST=`$COMPILER 2>&1 | $HEAD -n 1` 20442 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*Version \([1-9][0-9.]*\) .*/\1/p"` 20443 COMPILER_VENDOR="Microsoft CL.EXE" 20444 COMPILER_CPU_TEST=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* for \(.*\)$/\1/p"` 20445 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 20446 if test "x$COMPILER_CPU_TEST" != "x80x86"; then 20447 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5 20448 fi 20449 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 20450 if test "x$COMPILER_CPU_TEST" != "xx64"; then 20451 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 20452 fi 20453 fi 20454 else 20455 COMPILER_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1` 20456 # Check that this is likely to be GCC. 20457 $COMPILER --version 2>&1 | $GREP "Free Software Foundation" > /dev/null 20458 if test $? -ne 0; then 20459 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&5 20460 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&6;} 20461 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&5 20462 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&6;} 20463 as_fn_error $? "GCC compiler is required. Try setting --with-tools-dir." "$LINENO" 5 20464 fi 20465 20466 # First line typically looks something like: 20467 # gcc (Ubuntu/Linaro 4.5.2-8ubuntu4) 4.5.2 20468 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* \([1-9][0-9.]*\)/\1/p"` 20469 COMPILER_VENDOR=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^\(.*\) [1-9][0-9.]*/\1/p"` 20470 fi 20471 # This sets CC_VERSION or CXX_VERSION. (This comment is a grep marker) 20472 CC_VERSION="$COMPILER_VERSION" 20473 # This sets CC_VENDOR or CXX_VENDOR. (This comment is a grep marker) 20474 CC_VENDOR="$COMPILER_VENDOR" 20475 20476 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&5 20477 $as_echo "$as_me: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&6;} 20478 20479 20480 # Now that we have resolved CC ourself, let autoconf have its go at it 20481 ac_ext=c 20482 ac_cpp='$CPP $CPPFLAGS' 20483 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 20484 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 20485 ac_compiler_gnu=$ac_cv_c_compiler_gnu 20486 if test -n "$ac_tool_prefix"; then 20487 for ac_prog in $CC 20488 do 20489 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 20490 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 20491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20492 $as_echo_n "checking for $ac_word... " >&6; } 20493 if ${ac_cv_prog_CC+:} false; then : 20494 $as_echo_n "(cached) " >&6 20495 else 20496 if test -n "$CC"; then 20497 ac_cv_prog_CC="$CC" # Let the user override the test. 20498 else 20499 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20500 for as_dir in $PATH 20501 do 20502 IFS=$as_save_IFS 20503 test -z "$as_dir" && as_dir=. 20504 for ac_exec_ext in '' $ac_executable_extensions; do 20505 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 20506 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 20507 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20508 break 2 20509 fi 20510 done 20511 done 20512 IFS=$as_save_IFS 20513 20514 fi 20515 fi 20516 CC=$ac_cv_prog_CC 20517 if test -n "$CC"; then 20518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 20519 $as_echo "$CC" >&6; } 20520 else 20521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20522 $as_echo "no" >&6; } 20523 fi 20524 20525 20526 test -n "$CC" && break 20527 done 20528 fi 20529 if test -z "$CC"; then 20530 ac_ct_CC=$CC 20531 for ac_prog in $CC 20532 do 20533 # Extract the first word of "$ac_prog", so it can be a program name with args. 20534 set dummy $ac_prog; ac_word=$2 20535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20536 $as_echo_n "checking for $ac_word... " >&6; } 20537 if ${ac_cv_prog_ac_ct_CC+:} false; then : 20538 $as_echo_n "(cached) " >&6 20539 else 20540 if test -n "$ac_ct_CC"; then 20541 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 20542 else 20543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20544 for as_dir in $PATH 20545 do 20546 IFS=$as_save_IFS 20547 test -z "$as_dir" && as_dir=. 20548 for ac_exec_ext in '' $ac_executable_extensions; do 20549 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 20550 ac_cv_prog_ac_ct_CC="$ac_prog" 20551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20552 break 2 20553 fi 20554 done 20555 done 20556 IFS=$as_save_IFS 20557 20558 fi 20559 fi 20560 ac_ct_CC=$ac_cv_prog_ac_ct_CC 20561 if test -n "$ac_ct_CC"; then 20562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 20563 $as_echo "$ac_ct_CC" >&6; } 20564 else 20565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20566 $as_echo "no" >&6; } 20567 fi 20568 20569 20570 test -n "$ac_ct_CC" && break 20571 done 20572 20573 if test "x$ac_ct_CC" = x; then 20574 CC="" 20575 else 20576 case $cross_compiling:$ac_tool_warned in 20577 yes:) 20578 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 20579 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 20580 ac_tool_warned=yes ;; 20581 esac 20582 CC=$ac_ct_CC 20583 fi 20584 fi 20585 20586 20587 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20588 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 20589 as_fn_error $? "no acceptable C compiler found in \$PATH 20590 See \`config.log' for more details" "$LINENO" 5; } 20591 20592 # Provide some information about the compiler. 20593 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 20594 set X $ac_compile 20595 ac_compiler=$2 20596 for ac_option in --version -v -V -qversion; do 20597 { { ac_try="$ac_compiler $ac_option >&5" 20598 case "(($ac_try" in 20599 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 20600 *) ac_try_echo=$ac_try;; 20601 esac 20602 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 20603 $as_echo "$ac_try_echo"; } >&5 20604 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 20605 ac_status=$? 20606 if test -s conftest.err; then 20607 sed '10a\ 20608 ... rest of stderr output deleted ... 20609 10q' conftest.err >conftest.er1 20610 cat conftest.er1 >&5 20611 fi 20612 rm -f conftest.er1 conftest.err 20613 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 20614 test $ac_status = 0; } 20615 done 20616 20617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 20618 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 20619 if ${ac_cv_c_compiler_gnu+:} false; then : 20620 $as_echo_n "(cached) " >&6 20621 else 20622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20623 /* end confdefs.h. */ 20624 20625 int 20626 main () 20627 { 20628 #ifndef __GNUC__ 20629 choke me 20630 #endif 20631 20632 ; 20633 return 0; 20634 } 20635 _ACEOF 20636 if ac_fn_c_try_compile "$LINENO"; then : 20637 ac_compiler_gnu=yes 20638 else 20639 ac_compiler_gnu=no 20640 fi 20641 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 20642 ac_cv_c_compiler_gnu=$ac_compiler_gnu 20643 20644 fi 20645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 20646 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 20647 if test $ac_compiler_gnu = yes; then 20648 GCC=yes 20649 else 20650 GCC= 20651 fi 20652 ac_test_CFLAGS=${CFLAGS+set} 20653 ac_save_CFLAGS=$CFLAGS 20654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 20655 $as_echo_n "checking whether $CC accepts -g... " >&6; } 20656 if ${ac_cv_prog_cc_g+:} false; then : 20657 $as_echo_n "(cached) " >&6 20658 else 20659 ac_save_c_werror_flag=$ac_c_werror_flag 20660 ac_c_werror_flag=yes 20661 ac_cv_prog_cc_g=no 20662 CFLAGS="-g" 20663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20664 /* end confdefs.h. */ 20665 20666 int 20667 main () 20668 { 20669 20670 ; 20671 return 0; 20672 } 20673 _ACEOF 20674 if ac_fn_c_try_compile "$LINENO"; then : 20675 ac_cv_prog_cc_g=yes 20676 else 20677 CFLAGS="" 20678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20679 /* end confdefs.h. */ 20680 20681 int 20682 main () 20683 { 20684 20685 ; 20686 return 0; 20687 } 20688 _ACEOF 20689 if ac_fn_c_try_compile "$LINENO"; then : 20690 20691 else 20692 ac_c_werror_flag=$ac_save_c_werror_flag 20693 CFLAGS="-g" 20694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20695 /* end confdefs.h. */ 20696 20697 int 20698 main () 20699 { 20700 20701 ; 20702 return 0; 20703 } 20704 _ACEOF 20705 if ac_fn_c_try_compile "$LINENO"; then : 20706 ac_cv_prog_cc_g=yes 20707 fi 20708 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 20709 fi 20710 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 20711 fi 20712 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 20713 ac_c_werror_flag=$ac_save_c_werror_flag 20714 fi 20715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 20716 $as_echo "$ac_cv_prog_cc_g" >&6; } 20717 if test "$ac_test_CFLAGS" = set; then 20718 CFLAGS=$ac_save_CFLAGS 20719 elif test $ac_cv_prog_cc_g = yes; then 20720 if test "$GCC" = yes; then 20721 CFLAGS="-g -O2" 20722 else 20723 CFLAGS="-g" 20724 fi 20725 else 20726 if test "$GCC" = yes; then 20727 CFLAGS="-O2" 20728 else 20729 CFLAGS= 20730 fi 20731 fi 20732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 20733 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 20734 if ${ac_cv_prog_cc_c89+:} false; then : 20735 $as_echo_n "(cached) " >&6 20736 else 20737 ac_cv_prog_cc_c89=no 20738 ac_save_CC=$CC 20739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20740 /* end confdefs.h. */ 20741 #include <stdarg.h> 20742 #include <stdio.h> 20743 #include <sys/types.h> 20744 #include <sys/stat.h> 20745 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 20746 struct buf { int x; }; 20747 FILE * (*rcsopen) (struct buf *, struct stat *, int); 20748 static char *e (p, i) 20749 char **p; 20750 int i; 20751 { 20752 return p[i]; 20753 } 20754 static char *f (char * (*g) (char **, int), char **p, ...) 20755 { 20756 char *s; 20757 va_list v; 20758 va_start (v,p); 20759 s = g (p, va_arg (v,int)); 20760 va_end (v); 20761 return s; 20762 } 20763 20764 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 20765 function prototypes and stuff, but not '\xHH' hex character constants. 20766 These don't provoke an error unfortunately, instead are silently treated 20767 as 'x'. The following induces an error, until -std is added to get 20768 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 20769 array size at least. It's necessary to write '\x00'==0 to get something 20770 that's true only with -std. */ 20771 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 20772 20773 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 20774 inside strings and character constants. */ 20775 #define FOO(x) 'x' 20776 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 20777 20778 int test (int i, double x); 20779 struct s1 {int (*f) (int a);}; 20780 struct s2 {int (*f) (double a);}; 20781 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 20782 int argc; 20783 char **argv; 20784 int 20785 main () 20786 { 20787 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 20788 ; 20789 return 0; 20790 } 20791 _ACEOF 20792 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 20793 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 20794 do 20795 CC="$ac_save_CC $ac_arg" 20796 if ac_fn_c_try_compile "$LINENO"; then : 20797 ac_cv_prog_cc_c89=$ac_arg 20798 fi 20799 rm -f core conftest.err conftest.$ac_objext 20800 test "x$ac_cv_prog_cc_c89" != "xno" && break 20801 done 20802 rm -f conftest.$ac_ext 20803 CC=$ac_save_CC 20804 20805 fi 20806 # AC_CACHE_VAL 20807 case "x$ac_cv_prog_cc_c89" in 20808 x) 20809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 20810 $as_echo "none needed" >&6; } ;; 20811 xno) 20812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 20813 $as_echo "unsupported" >&6; } ;; 20814 *) 20815 CC="$CC $ac_cv_prog_cc_c89" 20816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 20817 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 20818 esac 20819 if test "x$ac_cv_prog_cc_c89" != xno; then : 20820 20821 fi 20822 20823 ac_ext=cpp 20824 ac_cpp='$CXXCPP $CPPFLAGS' 20825 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 20826 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 20827 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 20828 20829 20830 ### Locate C++ compiler (CXX) 20831 20832 if test "x$CXX" != x; then 20833 COMPILER_CHECK_LIST="$CXX" 20834 elif test "x$OPENJDK_TARGET_OS" = "xwindows"; then 20835 COMPILER_CHECK_LIST="cl" 20836 elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 20837 COMPILER_CHECK_LIST="CC g++" 20838 else 20839 COMPILER_CHECK_LIST="g++ CC" 20840 fi 20841 20842 20843 COMPILER_NAME=C++ 20844 20845 CXX= 20846 # If TOOLS_DIR is set, check for all compiler names in there first 20847 # before checking the rest of the PATH. 20848 if test -n "$TOOLS_DIR"; then 20849 PATH_save="$PATH" 20850 PATH="$TOOLS_DIR" 20851 for ac_prog in $COMPILER_CHECK_LIST 20852 do 20853 # Extract the first word of "$ac_prog", so it can be a program name with args. 20854 set dummy $ac_prog; ac_word=$2 20855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20856 $as_echo_n "checking for $ac_word... " >&6; } 20857 if ${ac_cv_path_TOOLS_DIR_CXX+:} false; then : 20858 $as_echo_n "(cached) " >&6 20859 else 20860 case $TOOLS_DIR_CXX in 20861 [\\/]* | ?:[\\/]*) 20862 ac_cv_path_TOOLS_DIR_CXX="$TOOLS_DIR_CXX" # Let the user override the test with a path. 20863 ;; 20864 *) 20865 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20866 for as_dir in $PATH 20867 do 20868 IFS=$as_save_IFS 20869 test -z "$as_dir" && as_dir=. 20870 for ac_exec_ext in '' $ac_executable_extensions; do 20871 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 20872 ac_cv_path_TOOLS_DIR_CXX="$as_dir/$ac_word$ac_exec_ext" 20873 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20874 break 2 20875 fi 20876 done 20877 done 20878 IFS=$as_save_IFS 20879 20880 ;; 20881 esac 20882 fi 20883 TOOLS_DIR_CXX=$ac_cv_path_TOOLS_DIR_CXX 20884 if test -n "$TOOLS_DIR_CXX"; then 20885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CXX" >&5 20886 $as_echo "$TOOLS_DIR_CXX" >&6; } 20887 else 20888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20889 $as_echo "no" >&6; } 20890 fi 20891 20892 20893 test -n "$TOOLS_DIR_CXX" && break 20894 done 20895 20896 CXX=$TOOLS_DIR_CXX 20897 PATH="$PATH_save" 20898 fi 20899 20900 # AC_PATH_PROGS can't be run multiple times with the same variable, 20901 # so create a new name for this run. 20902 if test "x$CXX" = x; then 20903 for ac_prog in $COMPILER_CHECK_LIST 20904 do 20905 # Extract the first word of "$ac_prog", so it can be a program name with args. 20906 set dummy $ac_prog; ac_word=$2 20907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20908 $as_echo_n "checking for $ac_word... " >&6; } 20909 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 20910 $as_echo_n "(cached) " >&6 20911 else 20912 case $POTENTIAL_CXX in 20913 [\\/]* | ?:[\\/]*) 20914 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 20915 ;; 20916 *) 20917 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20918 for as_dir in $PATH 20919 do 20920 IFS=$as_save_IFS 20921 test -z "$as_dir" && as_dir=. 20922 for ac_exec_ext in '' $ac_executable_extensions; do 20923 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 20924 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 20925 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20926 break 2 20927 fi 20928 done 20929 done 20930 IFS=$as_save_IFS 20931 20932 ;; 20933 esac 20934 fi 20935 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 20936 if test -n "$POTENTIAL_CXX"; then 20937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 20938 $as_echo "$POTENTIAL_CXX" >&6; } 20939 else 20940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20941 $as_echo "no" >&6; } 20942 fi 20943 20944 20945 test -n "$POTENTIAL_CXX" && break 20946 done 20947 20948 CXX=$POTENTIAL_CXX 20949 fi 20950 20951 if test "x$CXX" = x; then 20952 20953 # Print a helpful message on how to acquire the necessary build dependency. 20954 # devkit is the help tag: freetyp2, cups, pulse, alsa etc 20955 MISSING_DEPENDENCY=devkit 20956 PKGHANDLER_COMMAND= 20957 20958 case $PKGHANDLER in 20959 apt-get) 20960 apt_help $MISSING_DEPENDENCY ;; 20961 yum) 20962 yum_help $MISSING_DEPENDENCY ;; 20963 port) 20964 port_help $MISSING_DEPENDENCY ;; 20965 pkgutil) 20966 pkgutil_help $MISSING_DEPENDENCY ;; 20967 pkgadd) 20968 pkgadd_help $MISSING_DEPENDENCY ;; 20969 * ) 20970 break ;; 20971 esac 20972 20973 if test "x$PKGHANDLER_COMMAND" != x; then 20974 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 20975 fi 20976 20977 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 20978 fi 20979 20980 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20981 20982 # First separate the path from the arguments. This will split at the first 20983 # space. 20984 complete="$CXX" 20985 path="${complete%% *}" 20986 tmp="$complete EOL" 20987 arguments="${tmp#* }" 20988 20989 # Input might be given as Windows format, start by converting to 20990 # unix format. 20991 new_path=`$CYGPATH -u "$path"` 20992 20993 # Now try to locate executable using which 20994 new_path=`$WHICH "$new_path" 2> /dev/null` 20995 # bat and cmd files are not always considered executable in cygwin causing which 20996 # to not find them 20997 if test "x$new_path" = x \ 20998 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20999 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21000 new_path=`$CYGPATH -u "$path"` 21001 fi 21002 if test "x$new_path" = x; then 21003 # Oops. Which didn't find the executable. 21004 # The splitting of arguments from the executable at a space might have been incorrect, 21005 # since paths with space are more likely in Windows. Give it another try with the whole 21006 # argument. 21007 path="$complete" 21008 arguments="EOL" 21009 new_path=`$CYGPATH -u "$path"` 21010 new_path=`$WHICH "$new_path" 2> /dev/null` 21011 # bat and cmd files are not always considered executable in cygwin causing which 21012 # to not find them 21013 if test "x$new_path" = x \ 21014 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21015 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21016 new_path=`$CYGPATH -u "$path"` 21017 fi 21018 if test "x$new_path" = x; then 21019 # It's still not found. Now this is an unrecoverable error. 21020 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 21021 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 21022 has_space=`$ECHO "$complete" | $GREP " "` 21023 if test "x$has_space" != x; then 21024 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21025 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21026 fi 21027 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 21028 fi 21029 fi 21030 21031 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 21032 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 21033 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 21034 # "foo.exe" is OK but "foo" is an error. 21035 # 21036 # This test is therefore slightly more accurate than "test -f" to check for file precense. 21037 # It is also a way to make sure we got the proper file name for the real test later on. 21038 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 21039 if test "x$test_shortpath" = x; then 21040 # Short path failed, file does not exist as specified. 21041 # Try adding .exe or .cmd 21042 if test -f "${new_path}.exe"; then 21043 input_to_shortpath="${new_path}.exe" 21044 elif test -f "${new_path}.cmd"; then 21045 input_to_shortpath="${new_path}.cmd" 21046 else 21047 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5 21048 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;} 21049 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 21050 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 21051 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 21052 fi 21053 else 21054 input_to_shortpath="$new_path" 21055 fi 21056 21057 # Call helper function which possibly converts this using DOS-style short mode. 21058 # If so, the updated path is stored in $new_path. 21059 new_path="$input_to_shortpath" 21060 21061 input_path="$input_to_shortpath" 21062 # Check if we need to convert this using DOS-style short mode. If the path 21063 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21064 # take no chances and rewrite it. 21065 # Note: m4 eats our [], so we need to use [ and ] instead. 21066 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 21067 if test "x$has_forbidden_chars" != x; then 21068 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21069 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 21070 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 21071 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 21072 # Going to short mode and back again did indeed matter. Since short mode is 21073 # case insensitive, let's make it lowercase to improve readability. 21074 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21075 # Now convert it back to Unix-stile (cygpath) 21076 input_path=`$CYGPATH -u "$shortmode_path"` 21077 new_path="$input_path" 21078 fi 21079 fi 21080 21081 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 21082 if test "x$test_cygdrive_prefix" = x; then 21083 # As a simple fix, exclude /usr/bin since it's not a real path. 21084 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 21085 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 21086 # a path prefixed by /cygdrive for fixpath to work. 21087 new_path="$CYGWIN_ROOT_PATH$input_path" 21088 fi 21089 fi 21090 21091 # remove trailing .exe if any 21092 new_path="${new_path/%.exe/}" 21093 21094 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21095 21096 # First separate the path from the arguments. This will split at the first 21097 # space. 21098 complete="$CXX" 21099 path="${complete%% *}" 21100 tmp="$complete EOL" 21101 arguments="${tmp#* }" 21102 21103 # Input might be given as Windows format, start by converting to 21104 # unix format. 21105 new_path="$path" 21106 21107 windows_path="$new_path" 21108 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21109 unix_path=`$CYGPATH -u "$windows_path"` 21110 new_path="$unix_path" 21111 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21112 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21113 new_path="$unix_path" 21114 fi 21115 21116 21117 # Now try to locate executable using which 21118 new_path=`$WHICH "$new_path" 2> /dev/null` 21119 21120 if test "x$new_path" = x; then 21121 # Oops. Which didn't find the executable. 21122 # The splitting of arguments from the executable at a space might have been incorrect, 21123 # since paths with space are more likely in Windows. Give it another try with the whole 21124 # argument. 21125 path="$complete" 21126 arguments="EOL" 21127 new_path="$path" 21128 21129 windows_path="$new_path" 21130 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21131 unix_path=`$CYGPATH -u "$windows_path"` 21132 new_path="$unix_path" 21133 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21134 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21135 new_path="$unix_path" 21136 fi 21137 21138 21139 new_path=`$WHICH "$new_path" 2> /dev/null` 21140 21141 if test "x$new_path" = x; then 21142 # It's still not found. Now this is an unrecoverable error. 21143 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 21144 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 21145 has_space=`$ECHO "$complete" | $GREP " "` 21146 if test "x$has_space" != x; then 21147 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21148 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21149 fi 21150 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 21151 fi 21152 fi 21153 21154 # Now new_path has a complete unix path to the binary 21155 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 21156 # Keep paths in /bin as-is, but remove trailing .exe if any 21157 new_path="${new_path/%.exe/}" 21158 # Do not save /bin paths to all_fixpath_prefixes! 21159 else 21160 # Not in mixed or Windows style, start by that. 21161 new_path=`cmd //c echo $new_path` 21162 21163 input_path="$new_path" 21164 # Check if we need to convert this using DOS-style short mode. If the path 21165 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21166 # take no chances and rewrite it. 21167 # Note: m4 eats our [], so we need to use [ and ] instead. 21168 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 21169 if test "x$has_forbidden_chars" != x; then 21170 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21171 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21172 fi 21173 21174 # Output is in $new_path 21175 21176 windows_path="$new_path" 21177 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21178 unix_path=`$CYGPATH -u "$windows_path"` 21179 new_path="$unix_path" 21180 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21181 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21182 new_path="$unix_path" 21183 fi 21184 21185 # remove trailing .exe if any 21186 new_path="${new_path/%.exe/}" 21187 21188 # Save the first 10 bytes of this path to the storage, so fixpath can work. 21189 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21190 fi 21191 21192 else 21193 # We're on a posix platform. Hooray! :) 21194 # First separate the path from the arguments. This will split at the first 21195 # space. 21196 complete="$CXX" 21197 path="${complete%% *}" 21198 tmp="$complete EOL" 21199 arguments="${tmp#* }" 21200 21201 # Cannot rely on the command "which" here since it doesn't always work. 21202 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21203 if test -z "$is_absolute_path"; then 21204 # Path to executable is not absolute. Find it. 21205 IFS_save="$IFS" 21206 IFS=: 21207 for p in $PATH; do 21208 if test -f "$p/$path" && test -x "$p/$path"; then 21209 new_path="$p/$path" 21210 break 21211 fi 21212 done 21213 IFS="$IFS_save" 21214 else 21215 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CXX (as $path) failed, using $path directly." >&5 21216 $as_echo "$as_me: Resolving CXX (as $path) failed, using $path directly." >&6;} 21217 new_path="$path" 21218 fi 21219 21220 if test "x$new_path" = x; then 21221 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 21222 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 21223 has_space=`$ECHO "$complete" | $GREP " "` 21224 if test "x$has_space" != x; then 21225 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21226 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21227 fi 21228 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 21229 fi 21230 fi 21231 21232 # Now join together the path and the arguments once again 21233 if test "x$arguments" != xEOL; then 21234 new_complete="$new_path ${arguments% *}" 21235 else 21236 new_complete="$new_path" 21237 fi 21238 21239 if test "x$complete" != "x$new_complete"; then 21240 CXX="$new_complete" 21241 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5 21242 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;} 21243 fi 21244 21245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5 21246 $as_echo_n "checking resolved symbolic links for CXX... " >&6; } 21247 TEST_COMPILER="$CXX" 21248 21249 if test "x$OPENJDK_BUILD_OS" != xwindows; then 21250 # Follow a chain of symbolic links. Use readlink 21251 # where it exists, else fall back to horribly 21252 # complicated shell code. 21253 if test "x$READLINK_TESTED" != yes; then 21254 # On MacOSX there is a readlink tool with a different 21255 # purpose than the GNU readlink tool. Check the found readlink. 21256 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 21257 if test "x$ISGNU" = x; then 21258 # A readlink that we do not know how to use. 21259 # Are there other non-GNU readlinks out there? 21260 READLINK_TESTED=yes 21261 READLINK= 21262 fi 21263 fi 21264 21265 if test "x$READLINK" != x; then 21266 TEST_COMPILER=`$READLINK -f $TEST_COMPILER` 21267 else 21268 # Save the current directory for restoring afterwards 21269 STARTDIR=$PWD 21270 COUNTER=0 21271 sym_link_dir=`$DIRNAME $TEST_COMPILER` 21272 sym_link_file=`$BASENAME $TEST_COMPILER` 21273 # Use the system pwd and not the shell builtin to resolve directory symlinks 21274 cd $sym_link_dir 21275 cd `$THEPWDCMD` 21276 sym_link_dir=`$THEPWDCMD` 21277 # Resolve file symlinks 21278 while test $COUNTER -lt 20; do 21279 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 21280 if test "x$ISLINK" == x; then 21281 # This is not a symbolic link! We are done! 21282 break 21283 fi 21284 # Again resolve directory symlinks since the target of the just found 21285 # link could be in a different directory 21286 cd `$DIRNAME $ISLINK` 21287 sym_link_dir=`$THEPWDCMD` 21288 sym_link_file=`$BASENAME $ISLINK` 21289 let COUNTER=COUNTER+1 21290 done 21291 cd $STARTDIR 21292 TEST_COMPILER=$sym_link_dir/$sym_link_file 21293 fi 21294 fi 21295 21296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5 21297 $as_echo "$TEST_COMPILER" >&6; } 21298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CXX is disguised ccache" >&5 21299 $as_echo_n "checking if CXX is disguised ccache... " >&6; } 21300 21301 COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"` 21302 if test "x$COMPILER_BASENAME" = "xccache"; then 21303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5 21304 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; } 21305 # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache. 21306 # We want to control ccache invocation ourselves, so ignore this cc and try 21307 # searching again. 21308 21309 # Remove the path to the fake ccache cc from the PATH 21310 RETRY_COMPILER_SAVED_PATH="$PATH" 21311 COMPILER_DIRNAME=`$DIRNAME $CXX` 21312 PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`" 21313 21314 # Try again looking for our compiler 21315 if test -n "$ac_tool_prefix"; then 21316 for ac_prog in $COMPILER_CHECK_LIST 21317 do 21318 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 21319 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 21320 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21321 $as_echo_n "checking for $ac_word... " >&6; } 21322 if ${ac_cv_prog_PROPER_COMPILER_CXX+:} false; then : 21323 $as_echo_n "(cached) " >&6 21324 else 21325 if test -n "$PROPER_COMPILER_CXX"; then 21326 ac_cv_prog_PROPER_COMPILER_CXX="$PROPER_COMPILER_CXX" # Let the user override the test. 21327 else 21328 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21329 for as_dir in $PATH 21330 do 21331 IFS=$as_save_IFS 21332 test -z "$as_dir" && as_dir=. 21333 for ac_exec_ext in '' $ac_executable_extensions; do 21334 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 21335 ac_cv_prog_PROPER_COMPILER_CXX="$ac_tool_prefix$ac_prog" 21336 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21337 break 2 21338 fi 21339 done 21340 done 21341 IFS=$as_save_IFS 21342 21343 fi 21344 fi 21345 PROPER_COMPILER_CXX=$ac_cv_prog_PROPER_COMPILER_CXX 21346 if test -n "$PROPER_COMPILER_CXX"; then 21347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5 21348 $as_echo "$PROPER_COMPILER_CXX" >&6; } 21349 else 21350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21351 $as_echo "no" >&6; } 21352 fi 21353 21354 21355 test -n "$PROPER_COMPILER_CXX" && break 21356 done 21357 fi 21358 if test -z "$PROPER_COMPILER_CXX"; then 21359 ac_ct_PROPER_COMPILER_CXX=$PROPER_COMPILER_CXX 21360 for ac_prog in $COMPILER_CHECK_LIST 21361 do 21362 # Extract the first word of "$ac_prog", so it can be a program name with args. 21363 set dummy $ac_prog; ac_word=$2 21364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21365 $as_echo_n "checking for $ac_word... " >&6; } 21366 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CXX+:} false; then : 21367 $as_echo_n "(cached) " >&6 21368 else 21369 if test -n "$ac_ct_PROPER_COMPILER_CXX"; then 21370 ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_ct_PROPER_COMPILER_CXX" # Let the user override the test. 21371 else 21372 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21373 for as_dir in $PATH 21374 do 21375 IFS=$as_save_IFS 21376 test -z "$as_dir" && as_dir=. 21377 for ac_exec_ext in '' $ac_executable_extensions; do 21378 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 21379 ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_prog" 21380 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21381 break 2 21382 fi 21383 done 21384 done 21385 IFS=$as_save_IFS 21386 21387 fi 21388 fi 21389 ac_ct_PROPER_COMPILER_CXX=$ac_cv_prog_ac_ct_PROPER_COMPILER_CXX 21390 if test -n "$ac_ct_PROPER_COMPILER_CXX"; then 21391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CXX" >&5 21392 $as_echo "$ac_ct_PROPER_COMPILER_CXX" >&6; } 21393 else 21394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21395 $as_echo "no" >&6; } 21396 fi 21397 21398 21399 test -n "$ac_ct_PROPER_COMPILER_CXX" && break 21400 done 21401 21402 if test "x$ac_ct_PROPER_COMPILER_CXX" = x; then 21403 PROPER_COMPILER_CXX="" 21404 else 21405 case $cross_compiling:$ac_tool_warned in 21406 yes:) 21407 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 21408 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 21409 ac_tool_warned=yes ;; 21410 esac 21411 PROPER_COMPILER_CXX=$ac_ct_PROPER_COMPILER_CXX 21412 fi 21413 fi 21414 21415 21416 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21417 21418 # First separate the path from the arguments. This will split at the first 21419 # space. 21420 complete="$PROPER_COMPILER_CXX" 21421 path="${complete%% *}" 21422 tmp="$complete EOL" 21423 arguments="${tmp#* }" 21424 21425 # Input might be given as Windows format, start by converting to 21426 # unix format. 21427 new_path=`$CYGPATH -u "$path"` 21428 21429 # Now try to locate executable using which 21430 new_path=`$WHICH "$new_path" 2> /dev/null` 21431 # bat and cmd files are not always considered executable in cygwin causing which 21432 # to not find them 21433 if test "x$new_path" = x \ 21434 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21435 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21436 new_path=`$CYGPATH -u "$path"` 21437 fi 21438 if test "x$new_path" = x; then 21439 # Oops. Which didn't find the executable. 21440 # The splitting of arguments from the executable at a space might have been incorrect, 21441 # since paths with space are more likely in Windows. Give it another try with the whole 21442 # argument. 21443 path="$complete" 21444 arguments="EOL" 21445 new_path=`$CYGPATH -u "$path"` 21446 new_path=`$WHICH "$new_path" 2> /dev/null` 21447 # bat and cmd files are not always considered executable in cygwin causing which 21448 # to not find them 21449 if test "x$new_path" = x \ 21450 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21451 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21452 new_path=`$CYGPATH -u "$path"` 21453 fi 21454 if test "x$new_path" = x; then 21455 # It's still not found. Now this is an unrecoverable error. 21456 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5 21457 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;} 21458 has_space=`$ECHO "$complete" | $GREP " "` 21459 if test "x$has_space" != x; then 21460 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21461 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21462 fi 21463 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 21464 fi 21465 fi 21466 21467 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 21468 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 21469 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 21470 # "foo.exe" is OK but "foo" is an error. 21471 # 21472 # This test is therefore slightly more accurate than "test -f" to check for file precense. 21473 # It is also a way to make sure we got the proper file name for the real test later on. 21474 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 21475 if test "x$test_shortpath" = x; then 21476 # Short path failed, file does not exist as specified. 21477 # Try adding .exe or .cmd 21478 if test -f "${new_path}.exe"; then 21479 input_to_shortpath="${new_path}.exe" 21480 elif test -f "${new_path}.cmd"; then 21481 input_to_shortpath="${new_path}.cmd" 21482 else 21483 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&5 21484 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&6;} 21485 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 21486 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 21487 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 21488 fi 21489 else 21490 input_to_shortpath="$new_path" 21491 fi 21492 21493 # Call helper function which possibly converts this using DOS-style short mode. 21494 # If so, the updated path is stored in $new_path. 21495 new_path="$input_to_shortpath" 21496 21497 input_path="$input_to_shortpath" 21498 # Check if we need to convert this using DOS-style short mode. If the path 21499 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21500 # take no chances and rewrite it. 21501 # Note: m4 eats our [], so we need to use [ and ] instead. 21502 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 21503 if test "x$has_forbidden_chars" != x; then 21504 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21505 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 21506 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 21507 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 21508 # Going to short mode and back again did indeed matter. Since short mode is 21509 # case insensitive, let's make it lowercase to improve readability. 21510 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21511 # Now convert it back to Unix-stile (cygpath) 21512 input_path=`$CYGPATH -u "$shortmode_path"` 21513 new_path="$input_path" 21514 fi 21515 fi 21516 21517 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 21518 if test "x$test_cygdrive_prefix" = x; then 21519 # As a simple fix, exclude /usr/bin since it's not a real path. 21520 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 21521 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 21522 # a path prefixed by /cygdrive for fixpath to work. 21523 new_path="$CYGWIN_ROOT_PATH$input_path" 21524 fi 21525 fi 21526 21527 # remove trailing .exe if any 21528 new_path="${new_path/%.exe/}" 21529 21530 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21531 21532 # First separate the path from the arguments. This will split at the first 21533 # space. 21534 complete="$PROPER_COMPILER_CXX" 21535 path="${complete%% *}" 21536 tmp="$complete EOL" 21537 arguments="${tmp#* }" 21538 21539 # Input might be given as Windows format, start by converting to 21540 # unix format. 21541 new_path="$path" 21542 21543 windows_path="$new_path" 21544 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21545 unix_path=`$CYGPATH -u "$windows_path"` 21546 new_path="$unix_path" 21547 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21548 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21549 new_path="$unix_path" 21550 fi 21551 21552 21553 # Now try to locate executable using which 21554 new_path=`$WHICH "$new_path" 2> /dev/null` 21555 21556 if test "x$new_path" = x; then 21557 # Oops. Which didn't find the executable. 21558 # The splitting of arguments from the executable at a space might have been incorrect, 21559 # since paths with space are more likely in Windows. Give it another try with the whole 21560 # argument. 21561 path="$complete" 21562 arguments="EOL" 21563 new_path="$path" 21564 21565 windows_path="$new_path" 21566 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21567 unix_path=`$CYGPATH -u "$windows_path"` 21568 new_path="$unix_path" 21569 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21570 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21571 new_path="$unix_path" 21572 fi 21573 21574 21575 new_path=`$WHICH "$new_path" 2> /dev/null` 21576 21577 if test "x$new_path" = x; then 21578 # It's still not found. Now this is an unrecoverable error. 21579 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5 21580 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;} 21581 has_space=`$ECHO "$complete" | $GREP " "` 21582 if test "x$has_space" != x; then 21583 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21584 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21585 fi 21586 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 21587 fi 21588 fi 21589 21590 # Now new_path has a complete unix path to the binary 21591 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 21592 # Keep paths in /bin as-is, but remove trailing .exe if any 21593 new_path="${new_path/%.exe/}" 21594 # Do not save /bin paths to all_fixpath_prefixes! 21595 else 21596 # Not in mixed or Windows style, start by that. 21597 new_path=`cmd //c echo $new_path` 21598 21599 input_path="$new_path" 21600 # Check if we need to convert this using DOS-style short mode. If the path 21601 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21602 # take no chances and rewrite it. 21603 # Note: m4 eats our [], so we need to use [ and ] instead. 21604 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 21605 if test "x$has_forbidden_chars" != x; then 21606 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21607 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21608 fi 21609 21610 # Output is in $new_path 21611 21612 windows_path="$new_path" 21613 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21614 unix_path=`$CYGPATH -u "$windows_path"` 21615 new_path="$unix_path" 21616 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21617 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21618 new_path="$unix_path" 21619 fi 21620 21621 # remove trailing .exe if any 21622 new_path="${new_path/%.exe/}" 21623 21624 # Save the first 10 bytes of this path to the storage, so fixpath can work. 21625 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21626 fi 21627 21628 else 21629 # We're on a posix platform. Hooray! :) 21630 # First separate the path from the arguments. This will split at the first 21631 # space. 21632 complete="$PROPER_COMPILER_CXX" 21633 path="${complete%% *}" 21634 tmp="$complete EOL" 21635 arguments="${tmp#* }" 21636 21637 # Cannot rely on the command "which" here since it doesn't always work. 21638 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21639 if test -z "$is_absolute_path"; then 21640 # Path to executable is not absolute. Find it. 21641 IFS_save="$IFS" 21642 IFS=: 21643 for p in $PATH; do 21644 if test -f "$p/$path" && test -x "$p/$path"; then 21645 new_path="$p/$path" 21646 break 21647 fi 21648 done 21649 IFS="$IFS_save" 21650 else 21651 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving PROPER_COMPILER_CXX (as $path) failed, using $path directly." >&5 21652 $as_echo "$as_me: Resolving PROPER_COMPILER_CXX (as $path) failed, using $path directly." >&6;} 21653 new_path="$path" 21654 fi 21655 21656 if test "x$new_path" = x; then 21657 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5 21658 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;} 21659 has_space=`$ECHO "$complete" | $GREP " "` 21660 if test "x$has_space" != x; then 21661 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21662 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21663 fi 21664 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 21665 fi 21666 fi 21667 21668 # Now join together the path and the arguments once again 21669 if test "x$arguments" != xEOL; then 21670 new_complete="$new_path ${arguments% *}" 21671 else 21672 new_complete="$new_path" 21673 fi 21674 21675 if test "x$complete" != "x$new_complete"; then 21676 PROPER_COMPILER_CXX="$new_complete" 21677 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&5 21678 $as_echo "$as_me: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&6;} 21679 fi 21680 21681 PATH="$RETRY_COMPILER_SAVED_PATH" 21682 21683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CXX" >&5 21684 $as_echo_n "checking for resolved symbolic links for CXX... " >&6; } 21685 21686 if test "x$OPENJDK_BUILD_OS" != xwindows; then 21687 # Follow a chain of symbolic links. Use readlink 21688 # where it exists, else fall back to horribly 21689 # complicated shell code. 21690 if test "x$READLINK_TESTED" != yes; then 21691 # On MacOSX there is a readlink tool with a different 21692 # purpose than the GNU readlink tool. Check the found readlink. 21693 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 21694 if test "x$ISGNU" = x; then 21695 # A readlink that we do not know how to use. 21696 # Are there other non-GNU readlinks out there? 21697 READLINK_TESTED=yes 21698 READLINK= 21699 fi 21700 fi 21701 21702 if test "x$READLINK" != x; then 21703 PROPER_COMPILER_CXX=`$READLINK -f $PROPER_COMPILER_CXX` 21704 else 21705 # Save the current directory for restoring afterwards 21706 STARTDIR=$PWD 21707 COUNTER=0 21708 sym_link_dir=`$DIRNAME $PROPER_COMPILER_CXX` 21709 sym_link_file=`$BASENAME $PROPER_COMPILER_CXX` 21710 # Use the system pwd and not the shell builtin to resolve directory symlinks 21711 cd $sym_link_dir 21712 cd `$THEPWDCMD` 21713 sym_link_dir=`$THEPWDCMD` 21714 # Resolve file symlinks 21715 while test $COUNTER -lt 20; do 21716 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 21717 if test "x$ISLINK" == x; then 21718 # This is not a symbolic link! We are done! 21719 break 21720 fi 21721 # Again resolve directory symlinks since the target of the just found 21722 # link could be in a different directory 21723 cd `$DIRNAME $ISLINK` 21724 sym_link_dir=`$THEPWDCMD` 21725 sym_link_file=`$BASENAME $ISLINK` 21726 let COUNTER=COUNTER+1 21727 done 21728 cd $STARTDIR 21729 PROPER_COMPILER_CXX=$sym_link_dir/$sym_link_file 21730 fi 21731 fi 21732 21733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5 21734 $as_echo "$PROPER_COMPILER_CXX" >&6; } 21735 CXX="$PROPER_COMPILER_CXX" 21736 else 21737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CXX" >&5 21738 $as_echo "no, keeping CXX" >&6; } 21739 CXX="$TEST_COMPILER" 21740 fi 21741 21742 COMPILER=$CXX 21743 COMPILER_NAME=$COMPILER_NAME 21744 21745 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 21746 # Make sure we use the Sun Studio compiler and not gcc on Solaris, which won't work 21747 COMPILER_VERSION_TEST=`$COMPILER -V 2>&1 | $HEAD -n 1` 21748 $ECHO $COMPILER_VERSION_TEST | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 21749 if test $? -ne 0; then 21750 GCC_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1` 21751 21752 { $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 21753 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required Sun Studio compiler." >&6;} 21754 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&5 21755 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&6;} 21756 as_fn_error $? "Sun Studio compiler is required. Try setting --with-tools-dir." "$LINENO" 5 21757 else 21758 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/p"` 21759 COMPILER_VENDOR="Sun Studio" 21760 fi 21761 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 21762 # First line typically looks something like: 21763 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.30319.01 for 80x86 21764 COMPILER_VERSION_TEST=`$COMPILER 2>&1 | $HEAD -n 1` 21765 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*Version \([1-9][0-9.]*\) .*/\1/p"` 21766 COMPILER_VENDOR="Microsoft CL.EXE" 21767 COMPILER_CPU_TEST=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* for \(.*\)$/\1/p"` 21768 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 21769 if test "x$COMPILER_CPU_TEST" != "x80x86"; then 21770 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5 21771 fi 21772 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 21773 if test "x$COMPILER_CPU_TEST" != "xx64"; then 21774 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 21775 fi 21776 fi 21777 else 21778 COMPILER_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1` 21779 # Check that this is likely to be GCC. 21780 $COMPILER --version 2>&1 | $GREP "Free Software Foundation" > /dev/null 21781 if test $? -ne 0; then 21782 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&5 21783 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&6;} 21784 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&5 21785 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&6;} 21786 as_fn_error $? "GCC compiler is required. Try setting --with-tools-dir." "$LINENO" 5 21787 fi 21788 21789 # First line typically looks something like: 21790 # gcc (Ubuntu/Linaro 4.5.2-8ubuntu4) 4.5.2 21791 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* \([1-9][0-9.]*\)/\1/p"` 21792 COMPILER_VENDOR=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^\(.*\) [1-9][0-9.]*/\1/p"` 21793 fi 21794 # This sets CC_VERSION or CXX_VERSION. (This comment is a grep marker) 21795 CXX_VERSION="$COMPILER_VERSION" 21796 # This sets CC_VENDOR or CXX_VENDOR. (This comment is a grep marker) 21797 CXX_VENDOR="$COMPILER_VENDOR" 21798 21799 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&5 21800 $as_echo "$as_me: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&6;} 21801 21802 21803 # Now that we have resolved CXX ourself, let autoconf have its go at it 21804 ac_ext=cpp 21805 ac_cpp='$CXXCPP $CPPFLAGS' 21806 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 21807 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 21808 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 21809 if test -z "$CXX"; then 21810 if test -n "$CCC"; then 21811 CXX=$CCC 21812 else 21813 if test -n "$ac_tool_prefix"; then 21814 for ac_prog in $CXX 21815 do 21816 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 21817 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 21818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21819 $as_echo_n "checking for $ac_word... " >&6; } 21820 if ${ac_cv_prog_CXX+:} false; then : 21821 $as_echo_n "(cached) " >&6 21822 else 21823 if test -n "$CXX"; then 21824 ac_cv_prog_CXX="$CXX" # Let the user override the test. 21825 else 21826 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21827 for as_dir in $PATH 21828 do 21829 IFS=$as_save_IFS 21830 test -z "$as_dir" && as_dir=. 21831 for ac_exec_ext in '' $ac_executable_extensions; do 21832 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 21833 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" 21834 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21835 break 2 21836 fi 21837 done 21838 done 21839 IFS=$as_save_IFS 21840 21841 fi 21842 fi 21843 CXX=$ac_cv_prog_CXX 21844 if test -n "$CXX"; then 21845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 21846 $as_echo "$CXX" >&6; } 21847 else 21848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21849 $as_echo "no" >&6; } 21850 fi 21851 21852 21853 test -n "$CXX" && break 21854 done 21855 fi 21856 if test -z "$CXX"; then 21857 ac_ct_CXX=$CXX 21858 for ac_prog in $CXX 21859 do 21860 # Extract the first word of "$ac_prog", so it can be a program name with args. 21861 set dummy $ac_prog; ac_word=$2 21862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21863 $as_echo_n "checking for $ac_word... " >&6; } 21864 if ${ac_cv_prog_ac_ct_CXX+:} false; then : 21865 $as_echo_n "(cached) " >&6 21866 else 21867 if test -n "$ac_ct_CXX"; then 21868 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. 21869 else 21870 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21871 for as_dir in $PATH 21872 do 21873 IFS=$as_save_IFS 21874 test -z "$as_dir" && as_dir=. 21875 for ac_exec_ext in '' $ac_executable_extensions; do 21876 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 21877 ac_cv_prog_ac_ct_CXX="$ac_prog" 21878 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21879 break 2 21880 fi 21881 done 21882 done 21883 IFS=$as_save_IFS 21884 21885 fi 21886 fi 21887 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX 21888 if test -n "$ac_ct_CXX"; then 21889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 21890 $as_echo "$ac_ct_CXX" >&6; } 21891 else 21892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21893 $as_echo "no" >&6; } 21894 fi 21895 21896 21897 test -n "$ac_ct_CXX" && break 21898 done 21899 21900 if test "x$ac_ct_CXX" = x; then 21901 CXX="g++" 21902 else 21903 case $cross_compiling:$ac_tool_warned in 21904 yes:) 21905 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 21906 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 21907 ac_tool_warned=yes ;; 21908 esac 21909 CXX=$ac_ct_CXX 21910 fi 21911 fi 21912 21913 fi 21914 fi 21915 # Provide some information about the compiler. 21916 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 21917 set X $ac_compile 21918 ac_compiler=$2 21919 for ac_option in --version -v -V -qversion; do 21920 { { ac_try="$ac_compiler $ac_option >&5" 21921 case "(($ac_try" in 21922 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 21923 *) ac_try_echo=$ac_try;; 21924 esac 21925 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 21926 $as_echo "$ac_try_echo"; } >&5 21927 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 21928 ac_status=$? 21929 if test -s conftest.err; then 21930 sed '10a\ 21931 ... rest of stderr output deleted ... 21932 10q' conftest.err >conftest.er1 21933 cat conftest.er1 >&5 21934 fi 21935 rm -f conftest.er1 conftest.err 21936 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 21937 test $ac_status = 0; } 21938 done 21939 21940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 21941 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } 21942 if ${ac_cv_cxx_compiler_gnu+:} false; then : 21943 $as_echo_n "(cached) " >&6 21944 else 21945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21946 /* end confdefs.h. */ 21947 21948 int 21949 main () 21950 { 21951 #ifndef __GNUC__ 21952 choke me 21953 #endif 21954 21955 ; 21956 return 0; 21957 } 21958 _ACEOF 21959 if ac_fn_cxx_try_compile "$LINENO"; then : 21960 ac_compiler_gnu=yes 21961 else 21962 ac_compiler_gnu=no 21963 fi 21964 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 21965 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu 21966 21967 fi 21968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 21969 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } 21970 if test $ac_compiler_gnu = yes; then 21971 GXX=yes 21972 else 21973 GXX= 21974 fi 21975 ac_test_CXXFLAGS=${CXXFLAGS+set} 21976 ac_save_CXXFLAGS=$CXXFLAGS 21977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 21978 $as_echo_n "checking whether $CXX accepts -g... " >&6; } 21979 if ${ac_cv_prog_cxx_g+:} false; then : 21980 $as_echo_n "(cached) " >&6 21981 else 21982 ac_save_cxx_werror_flag=$ac_cxx_werror_flag 21983 ac_cxx_werror_flag=yes 21984 ac_cv_prog_cxx_g=no 21985 CXXFLAGS="-g" 21986 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21987 /* end confdefs.h. */ 21988 21989 int 21990 main () 21991 { 21992 21993 ; 21994 return 0; 21995 } 21996 _ACEOF 21997 if ac_fn_cxx_try_compile "$LINENO"; then : 21998 ac_cv_prog_cxx_g=yes 21999 else 22000 CXXFLAGS="" 22001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22002 /* end confdefs.h. */ 22003 22004 int 22005 main () 22006 { 22007 22008 ; 22009 return 0; 22010 } 22011 _ACEOF 22012 if ac_fn_cxx_try_compile "$LINENO"; then : 22013 22014 else 22015 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 22016 CXXFLAGS="-g" 22017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22018 /* end confdefs.h. */ 22019 22020 int 22021 main () 22022 { 22023 22024 ; 22025 return 0; 22026 } 22027 _ACEOF 22028 if ac_fn_cxx_try_compile "$LINENO"; then : 22029 ac_cv_prog_cxx_g=yes 22030 fi 22031 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22032 fi 22033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22034 fi 22035 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22036 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 22037 fi 22038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 22039 $as_echo "$ac_cv_prog_cxx_g" >&6; } 22040 if test "$ac_test_CXXFLAGS" = set; then 22041 CXXFLAGS=$ac_save_CXXFLAGS 22042 elif test $ac_cv_prog_cxx_g = yes; then 22043 if test "$GXX" = yes; then 22044 CXXFLAGS="-g -O2" 22045 else 22046 CXXFLAGS="-g" 22047 fi 22048 else 22049 if test "$GXX" = yes; then 22050 CXXFLAGS="-O2" 22051 else 22052 CXXFLAGS= 22053 fi 22054 fi 22055 ac_ext=cpp 22056 ac_cpp='$CXXCPP $CPPFLAGS' 22057 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 22058 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 22059 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 22060 22061 22062 ### Locate other tools 22063 22064 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 22065 ac_ext=m 22066 ac_cpp='$OBJCPP $CPPFLAGS' 22067 ac_compile='$OBJC -c $OBJCFLAGS $CPPFLAGS conftest.$ac_ext >&5' 22068 ac_link='$OBJC -o conftest$ac_exeext $OBJCFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 22069 ac_compiler_gnu=$ac_cv_objc_compiler_gnu 22070 if test -n "$ac_tool_prefix"; then 22071 for ac_prog in gcc objcc objc cc CC 22072 do 22073 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 22074 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 22075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22076 $as_echo_n "checking for $ac_word... " >&6; } 22077 if ${ac_cv_prog_OBJC+:} false; then : 22078 $as_echo_n "(cached) " >&6 22079 else 22080 if test -n "$OBJC"; then 22081 ac_cv_prog_OBJC="$OBJC" # Let the user override the test. 22082 else 22083 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22084 for as_dir in $PATH 22085 do 22086 IFS=$as_save_IFS 22087 test -z "$as_dir" && as_dir=. 22088 for ac_exec_ext in '' $ac_executable_extensions; do 22089 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 22090 ac_cv_prog_OBJC="$ac_tool_prefix$ac_prog" 22091 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22092 break 2 22093 fi 22094 done 22095 done 22096 IFS=$as_save_IFS 22097 22098 fi 22099 fi 22100 OBJC=$ac_cv_prog_OBJC 22101 if test -n "$OBJC"; then 22102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJC" >&5 22103 $as_echo "$OBJC" >&6; } 22104 else 22105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22106 $as_echo "no" >&6; } 22107 fi 22108 22109 22110 test -n "$OBJC" && break 22111 done 22112 fi 22113 if test -z "$OBJC"; then 22114 ac_ct_OBJC=$OBJC 22115 for ac_prog in gcc objcc objc cc CC 22116 do 22117 # Extract the first word of "$ac_prog", so it can be a program name with args. 22118 set dummy $ac_prog; ac_word=$2 22119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22120 $as_echo_n "checking for $ac_word... " >&6; } 22121 if ${ac_cv_prog_ac_ct_OBJC+:} false; then : 22122 $as_echo_n "(cached) " >&6 22123 else 22124 if test -n "$ac_ct_OBJC"; then 22125 ac_cv_prog_ac_ct_OBJC="$ac_ct_OBJC" # Let the user override the test. 22126 else 22127 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22128 for as_dir in $PATH 22129 do 22130 IFS=$as_save_IFS 22131 test -z "$as_dir" && as_dir=. 22132 for ac_exec_ext in '' $ac_executable_extensions; do 22133 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 22134 ac_cv_prog_ac_ct_OBJC="$ac_prog" 22135 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22136 break 2 22137 fi 22138 done 22139 done 22140 IFS=$as_save_IFS 22141 22142 fi 22143 fi 22144 ac_ct_OBJC=$ac_cv_prog_ac_ct_OBJC 22145 if test -n "$ac_ct_OBJC"; then 22146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJC" >&5 22147 $as_echo "$ac_ct_OBJC" >&6; } 22148 else 22149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22150 $as_echo "no" >&6; } 22151 fi 22152 22153 22154 test -n "$ac_ct_OBJC" && break 22155 done 22156 22157 if test "x$ac_ct_OBJC" = x; then 22158 OBJC="gcc" 22159 else 22160 case $cross_compiling:$ac_tool_warned in 22161 yes:) 22162 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 22163 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 22164 ac_tool_warned=yes ;; 22165 esac 22166 OBJC=$ac_ct_OBJC 22167 fi 22168 fi 22169 22170 # Provide some information about the compiler. 22171 $as_echo "$as_me:${as_lineno-$LINENO}: checking for Objective C compiler version" >&5 22172 set X $ac_compile 22173 ac_compiler=$2 22174 for ac_option in --version -v -V -qversion; do 22175 { { ac_try="$ac_compiler $ac_option >&5" 22176 case "(($ac_try" in 22177 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 22178 *) ac_try_echo=$ac_try;; 22179 esac 22180 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 22181 $as_echo "$ac_try_echo"; } >&5 22182 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 22183 ac_status=$? 22184 if test -s conftest.err; then 22185 sed '10a\ 22186 ... rest of stderr output deleted ... 22187 10q' conftest.err >conftest.er1 22188 cat conftest.er1 >&5 22189 fi 22190 rm -f conftest.er1 conftest.err 22191 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 22192 test $ac_status = 0; } 22193 done 22194 22195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Objective C compiler" >&5 22196 $as_echo_n "checking whether we are using the GNU Objective C compiler... " >&6; } 22197 if ${ac_cv_objc_compiler_gnu+:} false; then : 22198 $as_echo_n "(cached) " >&6 22199 else 22200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22201 /* end confdefs.h. */ 22202 22203 int 22204 main () 22205 { 22206 #ifndef __GNUC__ 22207 choke me 22208 #endif 22209 22210 ; 22211 return 0; 22212 } 22213 _ACEOF 22214 if ac_fn_objc_try_compile "$LINENO"; then : 22215 ac_compiler_gnu=yes 22216 else 22217 ac_compiler_gnu=no 22218 fi 22219 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22220 ac_cv_objc_compiler_gnu=$ac_compiler_gnu 22221 22222 fi 22223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objc_compiler_gnu" >&5 22224 $as_echo "$ac_cv_objc_compiler_gnu" >&6; } 22225 if test $ac_compiler_gnu = yes; then 22226 GOBJC=yes 22227 else 22228 GOBJC= 22229 fi 22230 ac_test_OBJCFLAGS=${OBJCFLAGS+set} 22231 ac_save_OBJCFLAGS=$OBJCFLAGS 22232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $OBJC accepts -g" >&5 22233 $as_echo_n "checking whether $OBJC accepts -g... " >&6; } 22234 if ${ac_cv_prog_objc_g+:} false; then : 22235 $as_echo_n "(cached) " >&6 22236 else 22237 ac_save_objc_werror_flag=$ac_objc_werror_flag 22238 ac_objc_werror_flag=yes 22239 ac_cv_prog_objc_g=no 22240 OBJCFLAGS="-g" 22241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22242 /* end confdefs.h. */ 22243 22244 int 22245 main () 22246 { 22247 22248 ; 22249 return 0; 22250 } 22251 _ACEOF 22252 if ac_fn_objc_try_compile "$LINENO"; then : 22253 ac_cv_prog_objc_g=yes 22254 else 22255 OBJCFLAGS="" 22256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22257 /* end confdefs.h. */ 22258 22259 int 22260 main () 22261 { 22262 22263 ; 22264 return 0; 22265 } 22266 _ACEOF 22267 if ac_fn_objc_try_compile "$LINENO"; then : 22268 22269 else 22270 ac_objc_werror_flag=$ac_save_objc_werror_flag 22271 OBJCFLAGS="-g" 22272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22273 /* end confdefs.h. */ 22274 22275 int 22276 main () 22277 { 22278 22279 ; 22280 return 0; 22281 } 22282 _ACEOF 22283 if ac_fn_objc_try_compile "$LINENO"; then : 22284 ac_cv_prog_objc_g=yes 22285 fi 22286 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22287 fi 22288 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22289 fi 22290 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22291 ac_objc_werror_flag=$ac_save_objc_werror_flag 22292 fi 22293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_objc_g" >&5 22294 $as_echo "$ac_cv_prog_objc_g" >&6; } 22295 if test "$ac_test_OBJCFLAGS" = set; then 22296 OBJCFLAGS=$ac_save_OBJCFLAGS 22297 elif test $ac_cv_prog_objc_g = yes; then 22298 if test "$GOBJC" = yes; then 22299 OBJCFLAGS="-g -O2" 22300 else 22301 OBJCFLAGS="-g" 22302 fi 22303 else 22304 if test "$GOBJC" = yes; then 22305 OBJCFLAGS="-O2" 22306 else 22307 OBJCFLAGS= 22308 fi 22309 fi 22310 ac_ext=cpp 22311 ac_cpp='$CXXCPP $CPPFLAGS' 22312 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 22313 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 22314 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 22315 22316 22317 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22318 22319 # First separate the path from the arguments. This will split at the first 22320 # space. 22321 complete="$OBJC" 22322 path="${complete%% *}" 22323 tmp="$complete EOL" 22324 arguments="${tmp#* }" 22325 22326 # Input might be given as Windows format, start by converting to 22327 # unix format. 22328 new_path=`$CYGPATH -u "$path"` 22329 22330 # Now try to locate executable using which 22331 new_path=`$WHICH "$new_path" 2> /dev/null` 22332 # bat and cmd files are not always considered executable in cygwin causing which 22333 # to not find them 22334 if test "x$new_path" = x \ 22335 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 22336 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 22337 new_path=`$CYGPATH -u "$path"` 22338 fi 22339 if test "x$new_path" = x; then 22340 # Oops. Which didn't find the executable. 22341 # The splitting of arguments from the executable at a space might have been incorrect, 22342 # since paths with space are more likely in Windows. Give it another try with the whole 22343 # argument. 22344 path="$complete" 22345 arguments="EOL" 22346 new_path=`$CYGPATH -u "$path"` 22347 new_path=`$WHICH "$new_path" 2> /dev/null` 22348 # bat and cmd files are not always considered executable in cygwin causing which 22349 # to not find them 22350 if test "x$new_path" = x \ 22351 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 22352 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 22353 new_path=`$CYGPATH -u "$path"` 22354 fi 22355 if test "x$new_path" = x; then 22356 # It's still not found. Now this is an unrecoverable error. 22357 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5 22358 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;} 22359 has_space=`$ECHO "$complete" | $GREP " "` 22360 if test "x$has_space" != x; then 22361 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 22362 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 22363 fi 22364 as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5 22365 fi 22366 fi 22367 22368 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 22369 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 22370 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 22371 # "foo.exe" is OK but "foo" is an error. 22372 # 22373 # This test is therefore slightly more accurate than "test -f" to check for file precense. 22374 # It is also a way to make sure we got the proper file name for the real test later on. 22375 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 22376 if test "x$test_shortpath" = x; then 22377 # Short path failed, file does not exist as specified. 22378 # Try adding .exe or .cmd 22379 if test -f "${new_path}.exe"; then 22380 input_to_shortpath="${new_path}.exe" 22381 elif test -f "${new_path}.cmd"; then 22382 input_to_shortpath="${new_path}.cmd" 22383 else 22384 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$new_path\", is invalid." >&5 22385 $as_echo "$as_me: The path of OBJC, which resolves as \"$new_path\", is invalid." >&6;} 22386 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 22387 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 22388 as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5 22389 fi 22390 else 22391 input_to_shortpath="$new_path" 22392 fi 22393 22394 # Call helper function which possibly converts this using DOS-style short mode. 22395 # If so, the updated path is stored in $new_path. 22396 new_path="$input_to_shortpath" 22397 22398 input_path="$input_to_shortpath" 22399 # Check if we need to convert this using DOS-style short mode. If the path 22400 # contains just simple characters, use it. Otherwise (spaces, weird characters), 22401 # take no chances and rewrite it. 22402 # Note: m4 eats our [], so we need to use [ and ] instead. 22403 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 22404 if test "x$has_forbidden_chars" != x; then 22405 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 22406 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 22407 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 22408 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 22409 # Going to short mode and back again did indeed matter. Since short mode is 22410 # case insensitive, let's make it lowercase to improve readability. 22411 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 22412 # Now convert it back to Unix-stile (cygpath) 22413 input_path=`$CYGPATH -u "$shortmode_path"` 22414 new_path="$input_path" 22415 fi 22416 fi 22417 22418 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 22419 if test "x$test_cygdrive_prefix" = x; then 22420 # As a simple fix, exclude /usr/bin since it's not a real path. 22421 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 22422 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 22423 # a path prefixed by /cygdrive for fixpath to work. 22424 new_path="$CYGWIN_ROOT_PATH$input_path" 22425 fi 22426 fi 22427 22428 # remove trailing .exe if any 22429 new_path="${new_path/%.exe/}" 22430 22431 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22432 22433 # First separate the path from the arguments. This will split at the first 22434 # space. 22435 complete="$OBJC" 22436 path="${complete%% *}" 22437 tmp="$complete EOL" 22438 arguments="${tmp#* }" 22439 22440 # Input might be given as Windows format, start by converting to 22441 # unix format. 22442 new_path="$path" 22443 22444 windows_path="$new_path" 22445 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22446 unix_path=`$CYGPATH -u "$windows_path"` 22447 new_path="$unix_path" 22448 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22449 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22450 new_path="$unix_path" 22451 fi 22452 22453 22454 # Now try to locate executable using which 22455 new_path=`$WHICH "$new_path" 2> /dev/null` 22456 22457 if test "x$new_path" = x; then 22458 # Oops. Which didn't find the executable. 22459 # The splitting of arguments from the executable at a space might have been incorrect, 22460 # since paths with space are more likely in Windows. Give it another try with the whole 22461 # argument. 22462 path="$complete" 22463 arguments="EOL" 22464 new_path="$path" 22465 22466 windows_path="$new_path" 22467 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22468 unix_path=`$CYGPATH -u "$windows_path"` 22469 new_path="$unix_path" 22470 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22471 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22472 new_path="$unix_path" 22473 fi 22474 22475 22476 new_path=`$WHICH "$new_path" 2> /dev/null` 22477 22478 if test "x$new_path" = x; then 22479 # It's still not found. Now this is an unrecoverable error. 22480 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5 22481 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;} 22482 has_space=`$ECHO "$complete" | $GREP " "` 22483 if test "x$has_space" != x; then 22484 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 22485 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 22486 fi 22487 as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5 22488 fi 22489 fi 22490 22491 # Now new_path has a complete unix path to the binary 22492 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 22493 # Keep paths in /bin as-is, but remove trailing .exe if any 22494 new_path="${new_path/%.exe/}" 22495 # Do not save /bin paths to all_fixpath_prefixes! 22496 else 22497 # Not in mixed or Windows style, start by that. 22498 new_path=`cmd //c echo $new_path` 22499 22500 input_path="$new_path" 22501 # Check if we need to convert this using DOS-style short mode. If the path 22502 # contains just simple characters, use it. Otherwise (spaces, weird characters), 22503 # take no chances and rewrite it. 22504 # Note: m4 eats our [], so we need to use [ and ] instead. 22505 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 22506 if test "x$has_forbidden_chars" != x; then 22507 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 22508 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 22509 fi 22510 22511 # Output is in $new_path 22512 22513 windows_path="$new_path" 22514 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22515 unix_path=`$CYGPATH -u "$windows_path"` 22516 new_path="$unix_path" 22517 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22518 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22519 new_path="$unix_path" 22520 fi 22521 22522 # remove trailing .exe if any 22523 new_path="${new_path/%.exe/}" 22524 22525 # Save the first 10 bytes of this path to the storage, so fixpath can work. 22526 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 22527 fi 22528 22529 else 22530 # We're on a posix platform. Hooray! :) 22531 # First separate the path from the arguments. This will split at the first 22532 # space. 22533 complete="$OBJC" 22534 path="${complete%% *}" 22535 tmp="$complete EOL" 22536 arguments="${tmp#* }" 22537 22538 # Cannot rely on the command "which" here since it doesn't always work. 22539 is_absolute_path=`$ECHO "$path" | $GREP ^/` 22540 if test -z "$is_absolute_path"; then 22541 # Path to executable is not absolute. Find it. 22542 IFS_save="$IFS" 22543 IFS=: 22544 for p in $PATH; do 22545 if test -f "$p/$path" && test -x "$p/$path"; then 22546 new_path="$p/$path" 22547 break 22548 fi 22549 done 22550 IFS="$IFS_save" 22551 else 22552 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving OBJC (as $path) failed, using $path directly." >&5 22553 $as_echo "$as_me: Resolving OBJC (as $path) failed, using $path directly." >&6;} 22554 new_path="$path" 22555 fi 22556 22557 if test "x$new_path" = x; then 22558 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5 22559 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;} 22560 has_space=`$ECHO "$complete" | $GREP " "` 22561 if test "x$has_space" != x; then 22562 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 22563 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 22564 fi 22565 as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5 22566 fi 22567 fi 22568 22569 # Now join together the path and the arguments once again 22570 if test "x$arguments" != xEOL; then 22571 new_complete="$new_path ${arguments% *}" 22572 else 22573 new_complete="$new_path" 22574 fi 22575 22576 if test "x$complete" != "x$new_complete"; then 22577 OBJC="$new_complete" 22578 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJC to \"$new_complete\"" >&5 22579 $as_echo "$as_me: Rewriting OBJC to \"$new_complete\"" >&6;} 22580 fi 22581 22582 else 22583 OBJC= 22584 fi 22585 22586 # Restore the flags to the user specified values. 22587 # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2" 22588 CFLAGS="$ORG_CFLAGS" 22589 CXXFLAGS="$ORG_CXXFLAGS" 22590 OBJCFLAGS="$ORG_OBJCFLAGS" 22591 22592 LD="$CC" 22593 LDEXE="$CC" 22594 LDCXX="$CXX" 22595 LDEXECXX="$CXX" 22596 22597 # LDEXE is the linker to use, when creating executables. 22598 22599 # Linking C++ libraries. 22600 22601 # Linking C++ executables. 22602 22603 22604 if test "x$OPENJDK_TARGET_OS" != xwindows; then 22605 if test -n "$ac_tool_prefix"; then 22606 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. 22607 set dummy ${ac_tool_prefix}ar; ac_word=$2 22608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22609 $as_echo_n "checking for $ac_word... " >&6; } 22610 if ${ac_cv_prog_AR+:} false; then : 22611 $as_echo_n "(cached) " >&6 22612 else 22613 if test -n "$AR"; then 22614 ac_cv_prog_AR="$AR" # Let the user override the test. 22615 else 22616 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22617 for as_dir in $PATH 22618 do 22619 IFS=$as_save_IFS 22620 test -z "$as_dir" && as_dir=. 22621 for ac_exec_ext in '' $ac_executable_extensions; do 22622 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 22623 ac_cv_prog_AR="${ac_tool_prefix}ar" 22624 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22625 break 2 22626 fi 22627 done 22628 done 22629 IFS=$as_save_IFS 22630 22631 fi 22632 fi 22633 AR=$ac_cv_prog_AR 22634 if test -n "$AR"; then 22635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 22636 $as_echo "$AR" >&6; } 22637 else 22638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22639 $as_echo "no" >&6; } 22640 fi 22641 22642 22643 fi 22644 if test -z "$ac_cv_prog_AR"; then 22645 ac_ct_AR=$AR 22646 # Extract the first word of "ar", so it can be a program name with args. 22647 set dummy ar; ac_word=$2 22648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22649 $as_echo_n "checking for $ac_word... " >&6; } 22650 if ${ac_cv_prog_ac_ct_AR+:} false; then : 22651 $as_echo_n "(cached) " >&6 22652 else 22653 if test -n "$ac_ct_AR"; then 22654 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 22655 else 22656 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22657 for as_dir in $PATH 22658 do 22659 IFS=$as_save_IFS 22660 test -z "$as_dir" && as_dir=. 22661 for ac_exec_ext in '' $ac_executable_extensions; do 22662 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 22663 ac_cv_prog_ac_ct_AR="ar" 22664 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22665 break 2 22666 fi 22667 done 22668 done 22669 IFS=$as_save_IFS 22670 22671 fi 22672 fi 22673 ac_ct_AR=$ac_cv_prog_ac_ct_AR 22674 if test -n "$ac_ct_AR"; then 22675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 22676 $as_echo "$ac_ct_AR" >&6; } 22677 else 22678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22679 $as_echo "no" >&6; } 22680 fi 22681 22682 if test "x$ac_ct_AR" = x; then 22683 AR="" 22684 else 22685 case $cross_compiling:$ac_tool_warned in 22686 yes:) 22687 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 22688 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 22689 ac_tool_warned=yes ;; 22690 esac 22691 AR=$ac_ct_AR 22692 fi 22693 else 22694 AR="$ac_cv_prog_AR" 22695 fi 22696 22697 22698 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22699 22700 # First separate the path from the arguments. This will split at the first 22701 # space. 22702 complete="$AR" 22703 path="${complete%% *}" 22704 tmp="$complete EOL" 22705 arguments="${tmp#* }" 22706 22707 # Input might be given as Windows format, start by converting to 22708 # unix format. 22709 new_path=`$CYGPATH -u "$path"` 22710 22711 # Now try to locate executable using which 22712 new_path=`$WHICH "$new_path" 2> /dev/null` 22713 # bat and cmd files are not always considered executable in cygwin causing which 22714 # to not find them 22715 if test "x$new_path" = x \ 22716 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 22717 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 22718 new_path=`$CYGPATH -u "$path"` 22719 fi 22720 if test "x$new_path" = x; then 22721 # Oops. Which didn't find the executable. 22722 # The splitting of arguments from the executable at a space might have been incorrect, 22723 # since paths with space are more likely in Windows. Give it another try with the whole 22724 # argument. 22725 path="$complete" 22726 arguments="EOL" 22727 new_path=`$CYGPATH -u "$path"` 22728 new_path=`$WHICH "$new_path" 2> /dev/null` 22729 # bat and cmd files are not always considered executable in cygwin causing which 22730 # to not find them 22731 if test "x$new_path" = x \ 22732 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 22733 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 22734 new_path=`$CYGPATH -u "$path"` 22735 fi 22736 if test "x$new_path" = x; then 22737 # It's still not found. Now this is an unrecoverable error. 22738 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 22739 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 22740 has_space=`$ECHO "$complete" | $GREP " "` 22741 if test "x$has_space" != x; then 22742 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 22743 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 22744 fi 22745 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 22746 fi 22747 fi 22748 22749 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 22750 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 22751 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 22752 # "foo.exe" is OK but "foo" is an error. 22753 # 22754 # This test is therefore slightly more accurate than "test -f" to check for file precense. 22755 # It is also a way to make sure we got the proper file name for the real test later on. 22756 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 22757 if test "x$test_shortpath" = x; then 22758 # Short path failed, file does not exist as specified. 22759 # Try adding .exe or .cmd 22760 if test -f "${new_path}.exe"; then 22761 input_to_shortpath="${new_path}.exe" 22762 elif test -f "${new_path}.cmd"; then 22763 input_to_shortpath="${new_path}.cmd" 22764 else 22765 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5 22766 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;} 22767 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 22768 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 22769 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 22770 fi 22771 else 22772 input_to_shortpath="$new_path" 22773 fi 22774 22775 # Call helper function which possibly converts this using DOS-style short mode. 22776 # If so, the updated path is stored in $new_path. 22777 new_path="$input_to_shortpath" 22778 22779 input_path="$input_to_shortpath" 22780 # Check if we need to convert this using DOS-style short mode. If the path 22781 # contains just simple characters, use it. Otherwise (spaces, weird characters), 22782 # take no chances and rewrite it. 22783 # Note: m4 eats our [], so we need to use [ and ] instead. 22784 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 22785 if test "x$has_forbidden_chars" != x; then 22786 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 22787 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 22788 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 22789 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 22790 # Going to short mode and back again did indeed matter. Since short mode is 22791 # case insensitive, let's make it lowercase to improve readability. 22792 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 22793 # Now convert it back to Unix-stile (cygpath) 22794 input_path=`$CYGPATH -u "$shortmode_path"` 22795 new_path="$input_path" 22796 fi 22797 fi 22798 22799 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 22800 if test "x$test_cygdrive_prefix" = x; then 22801 # As a simple fix, exclude /usr/bin since it's not a real path. 22802 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 22803 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 22804 # a path prefixed by /cygdrive for fixpath to work. 22805 new_path="$CYGWIN_ROOT_PATH$input_path" 22806 fi 22807 fi 22808 22809 # remove trailing .exe if any 22810 new_path="${new_path/%.exe/}" 22811 22812 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22813 22814 # First separate the path from the arguments. This will split at the first 22815 # space. 22816 complete="$AR" 22817 path="${complete%% *}" 22818 tmp="$complete EOL" 22819 arguments="${tmp#* }" 22820 22821 # Input might be given as Windows format, start by converting to 22822 # unix format. 22823 new_path="$path" 22824 22825 windows_path="$new_path" 22826 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22827 unix_path=`$CYGPATH -u "$windows_path"` 22828 new_path="$unix_path" 22829 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22830 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22831 new_path="$unix_path" 22832 fi 22833 22834 22835 # Now try to locate executable using which 22836 new_path=`$WHICH "$new_path" 2> /dev/null` 22837 22838 if test "x$new_path" = x; then 22839 # Oops. Which didn't find the executable. 22840 # The splitting of arguments from the executable at a space might have been incorrect, 22841 # since paths with space are more likely in Windows. Give it another try with the whole 22842 # argument. 22843 path="$complete" 22844 arguments="EOL" 22845 new_path="$path" 22846 22847 windows_path="$new_path" 22848 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22849 unix_path=`$CYGPATH -u "$windows_path"` 22850 new_path="$unix_path" 22851 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22852 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22853 new_path="$unix_path" 22854 fi 22855 22856 22857 new_path=`$WHICH "$new_path" 2> /dev/null` 22858 22859 if test "x$new_path" = x; then 22860 # It's still not found. Now this is an unrecoverable error. 22861 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 22862 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 22863 has_space=`$ECHO "$complete" | $GREP " "` 22864 if test "x$has_space" != x; then 22865 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 22866 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 22867 fi 22868 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 22869 fi 22870 fi 22871 22872 # Now new_path has a complete unix path to the binary 22873 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 22874 # Keep paths in /bin as-is, but remove trailing .exe if any 22875 new_path="${new_path/%.exe/}" 22876 # Do not save /bin paths to all_fixpath_prefixes! 22877 else 22878 # Not in mixed or Windows style, start by that. 22879 new_path=`cmd //c echo $new_path` 22880 22881 input_path="$new_path" 22882 # Check if we need to convert this using DOS-style short mode. If the path 22883 # contains just simple characters, use it. Otherwise (spaces, weird characters), 22884 # take no chances and rewrite it. 22885 # Note: m4 eats our [], so we need to use [ and ] instead. 22886 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 22887 if test "x$has_forbidden_chars" != x; then 22888 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 22889 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 22890 fi 22891 22892 # Output is in $new_path 22893 22894 windows_path="$new_path" 22895 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22896 unix_path=`$CYGPATH -u "$windows_path"` 22897 new_path="$unix_path" 22898 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22899 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22900 new_path="$unix_path" 22901 fi 22902 22903 # remove trailing .exe if any 22904 new_path="${new_path/%.exe/}" 22905 22906 # Save the first 10 bytes of this path to the storage, so fixpath can work. 22907 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 22908 fi 22909 22910 else 22911 # We're on a posix platform. Hooray! :) 22912 # First separate the path from the arguments. This will split at the first 22913 # space. 22914 complete="$AR" 22915 path="${complete%% *}" 22916 tmp="$complete EOL" 22917 arguments="${tmp#* }" 22918 22919 # Cannot rely on the command "which" here since it doesn't always work. 22920 is_absolute_path=`$ECHO "$path" | $GREP ^/` 22921 if test -z "$is_absolute_path"; then 22922 # Path to executable is not absolute. Find it. 22923 IFS_save="$IFS" 22924 IFS=: 22925 for p in $PATH; do 22926 if test -f "$p/$path" && test -x "$p/$path"; then 22927 new_path="$p/$path" 22928 break 22929 fi 22930 done 22931 IFS="$IFS_save" 22932 else 22933 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving AR (as $path) failed, using $path directly." >&5 22934 $as_echo "$as_me: Resolving AR (as $path) failed, using $path directly." >&6;} 22935 new_path="$path" 22936 fi 22937 22938 if test "x$new_path" = x; then 22939 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 22940 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 22941 has_space=`$ECHO "$complete" | $GREP " "` 22942 if test "x$has_space" != x; then 22943 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 22944 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 22945 fi 22946 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 22947 fi 22948 fi 22949 22950 # Now join together the path and the arguments once again 22951 if test "x$arguments" != xEOL; then 22952 new_complete="$new_path ${arguments% *}" 22953 else 22954 new_complete="$new_path" 22955 fi 22956 22957 if test "x$complete" != "x$new_complete"; then 22958 AR="$new_complete" 22959 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5 22960 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;} 22961 fi 22962 22963 fi 22964 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 22965 ARFLAGS="-r" 22966 else 22967 ARFLAGS="" 22968 fi 22969 22970 22971 # For hotspot, we need these in Windows mixed path; other platforms keep them the same 22972 HOTSPOT_CXX="$CXX" 22973 HOTSPOT_LD="$LD" 22974 22975 22976 22977 COMPILER_NAME=gcc 22978 COMPILER_TYPE=CC 22979 if test "x$OPENJDK_TARGET_OS" = xwindows; then : 22980 22981 # For now, assume that we are always compiling using cl.exe. 22982 CC_OUT_OPTION=-Fo 22983 EXE_OUT_OPTION=-out: 22984 LD_OUT_OPTION=-out: 22985 AR_OUT_OPTION=-out: 22986 # On Windows, reject /usr/bin/link (as determined in CYGWIN_LINK), which is a cygwin 22987 # program for something completely different. 22988 # Extract the first word of "link", so it can be a program name with args. 22989 set dummy link; ac_word=$2 22990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22991 $as_echo_n "checking for $ac_word... " >&6; } 22992 if ${ac_cv_prog_WINLD+:} false; then : 22993 $as_echo_n "(cached) " >&6 22994 else 22995 if test -n "$WINLD"; then 22996 ac_cv_prog_WINLD="$WINLD" # Let the user override the test. 22997 else 22998 ac_prog_rejected=no 22999 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23000 for as_dir in $PATH 23001 do 23002 IFS=$as_save_IFS 23003 test -z "$as_dir" && as_dir=. 23004 for ac_exec_ext in '' $ac_executable_extensions; do 23005 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 23006 if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then 23007 ac_prog_rejected=yes 23008 continue 23009 fi 23010 ac_cv_prog_WINLD="link" 23011 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23012 break 2 23013 fi 23014 done 23015 done 23016 IFS=$as_save_IFS 23017 23018 if test $ac_prog_rejected = yes; then 23019 # We found a bogon in the path, so make sure we never use it. 23020 set dummy $ac_cv_prog_WINLD 23021 shift 23022 if test $# != 0; then 23023 # We chose a different compiler from the bogus one. 23024 # However, it has the same basename, so the bogon will be chosen 23025 # first if we set WINLD to just the basename; use the full file name. 23026 shift 23027 ac_cv_prog_WINLD="$as_dir/$ac_word${1+' '}$@" 23028 fi 23029 fi 23030 fi 23031 fi 23032 WINLD=$ac_cv_prog_WINLD 23033 if test -n "$WINLD"; then 23034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINLD" >&5 23035 $as_echo "$WINLD" >&6; } 23036 else 23037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23038 $as_echo "no" >&6; } 23039 fi 23040 23041 23042 # Since we must ignore the first found link, WINLD will contain 23043 # the full path to the link.exe program. 23044 23045 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23046 23047 # First separate the path from the arguments. This will split at the first 23048 # space. 23049 complete="$WINLD" 23050 path="${complete%% *}" 23051 tmp="$complete EOL" 23052 arguments="${tmp#* }" 23053 23054 # Input might be given as Windows format, start by converting to 23055 # unix format. 23056 new_path=`$CYGPATH -u "$path"` 23057 23058 # Now try to locate executable using which 23059 new_path=`$WHICH "$new_path" 2> /dev/null` 23060 # bat and cmd files are not always considered executable in cygwin causing which 23061 # to not find them 23062 if test "x$new_path" = x \ 23063 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23064 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23065 new_path=`$CYGPATH -u "$path"` 23066 fi 23067 if test "x$new_path" = x; then 23068 # Oops. Which didn't find the executable. 23069 # The splitting of arguments from the executable at a space might have been incorrect, 23070 # since paths with space are more likely in Windows. Give it another try with the whole 23071 # argument. 23072 path="$complete" 23073 arguments="EOL" 23074 new_path=`$CYGPATH -u "$path"` 23075 new_path=`$WHICH "$new_path" 2> /dev/null` 23076 # bat and cmd files are not always considered executable in cygwin causing which 23077 # to not find them 23078 if test "x$new_path" = x \ 23079 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23080 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23081 new_path=`$CYGPATH -u "$path"` 23082 fi 23083 if test "x$new_path" = x; then 23084 # It's still not found. Now this is an unrecoverable error. 23085 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$complete\", is not found." >&5 23086 $as_echo "$as_me: The path of WINLD, which resolves as \"$complete\", is not found." >&6;} 23087 has_space=`$ECHO "$complete" | $GREP " "` 23088 if test "x$has_space" != x; then 23089 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23090 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23091 fi 23092 as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5 23093 fi 23094 fi 23095 23096 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 23097 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 23098 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 23099 # "foo.exe" is OK but "foo" is an error. 23100 # 23101 # This test is therefore slightly more accurate than "test -f" to check for file precense. 23102 # It is also a way to make sure we got the proper file name for the real test later on. 23103 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 23104 if test "x$test_shortpath" = x; then 23105 # Short path failed, file does not exist as specified. 23106 # Try adding .exe or .cmd 23107 if test -f "${new_path}.exe"; then 23108 input_to_shortpath="${new_path}.exe" 23109 elif test -f "${new_path}.cmd"; then 23110 input_to_shortpath="${new_path}.cmd" 23111 else 23112 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$new_path\", is invalid." >&5 23113 $as_echo "$as_me: The path of WINLD, which resolves as \"$new_path\", is invalid." >&6;} 23114 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 23115 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 23116 as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5 23117 fi 23118 else 23119 input_to_shortpath="$new_path" 23120 fi 23121 23122 # Call helper function which possibly converts this using DOS-style short mode. 23123 # If so, the updated path is stored in $new_path. 23124 new_path="$input_to_shortpath" 23125 23126 input_path="$input_to_shortpath" 23127 # Check if we need to convert this using DOS-style short mode. If the path 23128 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23129 # take no chances and rewrite it. 23130 # Note: m4 eats our [], so we need to use [ and ] instead. 23131 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 23132 if test "x$has_forbidden_chars" != x; then 23133 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23134 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 23135 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 23136 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 23137 # Going to short mode and back again did indeed matter. Since short mode is 23138 # case insensitive, let's make it lowercase to improve readability. 23139 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23140 # Now convert it back to Unix-stile (cygpath) 23141 input_path=`$CYGPATH -u "$shortmode_path"` 23142 new_path="$input_path" 23143 fi 23144 fi 23145 23146 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 23147 if test "x$test_cygdrive_prefix" = x; then 23148 # As a simple fix, exclude /usr/bin since it's not a real path. 23149 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 23150 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 23151 # a path prefixed by /cygdrive for fixpath to work. 23152 new_path="$CYGWIN_ROOT_PATH$input_path" 23153 fi 23154 fi 23155 23156 # remove trailing .exe if any 23157 new_path="${new_path/%.exe/}" 23158 23159 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23160 23161 # First separate the path from the arguments. This will split at the first 23162 # space. 23163 complete="$WINLD" 23164 path="${complete%% *}" 23165 tmp="$complete EOL" 23166 arguments="${tmp#* }" 23167 23168 # Input might be given as Windows format, start by converting to 23169 # unix format. 23170 new_path="$path" 23171 23172 windows_path="$new_path" 23173 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23174 unix_path=`$CYGPATH -u "$windows_path"` 23175 new_path="$unix_path" 23176 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23177 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23178 new_path="$unix_path" 23179 fi 23180 23181 23182 # Now try to locate executable using which 23183 new_path=`$WHICH "$new_path" 2> /dev/null` 23184 23185 if test "x$new_path" = x; then 23186 # Oops. Which didn't find the executable. 23187 # The splitting of arguments from the executable at a space might have been incorrect, 23188 # since paths with space are more likely in Windows. Give it another try with the whole 23189 # argument. 23190 path="$complete" 23191 arguments="EOL" 23192 new_path="$path" 23193 23194 windows_path="$new_path" 23195 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23196 unix_path=`$CYGPATH -u "$windows_path"` 23197 new_path="$unix_path" 23198 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23199 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23200 new_path="$unix_path" 23201 fi 23202 23203 23204 new_path=`$WHICH "$new_path" 2> /dev/null` 23205 23206 if test "x$new_path" = x; then 23207 # It's still not found. Now this is an unrecoverable error. 23208 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$complete\", is not found." >&5 23209 $as_echo "$as_me: The path of WINLD, which resolves as \"$complete\", is not found." >&6;} 23210 has_space=`$ECHO "$complete" | $GREP " "` 23211 if test "x$has_space" != x; then 23212 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23213 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23214 fi 23215 as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5 23216 fi 23217 fi 23218 23219 # Now new_path has a complete unix path to the binary 23220 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 23221 # Keep paths in /bin as-is, but remove trailing .exe if any 23222 new_path="${new_path/%.exe/}" 23223 # Do not save /bin paths to all_fixpath_prefixes! 23224 else 23225 # Not in mixed or Windows style, start by that. 23226 new_path=`cmd //c echo $new_path` 23227 23228 input_path="$new_path" 23229 # Check if we need to convert this using DOS-style short mode. If the path 23230 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23231 # take no chances and rewrite it. 23232 # Note: m4 eats our [], so we need to use [ and ] instead. 23233 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 23234 if test "x$has_forbidden_chars" != x; then 23235 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23236 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23237 fi 23238 23239 # Output is in $new_path 23240 23241 windows_path="$new_path" 23242 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23243 unix_path=`$CYGPATH -u "$windows_path"` 23244 new_path="$unix_path" 23245 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23246 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23247 new_path="$unix_path" 23248 fi 23249 23250 # remove trailing .exe if any 23251 new_path="${new_path/%.exe/}" 23252 23253 # Save the first 10 bytes of this path to the storage, so fixpath can work. 23254 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 23255 fi 23256 23257 else 23258 # We're on a posix platform. Hooray! :) 23259 # First separate the path from the arguments. This will split at the first 23260 # space. 23261 complete="$WINLD" 23262 path="${complete%% *}" 23263 tmp="$complete EOL" 23264 arguments="${tmp#* }" 23265 23266 # Cannot rely on the command "which" here since it doesn't always work. 23267 is_absolute_path=`$ECHO "$path" | $GREP ^/` 23268 if test -z "$is_absolute_path"; then 23269 # Path to executable is not absolute. Find it. 23270 IFS_save="$IFS" 23271 IFS=: 23272 for p in $PATH; do 23273 if test -f "$p/$path" && test -x "$p/$path"; then 23274 new_path="$p/$path" 23275 break 23276 fi 23277 done 23278 IFS="$IFS_save" 23279 else 23280 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving WINLD (as $path) failed, using $path directly." >&5 23281 $as_echo "$as_me: Resolving WINLD (as $path) failed, using $path directly." >&6;} 23282 new_path="$path" 23283 fi 23284 23285 if test "x$new_path" = x; then 23286 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$complete\", is not found." >&5 23287 $as_echo "$as_me: The path of WINLD, which resolves as \"$complete\", is not found." >&6;} 23288 has_space=`$ECHO "$complete" | $GREP " "` 23289 if test "x$has_space" != x; then 23290 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 23291 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 23292 fi 23293 as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5 23294 fi 23295 fi 23296 23297 # Now join together the path and the arguments once again 23298 if test "x$arguments" != xEOL; then 23299 new_complete="$new_path ${arguments% *}" 23300 else 23301 new_complete="$new_path" 23302 fi 23303 23304 if test "x$complete" != "x$new_complete"; then 23305 WINLD="$new_complete" 23306 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting WINLD to \"$new_complete\"" >&5 23307 $as_echo "$as_me: Rewriting WINLD to \"$new_complete\"" >&6;} 23308 fi 23309 23310 printf "Windows linker was found at $WINLD\n" 23311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5 23312 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; } 23313 "$WINLD" --version > /dev/null 23314 if test $? -eq 0 ; then 23315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23316 $as_echo "no" >&6; } 23317 as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5 23318 else 23319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23320 $as_echo "yes" >&6; } 23321 fi 23322 LD="$WINLD" 23323 LDEXE="$WINLD" 23324 LDCXX="$WINLD" 23325 LDEXECXX="$WINLD" 23326 23327 # Extract the first word of "mt", so it can be a program name with args. 23328 set dummy mt; ac_word=$2 23329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23330 $as_echo_n "checking for $ac_word... " >&6; } 23331 if ${ac_cv_prog_MT+:} false; then : 23332 $as_echo_n "(cached) " >&6 23333 else 23334 if test -n "$MT"; then 23335 ac_cv_prog_MT="$MT" # Let the user override the test. 23336 else 23337 ac_prog_rejected=no 23338 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23339 for as_dir in $PATH 23340 do 23341 IFS=$as_save_IFS 23342 test -z "$as_dir" && as_dir=. 23343 for ac_exec_ext in '' $ac_executable_extensions; do 23344 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 23345 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then 23346 ac_prog_rejected=yes 23347 continue 23348 fi 23349 ac_cv_prog_MT="mt" 23350 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23351 break 2 23352 fi 23353 done 23354 done 23355 IFS=$as_save_IFS 23356 23357 if test $ac_prog_rejected = yes; then 23358 # We found a bogon in the path, so make sure we never use it. 23359 set dummy $ac_cv_prog_MT 23360 shift 23361 if test $# != 0; then 23362 # We chose a different compiler from the bogus one. 23363 # However, it has the same basename, so the bogon will be chosen 23364 # first if we set MT to just the basename; use the full file name. 23365 shift 23366 ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@" 23367 fi 23368 fi 23369 fi 23370 fi 23371 MT=$ac_cv_prog_MT 23372 if test -n "$MT"; then 23373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 23374 $as_echo "$MT" >&6; } 23375 else 23376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23377 $as_echo "no" >&6; } 23378 fi 23379 23380 23381 23382 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23383 23384 # First separate the path from the arguments. This will split at the first 23385 # space. 23386 complete="$MT" 23387 path="${complete%% *}" 23388 tmp="$complete EOL" 23389 arguments="${tmp#* }" 23390 23391 # Input might be given as Windows format, start by converting to 23392 # unix format. 23393 new_path=`$CYGPATH -u "$path"` 23394 23395 # Now try to locate executable using which 23396 new_path=`$WHICH "$new_path" 2> /dev/null` 23397 # bat and cmd files are not always considered executable in cygwin causing which 23398 # to not find them 23399 if test "x$new_path" = x \ 23400 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23401 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23402 new_path=`$CYGPATH -u "$path"` 23403 fi 23404 if test "x$new_path" = x; then 23405 # Oops. Which didn't find the executable. 23406 # The splitting of arguments from the executable at a space might have been incorrect, 23407 # since paths with space are more likely in Windows. Give it another try with the whole 23408 # argument. 23409 path="$complete" 23410 arguments="EOL" 23411 new_path=`$CYGPATH -u "$path"` 23412 new_path=`$WHICH "$new_path" 2> /dev/null` 23413 # bat and cmd files are not always considered executable in cygwin causing which 23414 # to not find them 23415 if test "x$new_path" = x \ 23416 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23417 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23418 new_path=`$CYGPATH -u "$path"` 23419 fi 23420 if test "x$new_path" = x; then 23421 # It's still not found. Now this is an unrecoverable error. 23422 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 23423 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 23424 has_space=`$ECHO "$complete" | $GREP " "` 23425 if test "x$has_space" != x; then 23426 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23427 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23428 fi 23429 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 23430 fi 23431 fi 23432 23433 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 23434 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 23435 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 23436 # "foo.exe" is OK but "foo" is an error. 23437 # 23438 # This test is therefore slightly more accurate than "test -f" to check for file precense. 23439 # It is also a way to make sure we got the proper file name for the real test later on. 23440 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 23441 if test "x$test_shortpath" = x; then 23442 # Short path failed, file does not exist as specified. 23443 # Try adding .exe or .cmd 23444 if test -f "${new_path}.exe"; then 23445 input_to_shortpath="${new_path}.exe" 23446 elif test -f "${new_path}.cmd"; then 23447 input_to_shortpath="${new_path}.cmd" 23448 else 23449 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5 23450 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;} 23451 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 23452 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 23453 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 23454 fi 23455 else 23456 input_to_shortpath="$new_path" 23457 fi 23458 23459 # Call helper function which possibly converts this using DOS-style short mode. 23460 # If so, the updated path is stored in $new_path. 23461 new_path="$input_to_shortpath" 23462 23463 input_path="$input_to_shortpath" 23464 # Check if we need to convert this using DOS-style short mode. If the path 23465 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23466 # take no chances and rewrite it. 23467 # Note: m4 eats our [], so we need to use [ and ] instead. 23468 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 23469 if test "x$has_forbidden_chars" != x; then 23470 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23471 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 23472 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 23473 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 23474 # Going to short mode and back again did indeed matter. Since short mode is 23475 # case insensitive, let's make it lowercase to improve readability. 23476 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23477 # Now convert it back to Unix-stile (cygpath) 23478 input_path=`$CYGPATH -u "$shortmode_path"` 23479 new_path="$input_path" 23480 fi 23481 fi 23482 23483 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 23484 if test "x$test_cygdrive_prefix" = x; then 23485 # As a simple fix, exclude /usr/bin since it's not a real path. 23486 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 23487 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 23488 # a path prefixed by /cygdrive for fixpath to work. 23489 new_path="$CYGWIN_ROOT_PATH$input_path" 23490 fi 23491 fi 23492 23493 # remove trailing .exe if any 23494 new_path="${new_path/%.exe/}" 23495 23496 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23497 23498 # First separate the path from the arguments. This will split at the first 23499 # space. 23500 complete="$MT" 23501 path="${complete%% *}" 23502 tmp="$complete EOL" 23503 arguments="${tmp#* }" 23504 23505 # Input might be given as Windows format, start by converting to 23506 # unix format. 23507 new_path="$path" 23508 23509 windows_path="$new_path" 23510 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23511 unix_path=`$CYGPATH -u "$windows_path"` 23512 new_path="$unix_path" 23513 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23514 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23515 new_path="$unix_path" 23516 fi 23517 23518 23519 # Now try to locate executable using which 23520 new_path=`$WHICH "$new_path" 2> /dev/null` 23521 23522 if test "x$new_path" = x; then 23523 # Oops. Which didn't find the executable. 23524 # The splitting of arguments from the executable at a space might have been incorrect, 23525 # since paths with space are more likely in Windows. Give it another try with the whole 23526 # argument. 23527 path="$complete" 23528 arguments="EOL" 23529 new_path="$path" 23530 23531 windows_path="$new_path" 23532 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23533 unix_path=`$CYGPATH -u "$windows_path"` 23534 new_path="$unix_path" 23535 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23536 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23537 new_path="$unix_path" 23538 fi 23539 23540 23541 new_path=`$WHICH "$new_path" 2> /dev/null` 23542 23543 if test "x$new_path" = x; then 23544 # It's still not found. Now this is an unrecoverable error. 23545 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 23546 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 23547 has_space=`$ECHO "$complete" | $GREP " "` 23548 if test "x$has_space" != x; then 23549 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23550 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23551 fi 23552 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 23553 fi 23554 fi 23555 23556 # Now new_path has a complete unix path to the binary 23557 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 23558 # Keep paths in /bin as-is, but remove trailing .exe if any 23559 new_path="${new_path/%.exe/}" 23560 # Do not save /bin paths to all_fixpath_prefixes! 23561 else 23562 # Not in mixed or Windows style, start by that. 23563 new_path=`cmd //c echo $new_path` 23564 23565 input_path="$new_path" 23566 # Check if we need to convert this using DOS-style short mode. If the path 23567 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23568 # take no chances and rewrite it. 23569 # Note: m4 eats our [], so we need to use [ and ] instead. 23570 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 23571 if test "x$has_forbidden_chars" != x; then 23572 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23573 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23574 fi 23575 23576 # Output is in $new_path 23577 23578 windows_path="$new_path" 23579 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23580 unix_path=`$CYGPATH -u "$windows_path"` 23581 new_path="$unix_path" 23582 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23583 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23584 new_path="$unix_path" 23585 fi 23586 23587 # remove trailing .exe if any 23588 new_path="${new_path/%.exe/}" 23589 23590 # Save the first 10 bytes of this path to the storage, so fixpath can work. 23591 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 23592 fi 23593 23594 else 23595 # We're on a posix platform. Hooray! :) 23596 # First separate the path from the arguments. This will split at the first 23597 # space. 23598 complete="$MT" 23599 path="${complete%% *}" 23600 tmp="$complete EOL" 23601 arguments="${tmp#* }" 23602 23603 # Cannot rely on the command "which" here since it doesn't always work. 23604 is_absolute_path=`$ECHO "$path" | $GREP ^/` 23605 if test -z "$is_absolute_path"; then 23606 # Path to executable is not absolute. Find it. 23607 IFS_save="$IFS" 23608 IFS=: 23609 for p in $PATH; do 23610 if test -f "$p/$path" && test -x "$p/$path"; then 23611 new_path="$p/$path" 23612 break 23613 fi 23614 done 23615 IFS="$IFS_save" 23616 else 23617 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving MT (as $path) failed, using $path directly." >&5 23618 $as_echo "$as_me: Resolving MT (as $path) failed, using $path directly." >&6;} 23619 new_path="$path" 23620 fi 23621 23622 if test "x$new_path" = x; then 23623 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 23624 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 23625 has_space=`$ECHO "$complete" | $GREP " "` 23626 if test "x$has_space" != x; then 23627 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 23628 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 23629 fi 23630 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 23631 fi 23632 fi 23633 23634 # Now join together the path and the arguments once again 23635 if test "x$arguments" != xEOL; then 23636 new_complete="$new_path ${arguments% *}" 23637 else 23638 new_complete="$new_path" 23639 fi 23640 23641 if test "x$complete" != "x$new_complete"; then 23642 MT="$new_complete" 23643 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5 23644 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;} 23645 fi 23646 23647 # The resource compiler 23648 # Extract the first word of "rc", so it can be a program name with args. 23649 set dummy rc; ac_word=$2 23650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23651 $as_echo_n "checking for $ac_word... " >&6; } 23652 if ${ac_cv_prog_RC+:} false; then : 23653 $as_echo_n "(cached) " >&6 23654 else 23655 if test -n "$RC"; then 23656 ac_cv_prog_RC="$RC" # Let the user override the test. 23657 else 23658 ac_prog_rejected=no 23659 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23660 for as_dir in $PATH 23661 do 23662 IFS=$as_save_IFS 23663 test -z "$as_dir" && as_dir=. 23664 for ac_exec_ext in '' $ac_executable_extensions; do 23665 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 23666 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then 23667 ac_prog_rejected=yes 23668 continue 23669 fi 23670 ac_cv_prog_RC="rc" 23671 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23672 break 2 23673 fi 23674 done 23675 done 23676 IFS=$as_save_IFS 23677 23678 if test $ac_prog_rejected = yes; then 23679 # We found a bogon in the path, so make sure we never use it. 23680 set dummy $ac_cv_prog_RC 23681 shift 23682 if test $# != 0; then 23683 # We chose a different compiler from the bogus one. 23684 # However, it has the same basename, so the bogon will be chosen 23685 # first if we set RC to just the basename; use the full file name. 23686 shift 23687 ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@" 23688 fi 23689 fi 23690 fi 23691 fi 23692 RC=$ac_cv_prog_RC 23693 if test -n "$RC"; then 23694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5 23695 $as_echo "$RC" >&6; } 23696 else 23697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23698 $as_echo "no" >&6; } 23699 fi 23700 23701 23702 23703 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23704 23705 # First separate the path from the arguments. This will split at the first 23706 # space. 23707 complete="$RC" 23708 path="${complete%% *}" 23709 tmp="$complete EOL" 23710 arguments="${tmp#* }" 23711 23712 # Input might be given as Windows format, start by converting to 23713 # unix format. 23714 new_path=`$CYGPATH -u "$path"` 23715 23716 # Now try to locate executable using which 23717 new_path=`$WHICH "$new_path" 2> /dev/null` 23718 # bat and cmd files are not always considered executable in cygwin causing which 23719 # to not find them 23720 if test "x$new_path" = x \ 23721 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23722 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23723 new_path=`$CYGPATH -u "$path"` 23724 fi 23725 if test "x$new_path" = x; then 23726 # Oops. Which didn't find the executable. 23727 # The splitting of arguments from the executable at a space might have been incorrect, 23728 # since paths with space are more likely in Windows. Give it another try with the whole 23729 # argument. 23730 path="$complete" 23731 arguments="EOL" 23732 new_path=`$CYGPATH -u "$path"` 23733 new_path=`$WHICH "$new_path" 2> /dev/null` 23734 # bat and cmd files are not always considered executable in cygwin causing which 23735 # to not find them 23736 if test "x$new_path" = x \ 23737 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23738 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23739 new_path=`$CYGPATH -u "$path"` 23740 fi 23741 if test "x$new_path" = x; then 23742 # It's still not found. Now this is an unrecoverable error. 23743 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 23744 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 23745 has_space=`$ECHO "$complete" | $GREP " "` 23746 if test "x$has_space" != x; then 23747 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23748 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23749 fi 23750 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 23751 fi 23752 fi 23753 23754 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 23755 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 23756 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 23757 # "foo.exe" is OK but "foo" is an error. 23758 # 23759 # This test is therefore slightly more accurate than "test -f" to check for file precense. 23760 # It is also a way to make sure we got the proper file name for the real test later on. 23761 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 23762 if test "x$test_shortpath" = x; then 23763 # Short path failed, file does not exist as specified. 23764 # Try adding .exe or .cmd 23765 if test -f "${new_path}.exe"; then 23766 input_to_shortpath="${new_path}.exe" 23767 elif test -f "${new_path}.cmd"; then 23768 input_to_shortpath="${new_path}.cmd" 23769 else 23770 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5 23771 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;} 23772 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 23773 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 23774 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 23775 fi 23776 else 23777 input_to_shortpath="$new_path" 23778 fi 23779 23780 # Call helper function which possibly converts this using DOS-style short mode. 23781 # If so, the updated path is stored in $new_path. 23782 new_path="$input_to_shortpath" 23783 23784 input_path="$input_to_shortpath" 23785 # Check if we need to convert this using DOS-style short mode. If the path 23786 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23787 # take no chances and rewrite it. 23788 # Note: m4 eats our [], so we need to use [ and ] instead. 23789 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 23790 if test "x$has_forbidden_chars" != x; then 23791 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23792 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 23793 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 23794 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 23795 # Going to short mode and back again did indeed matter. Since short mode is 23796 # case insensitive, let's make it lowercase to improve readability. 23797 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23798 # Now convert it back to Unix-stile (cygpath) 23799 input_path=`$CYGPATH -u "$shortmode_path"` 23800 new_path="$input_path" 23801 fi 23802 fi 23803 23804 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 23805 if test "x$test_cygdrive_prefix" = x; then 23806 # As a simple fix, exclude /usr/bin since it's not a real path. 23807 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 23808 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 23809 # a path prefixed by /cygdrive for fixpath to work. 23810 new_path="$CYGWIN_ROOT_PATH$input_path" 23811 fi 23812 fi 23813 23814 # remove trailing .exe if any 23815 new_path="${new_path/%.exe/}" 23816 23817 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23818 23819 # First separate the path from the arguments. This will split at the first 23820 # space. 23821 complete="$RC" 23822 path="${complete%% *}" 23823 tmp="$complete EOL" 23824 arguments="${tmp#* }" 23825 23826 # Input might be given as Windows format, start by converting to 23827 # unix format. 23828 new_path="$path" 23829 23830 windows_path="$new_path" 23831 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23832 unix_path=`$CYGPATH -u "$windows_path"` 23833 new_path="$unix_path" 23834 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23835 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23836 new_path="$unix_path" 23837 fi 23838 23839 23840 # Now try to locate executable using which 23841 new_path=`$WHICH "$new_path" 2> /dev/null` 23842 23843 if test "x$new_path" = x; then 23844 # Oops. Which didn't find the executable. 23845 # The splitting of arguments from the executable at a space might have been incorrect, 23846 # since paths with space are more likely in Windows. Give it another try with the whole 23847 # argument. 23848 path="$complete" 23849 arguments="EOL" 23850 new_path="$path" 23851 23852 windows_path="$new_path" 23853 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23854 unix_path=`$CYGPATH -u "$windows_path"` 23855 new_path="$unix_path" 23856 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23857 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23858 new_path="$unix_path" 23859 fi 23860 23861 23862 new_path=`$WHICH "$new_path" 2> /dev/null` 23863 23864 if test "x$new_path" = x; then 23865 # It's still not found. Now this is an unrecoverable error. 23866 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 23867 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 23868 has_space=`$ECHO "$complete" | $GREP " "` 23869 if test "x$has_space" != x; then 23870 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23871 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23872 fi 23873 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 23874 fi 23875 fi 23876 23877 # Now new_path has a complete unix path to the binary 23878 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 23879 # Keep paths in /bin as-is, but remove trailing .exe if any 23880 new_path="${new_path/%.exe/}" 23881 # Do not save /bin paths to all_fixpath_prefixes! 23882 else 23883 # Not in mixed or Windows style, start by that. 23884 new_path=`cmd //c echo $new_path` 23885 23886 input_path="$new_path" 23887 # Check if we need to convert this using DOS-style short mode. If the path 23888 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23889 # take no chances and rewrite it. 23890 # Note: m4 eats our [], so we need to use [ and ] instead. 23891 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 23892 if test "x$has_forbidden_chars" != x; then 23893 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23894 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23895 fi 23896 23897 # Output is in $new_path 23898 23899 windows_path="$new_path" 23900 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23901 unix_path=`$CYGPATH -u "$windows_path"` 23902 new_path="$unix_path" 23903 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23904 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23905 new_path="$unix_path" 23906 fi 23907 23908 # remove trailing .exe if any 23909 new_path="${new_path/%.exe/}" 23910 23911 # Save the first 10 bytes of this path to the storage, so fixpath can work. 23912 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 23913 fi 23914 23915 else 23916 # We're on a posix platform. Hooray! :) 23917 # First separate the path from the arguments. This will split at the first 23918 # space. 23919 complete="$RC" 23920 path="${complete%% *}" 23921 tmp="$complete EOL" 23922 arguments="${tmp#* }" 23923 23924 # Cannot rely on the command "which" here since it doesn't always work. 23925 is_absolute_path=`$ECHO "$path" | $GREP ^/` 23926 if test -z "$is_absolute_path"; then 23927 # Path to executable is not absolute. Find it. 23928 IFS_save="$IFS" 23929 IFS=: 23930 for p in $PATH; do 23931 if test -f "$p/$path" && test -x "$p/$path"; then 23932 new_path="$p/$path" 23933 break 23934 fi 23935 done 23936 IFS="$IFS_save" 23937 else 23938 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving RC (as $path) failed, using $path directly." >&5 23939 $as_echo "$as_me: Resolving RC (as $path) failed, using $path directly." >&6;} 23940 new_path="$path" 23941 fi 23942 23943 if test "x$new_path" = x; then 23944 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 23945 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 23946 has_space=`$ECHO "$complete" | $GREP " "` 23947 if test "x$has_space" != x; then 23948 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 23949 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 23950 fi 23951 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 23952 fi 23953 fi 23954 23955 # Now join together the path and the arguments once again 23956 if test "x$arguments" != xEOL; then 23957 new_complete="$new_path ${arguments% *}" 23958 else 23959 new_complete="$new_path" 23960 fi 23961 23962 if test "x$complete" != "x$new_complete"; then 23963 RC="$new_complete" 23964 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5 23965 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;} 23966 fi 23967 23968 23969 # For hotspot, we need these in Windows mixed path, 23970 # so rewrite them all. Need added .exe suffix. 23971 HOTSPOT_CXX="$CXX.exe" 23972 HOTSPOT_LD="$LD.exe" 23973 HOTSPOT_MT="$MT.exe" 23974 HOTSPOT_RC="$RC.exe" 23975 23976 unix_path="$HOTSPOT_CXX" 23977 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23978 windows_path=`$CYGPATH -m "$unix_path"` 23979 HOTSPOT_CXX="$windows_path" 23980 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23981 windows_path=`cmd //c echo $unix_path` 23982 HOTSPOT_CXX="$windows_path" 23983 fi 23984 23985 23986 unix_path="$HOTSPOT_LD" 23987 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23988 windows_path=`$CYGPATH -m "$unix_path"` 23989 HOTSPOT_LD="$windows_path" 23990 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23991 windows_path=`cmd //c echo $unix_path` 23992 HOTSPOT_LD="$windows_path" 23993 fi 23994 23995 23996 unix_path="$HOTSPOT_MT" 23997 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23998 windows_path=`$CYGPATH -m "$unix_path"` 23999 HOTSPOT_MT="$windows_path" 24000 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24001 windows_path=`cmd //c echo $unix_path` 24002 HOTSPOT_MT="$windows_path" 24003 fi 24004 24005 24006 unix_path="$HOTSPOT_RC" 24007 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24008 windows_path=`$CYGPATH -m "$unix_path"` 24009 HOTSPOT_RC="$windows_path" 24010 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24011 windows_path=`cmd //c echo $unix_path` 24012 HOTSPOT_RC="$windows_path" 24013 fi 24014 24015 24016 24017 24018 RC_FLAGS="-nologo -l 0x409 -r" 24019 if test "x$VARIANT" = xOPT; then : 24020 24021 RC_FLAGS="$RC_FLAGS -d NDEBUG" 24022 24023 fi 24024 JDK_UPDATE_VERSION_NOTNULL=$JDK_UPDATE_VERSION 24025 if test "x$JDK_UPDATE_VERSION" = x; then : 24026 24027 JDK_UPDATE_VERSION_NOTNULL=0 24028 24029 fi 24030 RC_FLAGS="$RC_FLAGS -d \"JDK_BUILD_ID=$FULL_VERSION\"" 24031 RC_FLAGS="$RC_FLAGS -d \"JDK_COMPANY=$COMPANY_NAME\"" 24032 RC_FLAGS="$RC_FLAGS -d \"JDK_COMPONENT=$PRODUCT_NAME $JDK_RC_PLATFORM_NAME binary\"" 24033 RC_FLAGS="$RC_FLAGS -d \"JDK_VER=$JDK_MINOR_VERSION.$JDK_MICRO_VERSION.$JDK_UPDATE_VERSION_NOTNULL.$COOKED_BUILD_NUMBER\"" 24034 RC_FLAGS="$RC_FLAGS -d \"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\"" 24035 RC_FLAGS="$RC_FLAGS -d \"JDK_NAME=$PRODUCT_NAME $JDK_RC_PLATFORM_NAME $JDK_MINOR_VERSION $JDK_UPDATE_META_TAG\"" 24036 RC_FLAGS="$RC_FLAGS -d \"JDK_FVER=$JDK_MINOR_VERSION,$JDK_MICRO_VERSION,$JDK_UPDATE_VERSION_NOTNULL,$COOKED_BUILD_NUMBER\"" 24037 24038 # lib.exe is used to create static libraries. 24039 # Extract the first word of "lib", so it can be a program name with args. 24040 set dummy lib; ac_word=$2 24041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24042 $as_echo_n "checking for $ac_word... " >&6; } 24043 if ${ac_cv_prog_WINAR+:} false; then : 24044 $as_echo_n "(cached) " >&6 24045 else 24046 if test -n "$WINAR"; then 24047 ac_cv_prog_WINAR="$WINAR" # Let the user override the test. 24048 else 24049 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24050 for as_dir in $PATH 24051 do 24052 IFS=$as_save_IFS 24053 test -z "$as_dir" && as_dir=. 24054 for ac_exec_ext in '' $ac_executable_extensions; do 24055 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 24056 ac_cv_prog_WINAR="lib" 24057 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24058 break 2 24059 fi 24060 done 24061 done 24062 IFS=$as_save_IFS 24063 24064 fi 24065 fi 24066 WINAR=$ac_cv_prog_WINAR 24067 if test -n "$WINAR"; then 24068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINAR" >&5 24069 $as_echo "$WINAR" >&6; } 24070 else 24071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24072 $as_echo "no" >&6; } 24073 fi 24074 24075 24076 24077 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24078 24079 # First separate the path from the arguments. This will split at the first 24080 # space. 24081 complete="$WINAR" 24082 path="${complete%% *}" 24083 tmp="$complete EOL" 24084 arguments="${tmp#* }" 24085 24086 # Input might be given as Windows format, start by converting to 24087 # unix format. 24088 new_path=`$CYGPATH -u "$path"` 24089 24090 # Now try to locate executable using which 24091 new_path=`$WHICH "$new_path" 2> /dev/null` 24092 # bat and cmd files are not always considered executable in cygwin causing which 24093 # to not find them 24094 if test "x$new_path" = x \ 24095 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 24096 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 24097 new_path=`$CYGPATH -u "$path"` 24098 fi 24099 if test "x$new_path" = x; then 24100 # Oops. Which didn't find the executable. 24101 # The splitting of arguments from the executable at a space might have been incorrect, 24102 # since paths with space are more likely in Windows. Give it another try with the whole 24103 # argument. 24104 path="$complete" 24105 arguments="EOL" 24106 new_path=`$CYGPATH -u "$path"` 24107 new_path=`$WHICH "$new_path" 2> /dev/null` 24108 # bat and cmd files are not always considered executable in cygwin causing which 24109 # to not find them 24110 if test "x$new_path" = x \ 24111 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 24112 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 24113 new_path=`$CYGPATH -u "$path"` 24114 fi 24115 if test "x$new_path" = x; then 24116 # It's still not found. Now this is an unrecoverable error. 24117 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$complete\", is not found." >&5 24118 $as_echo "$as_me: The path of WINAR, which resolves as \"$complete\", is not found." >&6;} 24119 has_space=`$ECHO "$complete" | $GREP " "` 24120 if test "x$has_space" != x; then 24121 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24122 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24123 fi 24124 as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5 24125 fi 24126 fi 24127 24128 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24129 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24130 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24131 # "foo.exe" is OK but "foo" is an error. 24132 # 24133 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24134 # It is also a way to make sure we got the proper file name for the real test later on. 24135 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24136 if test "x$test_shortpath" = x; then 24137 # Short path failed, file does not exist as specified. 24138 # Try adding .exe or .cmd 24139 if test -f "${new_path}.exe"; then 24140 input_to_shortpath="${new_path}.exe" 24141 elif test -f "${new_path}.cmd"; then 24142 input_to_shortpath="${new_path}.cmd" 24143 else 24144 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$new_path\", is invalid." >&5 24145 $as_echo "$as_me: The path of WINAR, which resolves as \"$new_path\", is invalid." >&6;} 24146 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 24147 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 24148 as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5 24149 fi 24150 else 24151 input_to_shortpath="$new_path" 24152 fi 24153 24154 # Call helper function which possibly converts this using DOS-style short mode. 24155 # If so, the updated path is stored in $new_path. 24156 new_path="$input_to_shortpath" 24157 24158 input_path="$input_to_shortpath" 24159 # Check if we need to convert this using DOS-style short mode. If the path 24160 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24161 # take no chances and rewrite it. 24162 # Note: m4 eats our [], so we need to use [ and ] instead. 24163 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24164 if test "x$has_forbidden_chars" != x; then 24165 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24166 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24167 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24168 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24169 # Going to short mode and back again did indeed matter. Since short mode is 24170 # case insensitive, let's make it lowercase to improve readability. 24171 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24172 # Now convert it back to Unix-stile (cygpath) 24173 input_path=`$CYGPATH -u "$shortmode_path"` 24174 new_path="$input_path" 24175 fi 24176 fi 24177 24178 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24179 if test "x$test_cygdrive_prefix" = x; then 24180 # As a simple fix, exclude /usr/bin since it's not a real path. 24181 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 24182 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24183 # a path prefixed by /cygdrive for fixpath to work. 24184 new_path="$CYGWIN_ROOT_PATH$input_path" 24185 fi 24186 fi 24187 24188 # remove trailing .exe if any 24189 new_path="${new_path/%.exe/}" 24190 24191 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24192 24193 # First separate the path from the arguments. This will split at the first 24194 # space. 24195 complete="$WINAR" 24196 path="${complete%% *}" 24197 tmp="$complete EOL" 24198 arguments="${tmp#* }" 24199 24200 # Input might be given as Windows format, start by converting to 24201 # unix format. 24202 new_path="$path" 24203 24204 windows_path="$new_path" 24205 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24206 unix_path=`$CYGPATH -u "$windows_path"` 24207 new_path="$unix_path" 24208 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24209 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24210 new_path="$unix_path" 24211 fi 24212 24213 24214 # Now try to locate executable using which 24215 new_path=`$WHICH "$new_path" 2> /dev/null` 24216 24217 if test "x$new_path" = x; then 24218 # Oops. Which didn't find the executable. 24219 # The splitting of arguments from the executable at a space might have been incorrect, 24220 # since paths with space are more likely in Windows. Give it another try with the whole 24221 # argument. 24222 path="$complete" 24223 arguments="EOL" 24224 new_path="$path" 24225 24226 windows_path="$new_path" 24227 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24228 unix_path=`$CYGPATH -u "$windows_path"` 24229 new_path="$unix_path" 24230 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24231 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24232 new_path="$unix_path" 24233 fi 24234 24235 24236 new_path=`$WHICH "$new_path" 2> /dev/null` 24237 24238 if test "x$new_path" = x; then 24239 # It's still not found. Now this is an unrecoverable error. 24240 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$complete\", is not found." >&5 24241 $as_echo "$as_me: The path of WINAR, which resolves as \"$complete\", is not found." >&6;} 24242 has_space=`$ECHO "$complete" | $GREP " "` 24243 if test "x$has_space" != x; then 24244 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24245 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24246 fi 24247 as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5 24248 fi 24249 fi 24250 24251 # Now new_path has a complete unix path to the binary 24252 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 24253 # Keep paths in /bin as-is, but remove trailing .exe if any 24254 new_path="${new_path/%.exe/}" 24255 # Do not save /bin paths to all_fixpath_prefixes! 24256 else 24257 # Not in mixed or Windows style, start by that. 24258 new_path=`cmd //c echo $new_path` 24259 24260 input_path="$new_path" 24261 # Check if we need to convert this using DOS-style short mode. If the path 24262 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24263 # take no chances and rewrite it. 24264 # Note: m4 eats our [], so we need to use [ and ] instead. 24265 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24266 if test "x$has_forbidden_chars" != x; then 24267 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24268 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24269 fi 24270 24271 # Output is in $new_path 24272 24273 windows_path="$new_path" 24274 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24275 unix_path=`$CYGPATH -u "$windows_path"` 24276 new_path="$unix_path" 24277 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24278 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24279 new_path="$unix_path" 24280 fi 24281 24282 # remove trailing .exe if any 24283 new_path="${new_path/%.exe/}" 24284 24285 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24286 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24287 fi 24288 24289 else 24290 # We're on a posix platform. Hooray! :) 24291 # First separate the path from the arguments. This will split at the first 24292 # space. 24293 complete="$WINAR" 24294 path="${complete%% *}" 24295 tmp="$complete EOL" 24296 arguments="${tmp#* }" 24297 24298 # Cannot rely on the command "which" here since it doesn't always work. 24299 is_absolute_path=`$ECHO "$path" | $GREP ^/` 24300 if test -z "$is_absolute_path"; then 24301 # Path to executable is not absolute. Find it. 24302 IFS_save="$IFS" 24303 IFS=: 24304 for p in $PATH; do 24305 if test -f "$p/$path" && test -x "$p/$path"; then 24306 new_path="$p/$path" 24307 break 24308 fi 24309 done 24310 IFS="$IFS_save" 24311 else 24312 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving WINAR (as $path) failed, using $path directly." >&5 24313 $as_echo "$as_me: Resolving WINAR (as $path) failed, using $path directly." >&6;} 24314 new_path="$path" 24315 fi 24316 24317 if test "x$new_path" = x; then 24318 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$complete\", is not found." >&5 24319 $as_echo "$as_me: The path of WINAR, which resolves as \"$complete\", is not found." >&6;} 24320 has_space=`$ECHO "$complete" | $GREP " "` 24321 if test "x$has_space" != x; then 24322 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 24323 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 24324 fi 24325 as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5 24326 fi 24327 fi 24328 24329 # Now join together the path and the arguments once again 24330 if test "x$arguments" != xEOL; then 24331 new_complete="$new_path ${arguments% *}" 24332 else 24333 new_complete="$new_path" 24334 fi 24335 24336 if test "x$complete" != "x$new_complete"; then 24337 WINAR="$new_complete" 24338 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting WINAR to \"$new_complete\"" >&5 24339 $as_echo "$as_me: Rewriting WINAR to \"$new_complete\"" >&6;} 24340 fi 24341 24342 AR="$WINAR" 24343 ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT" 24344 24345 # Extract the first word of "dumpbin", so it can be a program name with args. 24346 set dummy dumpbin; ac_word=$2 24347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24348 $as_echo_n "checking for $ac_word... " >&6; } 24349 if ${ac_cv_prog_DUMPBIN+:} false; then : 24350 $as_echo_n "(cached) " >&6 24351 else 24352 if test -n "$DUMPBIN"; then 24353 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. 24354 else 24355 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24356 for as_dir in $PATH 24357 do 24358 IFS=$as_save_IFS 24359 test -z "$as_dir" && as_dir=. 24360 for ac_exec_ext in '' $ac_executable_extensions; do 24361 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 24362 ac_cv_prog_DUMPBIN="dumpbin" 24363 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24364 break 2 24365 fi 24366 done 24367 done 24368 IFS=$as_save_IFS 24369 24370 fi 24371 fi 24372 DUMPBIN=$ac_cv_prog_DUMPBIN 24373 if test -n "$DUMPBIN"; then 24374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 24375 $as_echo "$DUMPBIN" >&6; } 24376 else 24377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24378 $as_echo "no" >&6; } 24379 fi 24380 24381 24382 24383 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24384 24385 # First separate the path from the arguments. This will split at the first 24386 # space. 24387 complete="$DUMPBIN" 24388 path="${complete%% *}" 24389 tmp="$complete EOL" 24390 arguments="${tmp#* }" 24391 24392 # Input might be given as Windows format, start by converting to 24393 # unix format. 24394 new_path=`$CYGPATH -u "$path"` 24395 24396 # Now try to locate executable using which 24397 new_path=`$WHICH "$new_path" 2> /dev/null` 24398 # bat and cmd files are not always considered executable in cygwin causing which 24399 # to not find them 24400 if test "x$new_path" = x \ 24401 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 24402 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 24403 new_path=`$CYGPATH -u "$path"` 24404 fi 24405 if test "x$new_path" = x; then 24406 # Oops. Which didn't find the executable. 24407 # The splitting of arguments from the executable at a space might have been incorrect, 24408 # since paths with space are more likely in Windows. Give it another try with the whole 24409 # argument. 24410 path="$complete" 24411 arguments="EOL" 24412 new_path=`$CYGPATH -u "$path"` 24413 new_path=`$WHICH "$new_path" 2> /dev/null` 24414 # bat and cmd files are not always considered executable in cygwin causing which 24415 # to not find them 24416 if test "x$new_path" = x \ 24417 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 24418 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 24419 new_path=`$CYGPATH -u "$path"` 24420 fi 24421 if test "x$new_path" = x; then 24422 # It's still not found. Now this is an unrecoverable error. 24423 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 24424 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 24425 has_space=`$ECHO "$complete" | $GREP " "` 24426 if test "x$has_space" != x; then 24427 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24428 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24429 fi 24430 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 24431 fi 24432 fi 24433 24434 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24435 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24436 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24437 # "foo.exe" is OK but "foo" is an error. 24438 # 24439 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24440 # It is also a way to make sure we got the proper file name for the real test later on. 24441 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24442 if test "x$test_shortpath" = x; then 24443 # Short path failed, file does not exist as specified. 24444 # Try adding .exe or .cmd 24445 if test -f "${new_path}.exe"; then 24446 input_to_shortpath="${new_path}.exe" 24447 elif test -f "${new_path}.cmd"; then 24448 input_to_shortpath="${new_path}.cmd" 24449 else 24450 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5 24451 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;} 24452 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 24453 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 24454 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 24455 fi 24456 else 24457 input_to_shortpath="$new_path" 24458 fi 24459 24460 # Call helper function which possibly converts this using DOS-style short mode. 24461 # If so, the updated path is stored in $new_path. 24462 new_path="$input_to_shortpath" 24463 24464 input_path="$input_to_shortpath" 24465 # Check if we need to convert this using DOS-style short mode. If the path 24466 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24467 # take no chances and rewrite it. 24468 # Note: m4 eats our [], so we need to use [ and ] instead. 24469 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24470 if test "x$has_forbidden_chars" != x; then 24471 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24472 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24473 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24474 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24475 # Going to short mode and back again did indeed matter. Since short mode is 24476 # case insensitive, let's make it lowercase to improve readability. 24477 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24478 # Now convert it back to Unix-stile (cygpath) 24479 input_path=`$CYGPATH -u "$shortmode_path"` 24480 new_path="$input_path" 24481 fi 24482 fi 24483 24484 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24485 if test "x$test_cygdrive_prefix" = x; then 24486 # As a simple fix, exclude /usr/bin since it's not a real path. 24487 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 24488 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24489 # a path prefixed by /cygdrive for fixpath to work. 24490 new_path="$CYGWIN_ROOT_PATH$input_path" 24491 fi 24492 fi 24493 24494 # remove trailing .exe if any 24495 new_path="${new_path/%.exe/}" 24496 24497 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24498 24499 # First separate the path from the arguments. This will split at the first 24500 # space. 24501 complete="$DUMPBIN" 24502 path="${complete%% *}" 24503 tmp="$complete EOL" 24504 arguments="${tmp#* }" 24505 24506 # Input might be given as Windows format, start by converting to 24507 # unix format. 24508 new_path="$path" 24509 24510 windows_path="$new_path" 24511 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24512 unix_path=`$CYGPATH -u "$windows_path"` 24513 new_path="$unix_path" 24514 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24515 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24516 new_path="$unix_path" 24517 fi 24518 24519 24520 # Now try to locate executable using which 24521 new_path=`$WHICH "$new_path" 2> /dev/null` 24522 24523 if test "x$new_path" = x; then 24524 # Oops. Which didn't find the executable. 24525 # The splitting of arguments from the executable at a space might have been incorrect, 24526 # since paths with space are more likely in Windows. Give it another try with the whole 24527 # argument. 24528 path="$complete" 24529 arguments="EOL" 24530 new_path="$path" 24531 24532 windows_path="$new_path" 24533 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24534 unix_path=`$CYGPATH -u "$windows_path"` 24535 new_path="$unix_path" 24536 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24537 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24538 new_path="$unix_path" 24539 fi 24540 24541 24542 new_path=`$WHICH "$new_path" 2> /dev/null` 24543 24544 if test "x$new_path" = x; then 24545 # It's still not found. Now this is an unrecoverable error. 24546 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 24547 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 24548 has_space=`$ECHO "$complete" | $GREP " "` 24549 if test "x$has_space" != x; then 24550 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24551 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24552 fi 24553 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 24554 fi 24555 fi 24556 24557 # Now new_path has a complete unix path to the binary 24558 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 24559 # Keep paths in /bin as-is, but remove trailing .exe if any 24560 new_path="${new_path/%.exe/}" 24561 # Do not save /bin paths to all_fixpath_prefixes! 24562 else 24563 # Not in mixed or Windows style, start by that. 24564 new_path=`cmd //c echo $new_path` 24565 24566 input_path="$new_path" 24567 # Check if we need to convert this using DOS-style short mode. If the path 24568 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24569 # take no chances and rewrite it. 24570 # Note: m4 eats our [], so we need to use [ and ] instead. 24571 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24572 if test "x$has_forbidden_chars" != x; then 24573 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24574 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24575 fi 24576 24577 # Output is in $new_path 24578 24579 windows_path="$new_path" 24580 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24581 unix_path=`$CYGPATH -u "$windows_path"` 24582 new_path="$unix_path" 24583 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24584 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24585 new_path="$unix_path" 24586 fi 24587 24588 # remove trailing .exe if any 24589 new_path="${new_path/%.exe/}" 24590 24591 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24592 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24593 fi 24594 24595 else 24596 # We're on a posix platform. Hooray! :) 24597 # First separate the path from the arguments. This will split at the first 24598 # space. 24599 complete="$DUMPBIN" 24600 path="${complete%% *}" 24601 tmp="$complete EOL" 24602 arguments="${tmp#* }" 24603 24604 # Cannot rely on the command "which" here since it doesn't always work. 24605 is_absolute_path=`$ECHO "$path" | $GREP ^/` 24606 if test -z "$is_absolute_path"; then 24607 # Path to executable is not absolute. Find it. 24608 IFS_save="$IFS" 24609 IFS=: 24610 for p in $PATH; do 24611 if test -f "$p/$path" && test -x "$p/$path"; then 24612 new_path="$p/$path" 24613 break 24614 fi 24615 done 24616 IFS="$IFS_save" 24617 else 24618 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving DUMPBIN (as $path) failed, using $path directly." >&5 24619 $as_echo "$as_me: Resolving DUMPBIN (as $path) failed, using $path directly." >&6;} 24620 new_path="$path" 24621 fi 24622 24623 if test "x$new_path" = x; then 24624 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 24625 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 24626 has_space=`$ECHO "$complete" | $GREP " "` 24627 if test "x$has_space" != x; then 24628 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 24629 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 24630 fi 24631 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 24632 fi 24633 fi 24634 24635 # Now join together the path and the arguments once again 24636 if test "x$arguments" != xEOL; then 24637 new_complete="$new_path ${arguments% *}" 24638 else 24639 new_complete="$new_path" 24640 fi 24641 24642 if test "x$complete" != "x$new_complete"; then 24643 DUMPBIN="$new_complete" 24644 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5 24645 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;} 24646 fi 24647 24648 24649 COMPILER_TYPE=CL 24650 CCXXFLAGS="$CCXXFLAGS -nologo" 24651 24652 fi 24653 24654 24655 24656 ac_ext=c 24657 ac_cpp='$CPP $CPPFLAGS' 24658 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 24659 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 24660 ac_compiler_gnu=$ac_cv_c_compiler_gnu 24661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 24662 $as_echo_n "checking how to run the C preprocessor... " >&6; } 24663 # On Suns, sometimes $CPP names a directory. 24664 if test -n "$CPP" && test -d "$CPP"; then 24665 CPP= 24666 fi 24667 if test -z "$CPP"; then 24668 if ${ac_cv_prog_CPP+:} false; then : 24669 $as_echo_n "(cached) " >&6 24670 else 24671 # Double quotes because CPP needs to be expanded 24672 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 24673 do 24674 ac_preproc_ok=false 24675 for ac_c_preproc_warn_flag in '' yes 24676 do 24677 # Use a header file that comes with gcc, so configuring glibc 24678 # with a fresh cross-compiler works. 24679 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 24680 # <limits.h> exists even on freestanding compilers. 24681 # On the NeXT, cc -E runs the code through the compiler's parser, 24682 # not just through cpp. "Syntax error" is here to catch this case. 24683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24684 /* end confdefs.h. */ 24685 #ifdef __STDC__ 24686 # include <limits.h> 24687 #else 24688 # include <assert.h> 24689 #endif 24690 Syntax error 24691 _ACEOF 24692 if ac_fn_c_try_cpp "$LINENO"; then : 24693 24694 else 24695 # Broken: fails on valid input. 24696 continue 24697 fi 24698 rm -f conftest.err conftest.i conftest.$ac_ext 24699 24700 # OK, works on sane cases. Now check whether nonexistent headers 24701 # can be detected and how. 24702 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24703 /* end confdefs.h. */ 24704 #include <ac_nonexistent.h> 24705 _ACEOF 24706 if ac_fn_c_try_cpp "$LINENO"; then : 24707 # Broken: success on invalid input. 24708 continue 24709 else 24710 # Passes both tests. 24711 ac_preproc_ok=: 24712 break 24713 fi 24714 rm -f conftest.err conftest.i conftest.$ac_ext 24715 24716 done 24717 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 24718 rm -f conftest.i conftest.err conftest.$ac_ext 24719 if $ac_preproc_ok; then : 24720 break 24721 fi 24722 24723 done 24724 ac_cv_prog_CPP=$CPP 24725 24726 fi 24727 CPP=$ac_cv_prog_CPP 24728 else 24729 ac_cv_prog_CPP=$CPP 24730 fi 24731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 24732 $as_echo "$CPP" >&6; } 24733 ac_preproc_ok=false 24734 for ac_c_preproc_warn_flag in '' yes 24735 do 24736 # Use a header file that comes with gcc, so configuring glibc 24737 # with a fresh cross-compiler works. 24738 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 24739 # <limits.h> exists even on freestanding compilers. 24740 # On the NeXT, cc -E runs the code through the compiler's parser, 24741 # not just through cpp. "Syntax error" is here to catch this case. 24742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24743 /* end confdefs.h. */ 24744 #ifdef __STDC__ 24745 # include <limits.h> 24746 #else 24747 # include <assert.h> 24748 #endif 24749 Syntax error 24750 _ACEOF 24751 if ac_fn_c_try_cpp "$LINENO"; then : 24752 24753 else 24754 # Broken: fails on valid input. 24755 continue 24756 fi 24757 rm -f conftest.err conftest.i conftest.$ac_ext 24758 24759 # OK, works on sane cases. Now check whether nonexistent headers 24760 # can be detected and how. 24761 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24762 /* end confdefs.h. */ 24763 #include <ac_nonexistent.h> 24764 _ACEOF 24765 if ac_fn_c_try_cpp "$LINENO"; then : 24766 # Broken: success on invalid input. 24767 continue 24768 else 24769 # Passes both tests. 24770 ac_preproc_ok=: 24771 break 24772 fi 24773 rm -f conftest.err conftest.i conftest.$ac_ext 24774 24775 done 24776 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 24777 rm -f conftest.i conftest.err conftest.$ac_ext 24778 if $ac_preproc_ok; then : 24779 24780 else 24781 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 24782 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 24783 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 24784 See \`config.log' for more details" "$LINENO" 5; } 24785 fi 24786 24787 ac_ext=cpp 24788 ac_cpp='$CXXCPP $CPPFLAGS' 24789 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 24790 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 24791 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 24792 24793 24794 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24795 24796 # First separate the path from the arguments. This will split at the first 24797 # space. 24798 complete="$CPP" 24799 path="${complete%% *}" 24800 tmp="$complete EOL" 24801 arguments="${tmp#* }" 24802 24803 # Input might be given as Windows format, start by converting to 24804 # unix format. 24805 new_path=`$CYGPATH -u "$path"` 24806 24807 # Now try to locate executable using which 24808 new_path=`$WHICH "$new_path" 2> /dev/null` 24809 # bat and cmd files are not always considered executable in cygwin causing which 24810 # to not find them 24811 if test "x$new_path" = x \ 24812 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 24813 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 24814 new_path=`$CYGPATH -u "$path"` 24815 fi 24816 if test "x$new_path" = x; then 24817 # Oops. Which didn't find the executable. 24818 # The splitting of arguments from the executable at a space might have been incorrect, 24819 # since paths with space are more likely in Windows. Give it another try with the whole 24820 # argument. 24821 path="$complete" 24822 arguments="EOL" 24823 new_path=`$CYGPATH -u "$path"` 24824 new_path=`$WHICH "$new_path" 2> /dev/null` 24825 # bat and cmd files are not always considered executable in cygwin causing which 24826 # to not find them 24827 if test "x$new_path" = x \ 24828 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 24829 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 24830 new_path=`$CYGPATH -u "$path"` 24831 fi 24832 if test "x$new_path" = x; then 24833 # It's still not found. Now this is an unrecoverable error. 24834 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 24835 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 24836 has_space=`$ECHO "$complete" | $GREP " "` 24837 if test "x$has_space" != x; then 24838 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24839 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24840 fi 24841 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 24842 fi 24843 fi 24844 24845 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24846 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24847 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24848 # "foo.exe" is OK but "foo" is an error. 24849 # 24850 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24851 # It is also a way to make sure we got the proper file name for the real test later on. 24852 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24853 if test "x$test_shortpath" = x; then 24854 # Short path failed, file does not exist as specified. 24855 # Try adding .exe or .cmd 24856 if test -f "${new_path}.exe"; then 24857 input_to_shortpath="${new_path}.exe" 24858 elif test -f "${new_path}.cmd"; then 24859 input_to_shortpath="${new_path}.cmd" 24860 else 24861 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5 24862 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;} 24863 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 24864 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 24865 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 24866 fi 24867 else 24868 input_to_shortpath="$new_path" 24869 fi 24870 24871 # Call helper function which possibly converts this using DOS-style short mode. 24872 # If so, the updated path is stored in $new_path. 24873 new_path="$input_to_shortpath" 24874 24875 input_path="$input_to_shortpath" 24876 # Check if we need to convert this using DOS-style short mode. If the path 24877 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24878 # take no chances and rewrite it. 24879 # Note: m4 eats our [], so we need to use [ and ] instead. 24880 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24881 if test "x$has_forbidden_chars" != x; then 24882 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24883 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24884 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24885 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24886 # Going to short mode and back again did indeed matter. Since short mode is 24887 # case insensitive, let's make it lowercase to improve readability. 24888 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24889 # Now convert it back to Unix-stile (cygpath) 24890 input_path=`$CYGPATH -u "$shortmode_path"` 24891 new_path="$input_path" 24892 fi 24893 fi 24894 24895 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24896 if test "x$test_cygdrive_prefix" = x; then 24897 # As a simple fix, exclude /usr/bin since it's not a real path. 24898 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 24899 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24900 # a path prefixed by /cygdrive for fixpath to work. 24901 new_path="$CYGWIN_ROOT_PATH$input_path" 24902 fi 24903 fi 24904 24905 # remove trailing .exe if any 24906 new_path="${new_path/%.exe/}" 24907 24908 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24909 24910 # First separate the path from the arguments. This will split at the first 24911 # space. 24912 complete="$CPP" 24913 path="${complete%% *}" 24914 tmp="$complete EOL" 24915 arguments="${tmp#* }" 24916 24917 # Input might be given as Windows format, start by converting to 24918 # unix format. 24919 new_path="$path" 24920 24921 windows_path="$new_path" 24922 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24923 unix_path=`$CYGPATH -u "$windows_path"` 24924 new_path="$unix_path" 24925 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24926 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24927 new_path="$unix_path" 24928 fi 24929 24930 24931 # Now try to locate executable using which 24932 new_path=`$WHICH "$new_path" 2> /dev/null` 24933 24934 if test "x$new_path" = x; then 24935 # Oops. Which didn't find the executable. 24936 # The splitting of arguments from the executable at a space might have been incorrect, 24937 # since paths with space are more likely in Windows. Give it another try with the whole 24938 # argument. 24939 path="$complete" 24940 arguments="EOL" 24941 new_path="$path" 24942 24943 windows_path="$new_path" 24944 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24945 unix_path=`$CYGPATH -u "$windows_path"` 24946 new_path="$unix_path" 24947 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24948 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24949 new_path="$unix_path" 24950 fi 24951 24952 24953 new_path=`$WHICH "$new_path" 2> /dev/null` 24954 24955 if test "x$new_path" = x; then 24956 # It's still not found. Now this is an unrecoverable error. 24957 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 24958 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 24959 has_space=`$ECHO "$complete" | $GREP " "` 24960 if test "x$has_space" != x; then 24961 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24962 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24963 fi 24964 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 24965 fi 24966 fi 24967 24968 # Now new_path has a complete unix path to the binary 24969 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 24970 # Keep paths in /bin as-is, but remove trailing .exe if any 24971 new_path="${new_path/%.exe/}" 24972 # Do not save /bin paths to all_fixpath_prefixes! 24973 else 24974 # Not in mixed or Windows style, start by that. 24975 new_path=`cmd //c echo $new_path` 24976 24977 input_path="$new_path" 24978 # Check if we need to convert this using DOS-style short mode. If the path 24979 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24980 # take no chances and rewrite it. 24981 # Note: m4 eats our [], so we need to use [ and ] instead. 24982 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24983 if test "x$has_forbidden_chars" != x; then 24984 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24985 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24986 fi 24987 24988 # Output is in $new_path 24989 24990 windows_path="$new_path" 24991 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24992 unix_path=`$CYGPATH -u "$windows_path"` 24993 new_path="$unix_path" 24994 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24995 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24996 new_path="$unix_path" 24997 fi 24998 24999 # remove trailing .exe if any 25000 new_path="${new_path/%.exe/}" 25001 25002 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25003 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25004 fi 25005 25006 else 25007 # We're on a posix platform. Hooray! :) 25008 # First separate the path from the arguments. This will split at the first 25009 # space. 25010 complete="$CPP" 25011 path="${complete%% *}" 25012 tmp="$complete EOL" 25013 arguments="${tmp#* }" 25014 25015 # Cannot rely on the command "which" here since it doesn't always work. 25016 is_absolute_path=`$ECHO "$path" | $GREP ^/` 25017 if test -z "$is_absolute_path"; then 25018 # Path to executable is not absolute. Find it. 25019 IFS_save="$IFS" 25020 IFS=: 25021 for p in $PATH; do 25022 if test -f "$p/$path" && test -x "$p/$path"; then 25023 new_path="$p/$path" 25024 break 25025 fi 25026 done 25027 IFS="$IFS_save" 25028 else 25029 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CPP (as $path) failed, using $path directly." >&5 25030 $as_echo "$as_me: Resolving CPP (as $path) failed, using $path directly." >&6;} 25031 new_path="$path" 25032 fi 25033 25034 if test "x$new_path" = x; then 25035 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 25036 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 25037 has_space=`$ECHO "$complete" | $GREP " "` 25038 if test "x$has_space" != x; then 25039 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 25040 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 25041 fi 25042 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 25043 fi 25044 fi 25045 25046 # Now join together the path and the arguments once again 25047 if test "x$arguments" != xEOL; then 25048 new_complete="$new_path ${arguments% *}" 25049 else 25050 new_complete="$new_path" 25051 fi 25052 25053 if test "x$complete" != "x$new_complete"; then 25054 CPP="$new_complete" 25055 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5 25056 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;} 25057 fi 25058 25059 25060 ac_ext=cpp 25061 ac_cpp='$CXXCPP $CPPFLAGS' 25062 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 25063 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 25064 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 25065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 25066 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } 25067 if test -z "$CXXCPP"; then 25068 if ${ac_cv_prog_CXXCPP+:} false; then : 25069 $as_echo_n "(cached) " >&6 25070 else 25071 # Double quotes because CXXCPP needs to be expanded 25072 for CXXCPP in "$CXX -E" "/lib/cpp" 25073 do 25074 ac_preproc_ok=false 25075 for ac_cxx_preproc_warn_flag in '' yes 25076 do 25077 # Use a header file that comes with gcc, so configuring glibc 25078 # with a fresh cross-compiler works. 25079 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 25080 # <limits.h> exists even on freestanding compilers. 25081 # On the NeXT, cc -E runs the code through the compiler's parser, 25082 # not just through cpp. "Syntax error" is here to catch this case. 25083 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25084 /* end confdefs.h. */ 25085 #ifdef __STDC__ 25086 # include <limits.h> 25087 #else 25088 # include <assert.h> 25089 #endif 25090 Syntax error 25091 _ACEOF 25092 if ac_fn_cxx_try_cpp "$LINENO"; then : 25093 25094 else 25095 # Broken: fails on valid input. 25096 continue 25097 fi 25098 rm -f conftest.err conftest.i conftest.$ac_ext 25099 25100 # OK, works on sane cases. Now check whether nonexistent headers 25101 # can be detected and how. 25102 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25103 /* end confdefs.h. */ 25104 #include <ac_nonexistent.h> 25105 _ACEOF 25106 if ac_fn_cxx_try_cpp "$LINENO"; then : 25107 # Broken: success on invalid input. 25108 continue 25109 else 25110 # Passes both tests. 25111 ac_preproc_ok=: 25112 break 25113 fi 25114 rm -f conftest.err conftest.i conftest.$ac_ext 25115 25116 done 25117 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 25118 rm -f conftest.i conftest.err conftest.$ac_ext 25119 if $ac_preproc_ok; then : 25120 break 25121 fi 25122 25123 done 25124 ac_cv_prog_CXXCPP=$CXXCPP 25125 25126 fi 25127 CXXCPP=$ac_cv_prog_CXXCPP 25128 else 25129 ac_cv_prog_CXXCPP=$CXXCPP 25130 fi 25131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 25132 $as_echo "$CXXCPP" >&6; } 25133 ac_preproc_ok=false 25134 for ac_cxx_preproc_warn_flag in '' yes 25135 do 25136 # Use a header file that comes with gcc, so configuring glibc 25137 # with a fresh cross-compiler works. 25138 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 25139 # <limits.h> exists even on freestanding compilers. 25140 # On the NeXT, cc -E runs the code through the compiler's parser, 25141 # not just through cpp. "Syntax error" is here to catch this case. 25142 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25143 /* end confdefs.h. */ 25144 #ifdef __STDC__ 25145 # include <limits.h> 25146 #else 25147 # include <assert.h> 25148 #endif 25149 Syntax error 25150 _ACEOF 25151 if ac_fn_cxx_try_cpp "$LINENO"; then : 25152 25153 else 25154 # Broken: fails on valid input. 25155 continue 25156 fi 25157 rm -f conftest.err conftest.i conftest.$ac_ext 25158 25159 # OK, works on sane cases. Now check whether nonexistent headers 25160 # can be detected and how. 25161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25162 /* end confdefs.h. */ 25163 #include <ac_nonexistent.h> 25164 _ACEOF 25165 if ac_fn_cxx_try_cpp "$LINENO"; then : 25166 # Broken: success on invalid input. 25167 continue 25168 else 25169 # Passes both tests. 25170 ac_preproc_ok=: 25171 break 25172 fi 25173 rm -f conftest.err conftest.i conftest.$ac_ext 25174 25175 done 25176 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 25177 rm -f conftest.i conftest.err conftest.$ac_ext 25178 if $ac_preproc_ok; then : 25179 25180 else 25181 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 25182 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 25183 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check 25184 See \`config.log' for more details" "$LINENO" 5; } 25185 fi 25186 25187 ac_ext=cpp 25188 ac_cpp='$CXXCPP $CPPFLAGS' 25189 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 25190 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 25191 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 25192 25193 25194 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25195 25196 # First separate the path from the arguments. This will split at the first 25197 # space. 25198 complete="$CXXCPP" 25199 path="${complete%% *}" 25200 tmp="$complete EOL" 25201 arguments="${tmp#* }" 25202 25203 # Input might be given as Windows format, start by converting to 25204 # unix format. 25205 new_path=`$CYGPATH -u "$path"` 25206 25207 # Now try to locate executable using which 25208 new_path=`$WHICH "$new_path" 2> /dev/null` 25209 # bat and cmd files are not always considered executable in cygwin causing which 25210 # to not find them 25211 if test "x$new_path" = x \ 25212 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25213 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25214 new_path=`$CYGPATH -u "$path"` 25215 fi 25216 if test "x$new_path" = x; then 25217 # Oops. Which didn't find the executable. 25218 # The splitting of arguments from the executable at a space might have been incorrect, 25219 # since paths with space are more likely in Windows. Give it another try with the whole 25220 # argument. 25221 path="$complete" 25222 arguments="EOL" 25223 new_path=`$CYGPATH -u "$path"` 25224 new_path=`$WHICH "$new_path" 2> /dev/null` 25225 # bat and cmd files are not always considered executable in cygwin causing which 25226 # to not find them 25227 if test "x$new_path" = x \ 25228 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25229 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25230 new_path=`$CYGPATH -u "$path"` 25231 fi 25232 if test "x$new_path" = x; then 25233 # It's still not found. Now this is an unrecoverable error. 25234 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 25235 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 25236 has_space=`$ECHO "$complete" | $GREP " "` 25237 if test "x$has_space" != x; then 25238 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25239 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25240 fi 25241 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 25242 fi 25243 fi 25244 25245 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25246 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25247 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25248 # "foo.exe" is OK but "foo" is an error. 25249 # 25250 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25251 # It is also a way to make sure we got the proper file name for the real test later on. 25252 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25253 if test "x$test_shortpath" = x; then 25254 # Short path failed, file does not exist as specified. 25255 # Try adding .exe or .cmd 25256 if test -f "${new_path}.exe"; then 25257 input_to_shortpath="${new_path}.exe" 25258 elif test -f "${new_path}.cmd"; then 25259 input_to_shortpath="${new_path}.cmd" 25260 else 25261 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5 25262 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;} 25263 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 25264 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 25265 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 25266 fi 25267 else 25268 input_to_shortpath="$new_path" 25269 fi 25270 25271 # Call helper function which possibly converts this using DOS-style short mode. 25272 # If so, the updated path is stored in $new_path. 25273 new_path="$input_to_shortpath" 25274 25275 input_path="$input_to_shortpath" 25276 # Check if we need to convert this using DOS-style short mode. If the path 25277 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25278 # take no chances and rewrite it. 25279 # Note: m4 eats our [], so we need to use [ and ] instead. 25280 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25281 if test "x$has_forbidden_chars" != x; then 25282 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25283 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25284 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25285 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25286 # Going to short mode and back again did indeed matter. Since short mode is 25287 # case insensitive, let's make it lowercase to improve readability. 25288 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25289 # Now convert it back to Unix-stile (cygpath) 25290 input_path=`$CYGPATH -u "$shortmode_path"` 25291 new_path="$input_path" 25292 fi 25293 fi 25294 25295 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25296 if test "x$test_cygdrive_prefix" = x; then 25297 # As a simple fix, exclude /usr/bin since it's not a real path. 25298 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 25299 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25300 # a path prefixed by /cygdrive for fixpath to work. 25301 new_path="$CYGWIN_ROOT_PATH$input_path" 25302 fi 25303 fi 25304 25305 # remove trailing .exe if any 25306 new_path="${new_path/%.exe/}" 25307 25308 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25309 25310 # First separate the path from the arguments. This will split at the first 25311 # space. 25312 complete="$CXXCPP" 25313 path="${complete%% *}" 25314 tmp="$complete EOL" 25315 arguments="${tmp#* }" 25316 25317 # Input might be given as Windows format, start by converting to 25318 # unix format. 25319 new_path="$path" 25320 25321 windows_path="$new_path" 25322 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25323 unix_path=`$CYGPATH -u "$windows_path"` 25324 new_path="$unix_path" 25325 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25326 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25327 new_path="$unix_path" 25328 fi 25329 25330 25331 # Now try to locate executable using which 25332 new_path=`$WHICH "$new_path" 2> /dev/null` 25333 25334 if test "x$new_path" = x; then 25335 # Oops. Which didn't find the executable. 25336 # The splitting of arguments from the executable at a space might have been incorrect, 25337 # since paths with space are more likely in Windows. Give it another try with the whole 25338 # argument. 25339 path="$complete" 25340 arguments="EOL" 25341 new_path="$path" 25342 25343 windows_path="$new_path" 25344 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25345 unix_path=`$CYGPATH -u "$windows_path"` 25346 new_path="$unix_path" 25347 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25348 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25349 new_path="$unix_path" 25350 fi 25351 25352 25353 new_path=`$WHICH "$new_path" 2> /dev/null` 25354 25355 if test "x$new_path" = x; then 25356 # It's still not found. Now this is an unrecoverable error. 25357 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 25358 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 25359 has_space=`$ECHO "$complete" | $GREP " "` 25360 if test "x$has_space" != x; then 25361 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25362 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25363 fi 25364 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 25365 fi 25366 fi 25367 25368 # Now new_path has a complete unix path to the binary 25369 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 25370 # Keep paths in /bin as-is, but remove trailing .exe if any 25371 new_path="${new_path/%.exe/}" 25372 # Do not save /bin paths to all_fixpath_prefixes! 25373 else 25374 # Not in mixed or Windows style, start by that. 25375 new_path=`cmd //c echo $new_path` 25376 25377 input_path="$new_path" 25378 # Check if we need to convert this using DOS-style short mode. If the path 25379 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25380 # take no chances and rewrite it. 25381 # Note: m4 eats our [], so we need to use [ and ] instead. 25382 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25383 if test "x$has_forbidden_chars" != x; then 25384 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25385 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25386 fi 25387 25388 # Output is in $new_path 25389 25390 windows_path="$new_path" 25391 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25392 unix_path=`$CYGPATH -u "$windows_path"` 25393 new_path="$unix_path" 25394 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25395 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25396 new_path="$unix_path" 25397 fi 25398 25399 # remove trailing .exe if any 25400 new_path="${new_path/%.exe/}" 25401 25402 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25403 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25404 fi 25405 25406 else 25407 # We're on a posix platform. Hooray! :) 25408 # First separate the path from the arguments. This will split at the first 25409 # space. 25410 complete="$CXXCPP" 25411 path="${complete%% *}" 25412 tmp="$complete EOL" 25413 arguments="${tmp#* }" 25414 25415 # Cannot rely on the command "which" here since it doesn't always work. 25416 is_absolute_path=`$ECHO "$path" | $GREP ^/` 25417 if test -z "$is_absolute_path"; then 25418 # Path to executable is not absolute. Find it. 25419 IFS_save="$IFS" 25420 IFS=: 25421 for p in $PATH; do 25422 if test -f "$p/$path" && test -x "$p/$path"; then 25423 new_path="$p/$path" 25424 break 25425 fi 25426 done 25427 IFS="$IFS_save" 25428 else 25429 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CXXCPP (as $path) failed, using $path directly." >&5 25430 $as_echo "$as_me: Resolving CXXCPP (as $path) failed, using $path directly." >&6;} 25431 new_path="$path" 25432 fi 25433 25434 if test "x$new_path" = x; then 25435 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 25436 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 25437 has_space=`$ECHO "$complete" | $GREP " "` 25438 if test "x$has_space" != x; then 25439 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 25440 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 25441 fi 25442 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 25443 fi 25444 fi 25445 25446 # Now join together the path and the arguments once again 25447 if test "x$arguments" != xEOL; then 25448 new_complete="$new_path ${arguments% *}" 25449 else 25450 new_complete="$new_path" 25451 fi 25452 25453 if test "x$complete" != "x$new_complete"; then 25454 CXXCPP="$new_complete" 25455 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5 25456 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;} 25457 fi 25458 25459 25460 if test "x$COMPILE_TYPE" != "xcross"; then 25461 # If we are not cross compiling, use the same compilers for 25462 # building the build platform executables. The cross-compilation 25463 # case needed to be done earlier, but this can only be done after 25464 # the native tools have been localized. 25465 BUILD_CC="$CC" 25466 BUILD_CXX="$CXX" 25467 BUILD_LD="$LD" 25468 fi 25469 25470 # for solaris we really need solaris tools, and not gnu equivalent 25471 # these seems to normally reside in /usr/ccs/bin so add that to path before 25472 # starting to probe 25473 # 25474 # NOTE: I add this /usr/ccs/bin after TOOLS but before OLD_PATH 25475 # so that it can be overriden --with-tools-dir 25476 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 25477 PATH="${TOOLS_DIR}:/usr/ccs/bin:${OLD_PATH}" 25478 fi 25479 25480 # Find the right assembler. 25481 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 25482 # Extract the first word of "as", so it can be a program name with args. 25483 set dummy as; ac_word=$2 25484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 25485 $as_echo_n "checking for $ac_word... " >&6; } 25486 if ${ac_cv_path_AS+:} false; then : 25487 $as_echo_n "(cached) " >&6 25488 else 25489 case $AS in 25490 [\\/]* | ?:[\\/]*) 25491 ac_cv_path_AS="$AS" # Let the user override the test with a path. 25492 ;; 25493 *) 25494 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 25495 for as_dir in $PATH 25496 do 25497 IFS=$as_save_IFS 25498 test -z "$as_dir" && as_dir=. 25499 for ac_exec_ext in '' $ac_executable_extensions; do 25500 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 25501 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 25502 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 25503 break 2 25504 fi 25505 done 25506 done 25507 IFS=$as_save_IFS 25508 25509 ;; 25510 esac 25511 fi 25512 AS=$ac_cv_path_AS 25513 if test -n "$AS"; then 25514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 25515 $as_echo "$AS" >&6; } 25516 else 25517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 25518 $as_echo "no" >&6; } 25519 fi 25520 25521 25522 25523 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25524 25525 # First separate the path from the arguments. This will split at the first 25526 # space. 25527 complete="$AS" 25528 path="${complete%% *}" 25529 tmp="$complete EOL" 25530 arguments="${tmp#* }" 25531 25532 # Input might be given as Windows format, start by converting to 25533 # unix format. 25534 new_path=`$CYGPATH -u "$path"` 25535 25536 # Now try to locate executable using which 25537 new_path=`$WHICH "$new_path" 2> /dev/null` 25538 # bat and cmd files are not always considered executable in cygwin causing which 25539 # to not find them 25540 if test "x$new_path" = x \ 25541 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25542 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25543 new_path=`$CYGPATH -u "$path"` 25544 fi 25545 if test "x$new_path" = x; then 25546 # Oops. Which didn't find the executable. 25547 # The splitting of arguments from the executable at a space might have been incorrect, 25548 # since paths with space are more likely in Windows. Give it another try with the whole 25549 # argument. 25550 path="$complete" 25551 arguments="EOL" 25552 new_path=`$CYGPATH -u "$path"` 25553 new_path=`$WHICH "$new_path" 2> /dev/null` 25554 # bat and cmd files are not always considered executable in cygwin causing which 25555 # to not find them 25556 if test "x$new_path" = x \ 25557 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25558 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25559 new_path=`$CYGPATH -u "$path"` 25560 fi 25561 if test "x$new_path" = x; then 25562 # It's still not found. Now this is an unrecoverable error. 25563 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 25564 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 25565 has_space=`$ECHO "$complete" | $GREP " "` 25566 if test "x$has_space" != x; then 25567 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25568 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25569 fi 25570 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 25571 fi 25572 fi 25573 25574 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25575 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25576 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25577 # "foo.exe" is OK but "foo" is an error. 25578 # 25579 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25580 # It is also a way to make sure we got the proper file name for the real test later on. 25581 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25582 if test "x$test_shortpath" = x; then 25583 # Short path failed, file does not exist as specified. 25584 # Try adding .exe or .cmd 25585 if test -f "${new_path}.exe"; then 25586 input_to_shortpath="${new_path}.exe" 25587 elif test -f "${new_path}.cmd"; then 25588 input_to_shortpath="${new_path}.cmd" 25589 else 25590 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5 25591 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;} 25592 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 25593 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 25594 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 25595 fi 25596 else 25597 input_to_shortpath="$new_path" 25598 fi 25599 25600 # Call helper function which possibly converts this using DOS-style short mode. 25601 # If so, the updated path is stored in $new_path. 25602 new_path="$input_to_shortpath" 25603 25604 input_path="$input_to_shortpath" 25605 # Check if we need to convert this using DOS-style short mode. If the path 25606 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25607 # take no chances and rewrite it. 25608 # Note: m4 eats our [], so we need to use [ and ] instead. 25609 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25610 if test "x$has_forbidden_chars" != x; then 25611 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25612 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25613 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25614 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25615 # Going to short mode and back again did indeed matter. Since short mode is 25616 # case insensitive, let's make it lowercase to improve readability. 25617 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25618 # Now convert it back to Unix-stile (cygpath) 25619 input_path=`$CYGPATH -u "$shortmode_path"` 25620 new_path="$input_path" 25621 fi 25622 fi 25623 25624 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25625 if test "x$test_cygdrive_prefix" = x; then 25626 # As a simple fix, exclude /usr/bin since it's not a real path. 25627 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 25628 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25629 # a path prefixed by /cygdrive for fixpath to work. 25630 new_path="$CYGWIN_ROOT_PATH$input_path" 25631 fi 25632 fi 25633 25634 # remove trailing .exe if any 25635 new_path="${new_path/%.exe/}" 25636 25637 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25638 25639 # First separate the path from the arguments. This will split at the first 25640 # space. 25641 complete="$AS" 25642 path="${complete%% *}" 25643 tmp="$complete EOL" 25644 arguments="${tmp#* }" 25645 25646 # Input might be given as Windows format, start by converting to 25647 # unix format. 25648 new_path="$path" 25649 25650 windows_path="$new_path" 25651 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25652 unix_path=`$CYGPATH -u "$windows_path"` 25653 new_path="$unix_path" 25654 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25655 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25656 new_path="$unix_path" 25657 fi 25658 25659 25660 # Now try to locate executable using which 25661 new_path=`$WHICH "$new_path" 2> /dev/null` 25662 25663 if test "x$new_path" = x; then 25664 # Oops. Which didn't find the executable. 25665 # The splitting of arguments from the executable at a space might have been incorrect, 25666 # since paths with space are more likely in Windows. Give it another try with the whole 25667 # argument. 25668 path="$complete" 25669 arguments="EOL" 25670 new_path="$path" 25671 25672 windows_path="$new_path" 25673 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25674 unix_path=`$CYGPATH -u "$windows_path"` 25675 new_path="$unix_path" 25676 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25677 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25678 new_path="$unix_path" 25679 fi 25680 25681 25682 new_path=`$WHICH "$new_path" 2> /dev/null` 25683 25684 if test "x$new_path" = x; then 25685 # It's still not found. Now this is an unrecoverable error. 25686 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 25687 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 25688 has_space=`$ECHO "$complete" | $GREP " "` 25689 if test "x$has_space" != x; then 25690 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25691 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25692 fi 25693 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 25694 fi 25695 fi 25696 25697 # Now new_path has a complete unix path to the binary 25698 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 25699 # Keep paths in /bin as-is, but remove trailing .exe if any 25700 new_path="${new_path/%.exe/}" 25701 # Do not save /bin paths to all_fixpath_prefixes! 25702 else 25703 # Not in mixed or Windows style, start by that. 25704 new_path=`cmd //c echo $new_path` 25705 25706 input_path="$new_path" 25707 # Check if we need to convert this using DOS-style short mode. If the path 25708 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25709 # take no chances and rewrite it. 25710 # Note: m4 eats our [], so we need to use [ and ] instead. 25711 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25712 if test "x$has_forbidden_chars" != x; then 25713 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25714 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25715 fi 25716 25717 # Output is in $new_path 25718 25719 windows_path="$new_path" 25720 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25721 unix_path=`$CYGPATH -u "$windows_path"` 25722 new_path="$unix_path" 25723 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25724 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25725 new_path="$unix_path" 25726 fi 25727 25728 # remove trailing .exe if any 25729 new_path="${new_path/%.exe/}" 25730 25731 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25732 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25733 fi 25734 25735 else 25736 # We're on a posix platform. Hooray! :) 25737 # First separate the path from the arguments. This will split at the first 25738 # space. 25739 complete="$AS" 25740 path="${complete%% *}" 25741 tmp="$complete EOL" 25742 arguments="${tmp#* }" 25743 25744 # Cannot rely on the command "which" here since it doesn't always work. 25745 is_absolute_path=`$ECHO "$path" | $GREP ^/` 25746 if test -z "$is_absolute_path"; then 25747 # Path to executable is not absolute. Find it. 25748 IFS_save="$IFS" 25749 IFS=: 25750 for p in $PATH; do 25751 if test -f "$p/$path" && test -x "$p/$path"; then 25752 new_path="$p/$path" 25753 break 25754 fi 25755 done 25756 IFS="$IFS_save" 25757 else 25758 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving AS (as $path) failed, using $path directly." >&5 25759 $as_echo "$as_me: Resolving AS (as $path) failed, using $path directly." >&6;} 25760 new_path="$path" 25761 fi 25762 25763 if test "x$new_path" = x; then 25764 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 25765 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 25766 has_space=`$ECHO "$complete" | $GREP " "` 25767 if test "x$has_space" != x; then 25768 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 25769 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 25770 fi 25771 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 25772 fi 25773 fi 25774 25775 # Now join together the path and the arguments once again 25776 if test "x$arguments" != xEOL; then 25777 new_complete="$new_path ${arguments% *}" 25778 else 25779 new_complete="$new_path" 25780 fi 25781 25782 if test "x$complete" != "x$new_complete"; then 25783 AS="$new_complete" 25784 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5 25785 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;} 25786 fi 25787 25788 else 25789 AS="$CC -c" 25790 fi 25791 25792 25793 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 25794 # Extract the first word of "nm", so it can be a program name with args. 25795 set dummy nm; ac_word=$2 25796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 25797 $as_echo_n "checking for $ac_word... " >&6; } 25798 if ${ac_cv_path_NM+:} false; then : 25799 $as_echo_n "(cached) " >&6 25800 else 25801 case $NM in 25802 [\\/]* | ?:[\\/]*) 25803 ac_cv_path_NM="$NM" # Let the user override the test with a path. 25804 ;; 25805 *) 25806 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 25807 for as_dir in $PATH 25808 do 25809 IFS=$as_save_IFS 25810 test -z "$as_dir" && as_dir=. 25811 for ac_exec_ext in '' $ac_executable_extensions; do 25812 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 25813 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 25814 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 25815 break 2 25816 fi 25817 done 25818 done 25819 IFS=$as_save_IFS 25820 25821 ;; 25822 esac 25823 fi 25824 NM=$ac_cv_path_NM 25825 if test -n "$NM"; then 25826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 25827 $as_echo "$NM" >&6; } 25828 else 25829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 25830 $as_echo "no" >&6; } 25831 fi 25832 25833 25834 25835 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25836 25837 # First separate the path from the arguments. This will split at the first 25838 # space. 25839 complete="$NM" 25840 path="${complete%% *}" 25841 tmp="$complete EOL" 25842 arguments="${tmp#* }" 25843 25844 # Input might be given as Windows format, start by converting to 25845 # unix format. 25846 new_path=`$CYGPATH -u "$path"` 25847 25848 # Now try to locate executable using which 25849 new_path=`$WHICH "$new_path" 2> /dev/null` 25850 # bat and cmd files are not always considered executable in cygwin causing which 25851 # to not find them 25852 if test "x$new_path" = x \ 25853 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25854 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25855 new_path=`$CYGPATH -u "$path"` 25856 fi 25857 if test "x$new_path" = x; then 25858 # Oops. Which didn't find the executable. 25859 # The splitting of arguments from the executable at a space might have been incorrect, 25860 # since paths with space are more likely in Windows. Give it another try with the whole 25861 # argument. 25862 path="$complete" 25863 arguments="EOL" 25864 new_path=`$CYGPATH -u "$path"` 25865 new_path=`$WHICH "$new_path" 2> /dev/null` 25866 # bat and cmd files are not always considered executable in cygwin causing which 25867 # to not find them 25868 if test "x$new_path" = x \ 25869 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25870 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25871 new_path=`$CYGPATH -u "$path"` 25872 fi 25873 if test "x$new_path" = x; then 25874 # It's still not found. Now this is an unrecoverable error. 25875 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 25876 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 25877 has_space=`$ECHO "$complete" | $GREP " "` 25878 if test "x$has_space" != x; then 25879 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25880 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25881 fi 25882 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 25883 fi 25884 fi 25885 25886 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25887 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25888 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25889 # "foo.exe" is OK but "foo" is an error. 25890 # 25891 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25892 # It is also a way to make sure we got the proper file name for the real test later on. 25893 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25894 if test "x$test_shortpath" = x; then 25895 # Short path failed, file does not exist as specified. 25896 # Try adding .exe or .cmd 25897 if test -f "${new_path}.exe"; then 25898 input_to_shortpath="${new_path}.exe" 25899 elif test -f "${new_path}.cmd"; then 25900 input_to_shortpath="${new_path}.cmd" 25901 else 25902 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 25903 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 25904 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 25905 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 25906 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 25907 fi 25908 else 25909 input_to_shortpath="$new_path" 25910 fi 25911 25912 # Call helper function which possibly converts this using DOS-style short mode. 25913 # If so, the updated path is stored in $new_path. 25914 new_path="$input_to_shortpath" 25915 25916 input_path="$input_to_shortpath" 25917 # Check if we need to convert this using DOS-style short mode. If the path 25918 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25919 # take no chances and rewrite it. 25920 # Note: m4 eats our [], so we need to use [ and ] instead. 25921 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25922 if test "x$has_forbidden_chars" != x; then 25923 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25924 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25925 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25926 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25927 # Going to short mode and back again did indeed matter. Since short mode is 25928 # case insensitive, let's make it lowercase to improve readability. 25929 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25930 # Now convert it back to Unix-stile (cygpath) 25931 input_path=`$CYGPATH -u "$shortmode_path"` 25932 new_path="$input_path" 25933 fi 25934 fi 25935 25936 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25937 if test "x$test_cygdrive_prefix" = x; then 25938 # As a simple fix, exclude /usr/bin since it's not a real path. 25939 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 25940 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25941 # a path prefixed by /cygdrive for fixpath to work. 25942 new_path="$CYGWIN_ROOT_PATH$input_path" 25943 fi 25944 fi 25945 25946 # remove trailing .exe if any 25947 new_path="${new_path/%.exe/}" 25948 25949 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25950 25951 # First separate the path from the arguments. This will split at the first 25952 # space. 25953 complete="$NM" 25954 path="${complete%% *}" 25955 tmp="$complete EOL" 25956 arguments="${tmp#* }" 25957 25958 # Input might be given as Windows format, start by converting to 25959 # unix format. 25960 new_path="$path" 25961 25962 windows_path="$new_path" 25963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25964 unix_path=`$CYGPATH -u "$windows_path"` 25965 new_path="$unix_path" 25966 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25967 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25968 new_path="$unix_path" 25969 fi 25970 25971 25972 # Now try to locate executable using which 25973 new_path=`$WHICH "$new_path" 2> /dev/null` 25974 25975 if test "x$new_path" = x; then 25976 # Oops. Which didn't find the executable. 25977 # The splitting of arguments from the executable at a space might have been incorrect, 25978 # since paths with space are more likely in Windows. Give it another try with the whole 25979 # argument. 25980 path="$complete" 25981 arguments="EOL" 25982 new_path="$path" 25983 25984 windows_path="$new_path" 25985 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25986 unix_path=`$CYGPATH -u "$windows_path"` 25987 new_path="$unix_path" 25988 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25989 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25990 new_path="$unix_path" 25991 fi 25992 25993 25994 new_path=`$WHICH "$new_path" 2> /dev/null` 25995 25996 if test "x$new_path" = x; then 25997 # It's still not found. Now this is an unrecoverable error. 25998 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 25999 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 26000 has_space=`$ECHO "$complete" | $GREP " "` 26001 if test "x$has_space" != x; then 26002 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26003 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26004 fi 26005 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 26006 fi 26007 fi 26008 26009 # Now new_path has a complete unix path to the binary 26010 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 26011 # Keep paths in /bin as-is, but remove trailing .exe if any 26012 new_path="${new_path/%.exe/}" 26013 # Do not save /bin paths to all_fixpath_prefixes! 26014 else 26015 # Not in mixed or Windows style, start by that. 26016 new_path=`cmd //c echo $new_path` 26017 26018 input_path="$new_path" 26019 # Check if we need to convert this using DOS-style short mode. If the path 26020 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26021 # take no chances and rewrite it. 26022 # Note: m4 eats our [], so we need to use [ and ] instead. 26023 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26024 if test "x$has_forbidden_chars" != x; then 26025 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26026 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26027 fi 26028 26029 # Output is in $new_path 26030 26031 windows_path="$new_path" 26032 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26033 unix_path=`$CYGPATH -u "$windows_path"` 26034 new_path="$unix_path" 26035 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26036 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26037 new_path="$unix_path" 26038 fi 26039 26040 # remove trailing .exe if any 26041 new_path="${new_path/%.exe/}" 26042 26043 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26044 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26045 fi 26046 26047 else 26048 # We're on a posix platform. Hooray! :) 26049 # First separate the path from the arguments. This will split at the first 26050 # space. 26051 complete="$NM" 26052 path="${complete%% *}" 26053 tmp="$complete EOL" 26054 arguments="${tmp#* }" 26055 26056 # Cannot rely on the command "which" here since it doesn't always work. 26057 is_absolute_path=`$ECHO "$path" | $GREP ^/` 26058 if test -z "$is_absolute_path"; then 26059 # Path to executable is not absolute. Find it. 26060 IFS_save="$IFS" 26061 IFS=: 26062 for p in $PATH; do 26063 if test -f "$p/$path" && test -x "$p/$path"; then 26064 new_path="$p/$path" 26065 break 26066 fi 26067 done 26068 IFS="$IFS_save" 26069 else 26070 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving NM (as $path) failed, using $path directly." >&5 26071 $as_echo "$as_me: Resolving NM (as $path) failed, using $path directly." >&6;} 26072 new_path="$path" 26073 fi 26074 26075 if test "x$new_path" = x; then 26076 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 26077 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 26078 has_space=`$ECHO "$complete" | $GREP " "` 26079 if test "x$has_space" != x; then 26080 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 26081 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 26082 fi 26083 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 26084 fi 26085 fi 26086 26087 # Now join together the path and the arguments once again 26088 if test "x$arguments" != xEOL; then 26089 new_complete="$new_path ${arguments% *}" 26090 else 26091 new_complete="$new_path" 26092 fi 26093 26094 if test "x$complete" != "x$new_complete"; then 26095 NM="$new_complete" 26096 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 26097 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 26098 fi 26099 26100 # Extract the first word of "gnm", so it can be a program name with args. 26101 set dummy gnm; ac_word=$2 26102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26103 $as_echo_n "checking for $ac_word... " >&6; } 26104 if ${ac_cv_path_GNM+:} false; then : 26105 $as_echo_n "(cached) " >&6 26106 else 26107 case $GNM in 26108 [\\/]* | ?:[\\/]*) 26109 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 26110 ;; 26111 *) 26112 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26113 for as_dir in $PATH 26114 do 26115 IFS=$as_save_IFS 26116 test -z "$as_dir" && as_dir=. 26117 for ac_exec_ext in '' $ac_executable_extensions; do 26118 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 26119 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 26120 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26121 break 2 26122 fi 26123 done 26124 done 26125 IFS=$as_save_IFS 26126 26127 ;; 26128 esac 26129 fi 26130 GNM=$ac_cv_path_GNM 26131 if test -n "$GNM"; then 26132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 26133 $as_echo "$GNM" >&6; } 26134 else 26135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26136 $as_echo "no" >&6; } 26137 fi 26138 26139 26140 26141 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26142 26143 # First separate the path from the arguments. This will split at the first 26144 # space. 26145 complete="$GNM" 26146 path="${complete%% *}" 26147 tmp="$complete EOL" 26148 arguments="${tmp#* }" 26149 26150 # Input might be given as Windows format, start by converting to 26151 # unix format. 26152 new_path=`$CYGPATH -u "$path"` 26153 26154 # Now try to locate executable using which 26155 new_path=`$WHICH "$new_path" 2> /dev/null` 26156 # bat and cmd files are not always considered executable in cygwin causing which 26157 # to not find them 26158 if test "x$new_path" = x \ 26159 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26160 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26161 new_path=`$CYGPATH -u "$path"` 26162 fi 26163 if test "x$new_path" = x; then 26164 # Oops. Which didn't find the executable. 26165 # The splitting of arguments from the executable at a space might have been incorrect, 26166 # since paths with space are more likely in Windows. Give it another try with the whole 26167 # argument. 26168 path="$complete" 26169 arguments="EOL" 26170 new_path=`$CYGPATH -u "$path"` 26171 new_path=`$WHICH "$new_path" 2> /dev/null` 26172 # bat and cmd files are not always considered executable in cygwin causing which 26173 # to not find them 26174 if test "x$new_path" = x \ 26175 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26176 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26177 new_path=`$CYGPATH -u "$path"` 26178 fi 26179 if test "x$new_path" = x; then 26180 # It's still not found. Now this is an unrecoverable error. 26181 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 26182 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 26183 has_space=`$ECHO "$complete" | $GREP " "` 26184 if test "x$has_space" != x; then 26185 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26186 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26187 fi 26188 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 26189 fi 26190 fi 26191 26192 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26193 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26194 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26195 # "foo.exe" is OK but "foo" is an error. 26196 # 26197 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26198 # It is also a way to make sure we got the proper file name for the real test later on. 26199 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26200 if test "x$test_shortpath" = x; then 26201 # Short path failed, file does not exist as specified. 26202 # Try adding .exe or .cmd 26203 if test -f "${new_path}.exe"; then 26204 input_to_shortpath="${new_path}.exe" 26205 elif test -f "${new_path}.cmd"; then 26206 input_to_shortpath="${new_path}.cmd" 26207 else 26208 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5 26209 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;} 26210 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 26211 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 26212 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 26213 fi 26214 else 26215 input_to_shortpath="$new_path" 26216 fi 26217 26218 # Call helper function which possibly converts this using DOS-style short mode. 26219 # If so, the updated path is stored in $new_path. 26220 new_path="$input_to_shortpath" 26221 26222 input_path="$input_to_shortpath" 26223 # Check if we need to convert this using DOS-style short mode. If the path 26224 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26225 # take no chances and rewrite it. 26226 # Note: m4 eats our [], so we need to use [ and ] instead. 26227 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26228 if test "x$has_forbidden_chars" != x; then 26229 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26230 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26231 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26232 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26233 # Going to short mode and back again did indeed matter. Since short mode is 26234 # case insensitive, let's make it lowercase to improve readability. 26235 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26236 # Now convert it back to Unix-stile (cygpath) 26237 input_path=`$CYGPATH -u "$shortmode_path"` 26238 new_path="$input_path" 26239 fi 26240 fi 26241 26242 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26243 if test "x$test_cygdrive_prefix" = x; then 26244 # As a simple fix, exclude /usr/bin since it's not a real path. 26245 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 26246 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26247 # a path prefixed by /cygdrive for fixpath to work. 26248 new_path="$CYGWIN_ROOT_PATH$input_path" 26249 fi 26250 fi 26251 26252 # remove trailing .exe if any 26253 new_path="${new_path/%.exe/}" 26254 26255 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26256 26257 # First separate the path from the arguments. This will split at the first 26258 # space. 26259 complete="$GNM" 26260 path="${complete%% *}" 26261 tmp="$complete EOL" 26262 arguments="${tmp#* }" 26263 26264 # Input might be given as Windows format, start by converting to 26265 # unix format. 26266 new_path="$path" 26267 26268 windows_path="$new_path" 26269 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26270 unix_path=`$CYGPATH -u "$windows_path"` 26271 new_path="$unix_path" 26272 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26273 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26274 new_path="$unix_path" 26275 fi 26276 26277 26278 # Now try to locate executable using which 26279 new_path=`$WHICH "$new_path" 2> /dev/null` 26280 26281 if test "x$new_path" = x; then 26282 # Oops. Which didn't find the executable. 26283 # The splitting of arguments from the executable at a space might have been incorrect, 26284 # since paths with space are more likely in Windows. Give it another try with the whole 26285 # argument. 26286 path="$complete" 26287 arguments="EOL" 26288 new_path="$path" 26289 26290 windows_path="$new_path" 26291 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26292 unix_path=`$CYGPATH -u "$windows_path"` 26293 new_path="$unix_path" 26294 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26295 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26296 new_path="$unix_path" 26297 fi 26298 26299 26300 new_path=`$WHICH "$new_path" 2> /dev/null` 26301 26302 if test "x$new_path" = x; then 26303 # It's still not found. Now this is an unrecoverable error. 26304 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 26305 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 26306 has_space=`$ECHO "$complete" | $GREP " "` 26307 if test "x$has_space" != x; then 26308 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26309 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26310 fi 26311 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 26312 fi 26313 fi 26314 26315 # Now new_path has a complete unix path to the binary 26316 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 26317 # Keep paths in /bin as-is, but remove trailing .exe if any 26318 new_path="${new_path/%.exe/}" 26319 # Do not save /bin paths to all_fixpath_prefixes! 26320 else 26321 # Not in mixed or Windows style, start by that. 26322 new_path=`cmd //c echo $new_path` 26323 26324 input_path="$new_path" 26325 # Check if we need to convert this using DOS-style short mode. If the path 26326 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26327 # take no chances and rewrite it. 26328 # Note: m4 eats our [], so we need to use [ and ] instead. 26329 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26330 if test "x$has_forbidden_chars" != x; then 26331 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26332 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26333 fi 26334 26335 # Output is in $new_path 26336 26337 windows_path="$new_path" 26338 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26339 unix_path=`$CYGPATH -u "$windows_path"` 26340 new_path="$unix_path" 26341 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26342 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26343 new_path="$unix_path" 26344 fi 26345 26346 # remove trailing .exe if any 26347 new_path="${new_path/%.exe/}" 26348 26349 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26350 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26351 fi 26352 26353 else 26354 # We're on a posix platform. Hooray! :) 26355 # First separate the path from the arguments. This will split at the first 26356 # space. 26357 complete="$GNM" 26358 path="${complete%% *}" 26359 tmp="$complete EOL" 26360 arguments="${tmp#* }" 26361 26362 # Cannot rely on the command "which" here since it doesn't always work. 26363 is_absolute_path=`$ECHO "$path" | $GREP ^/` 26364 if test -z "$is_absolute_path"; then 26365 # Path to executable is not absolute. Find it. 26366 IFS_save="$IFS" 26367 IFS=: 26368 for p in $PATH; do 26369 if test -f "$p/$path" && test -x "$p/$path"; then 26370 new_path="$p/$path" 26371 break 26372 fi 26373 done 26374 IFS="$IFS_save" 26375 else 26376 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving GNM (as $path) failed, using $path directly." >&5 26377 $as_echo "$as_me: Resolving GNM (as $path) failed, using $path directly." >&6;} 26378 new_path="$path" 26379 fi 26380 26381 if test "x$new_path" = x; then 26382 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 26383 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 26384 has_space=`$ECHO "$complete" | $GREP " "` 26385 if test "x$has_space" != x; then 26386 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 26387 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 26388 fi 26389 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 26390 fi 26391 fi 26392 26393 # Now join together the path and the arguments once again 26394 if test "x$arguments" != xEOL; then 26395 new_complete="$new_path ${arguments% *}" 26396 else 26397 new_complete="$new_path" 26398 fi 26399 26400 if test "x$complete" != "x$new_complete"; then 26401 GNM="$new_complete" 26402 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5 26403 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;} 26404 fi 26405 26406 # Extract the first word of "strip", so it can be a program name with args. 26407 set dummy strip; ac_word=$2 26408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26409 $as_echo_n "checking for $ac_word... " >&6; } 26410 if ${ac_cv_path_STRIP+:} false; then : 26411 $as_echo_n "(cached) " >&6 26412 else 26413 case $STRIP in 26414 [\\/]* | ?:[\\/]*) 26415 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 26416 ;; 26417 *) 26418 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26419 for as_dir in $PATH 26420 do 26421 IFS=$as_save_IFS 26422 test -z "$as_dir" && as_dir=. 26423 for ac_exec_ext in '' $ac_executable_extensions; do 26424 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 26425 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 26426 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26427 break 2 26428 fi 26429 done 26430 done 26431 IFS=$as_save_IFS 26432 26433 ;; 26434 esac 26435 fi 26436 STRIP=$ac_cv_path_STRIP 26437 if test -n "$STRIP"; then 26438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 26439 $as_echo "$STRIP" >&6; } 26440 else 26441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26442 $as_echo "no" >&6; } 26443 fi 26444 26445 26446 26447 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26448 26449 # First separate the path from the arguments. This will split at the first 26450 # space. 26451 complete="$STRIP" 26452 path="${complete%% *}" 26453 tmp="$complete EOL" 26454 arguments="${tmp#* }" 26455 26456 # Input might be given as Windows format, start by converting to 26457 # unix format. 26458 new_path=`$CYGPATH -u "$path"` 26459 26460 # Now try to locate executable using which 26461 new_path=`$WHICH "$new_path" 2> /dev/null` 26462 # bat and cmd files are not always considered executable in cygwin causing which 26463 # to not find them 26464 if test "x$new_path" = x \ 26465 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26466 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26467 new_path=`$CYGPATH -u "$path"` 26468 fi 26469 if test "x$new_path" = x; then 26470 # Oops. Which didn't find the executable. 26471 # The splitting of arguments from the executable at a space might have been incorrect, 26472 # since paths with space are more likely in Windows. Give it another try with the whole 26473 # argument. 26474 path="$complete" 26475 arguments="EOL" 26476 new_path=`$CYGPATH -u "$path"` 26477 new_path=`$WHICH "$new_path" 2> /dev/null` 26478 # bat and cmd files are not always considered executable in cygwin causing which 26479 # to not find them 26480 if test "x$new_path" = x \ 26481 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26482 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26483 new_path=`$CYGPATH -u "$path"` 26484 fi 26485 if test "x$new_path" = x; then 26486 # It's still not found. Now this is an unrecoverable error. 26487 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 26488 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 26489 has_space=`$ECHO "$complete" | $GREP " "` 26490 if test "x$has_space" != x; then 26491 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26492 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26493 fi 26494 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 26495 fi 26496 fi 26497 26498 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26499 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26500 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26501 # "foo.exe" is OK but "foo" is an error. 26502 # 26503 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26504 # It is also a way to make sure we got the proper file name for the real test later on. 26505 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26506 if test "x$test_shortpath" = x; then 26507 # Short path failed, file does not exist as specified. 26508 # Try adding .exe or .cmd 26509 if test -f "${new_path}.exe"; then 26510 input_to_shortpath="${new_path}.exe" 26511 elif test -f "${new_path}.cmd"; then 26512 input_to_shortpath="${new_path}.cmd" 26513 else 26514 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 26515 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 26516 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 26517 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 26518 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 26519 fi 26520 else 26521 input_to_shortpath="$new_path" 26522 fi 26523 26524 # Call helper function which possibly converts this using DOS-style short mode. 26525 # If so, the updated path is stored in $new_path. 26526 new_path="$input_to_shortpath" 26527 26528 input_path="$input_to_shortpath" 26529 # Check if we need to convert this using DOS-style short mode. If the path 26530 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26531 # take no chances and rewrite it. 26532 # Note: m4 eats our [], so we need to use [ and ] instead. 26533 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26534 if test "x$has_forbidden_chars" != x; then 26535 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26536 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26537 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26538 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26539 # Going to short mode and back again did indeed matter. Since short mode is 26540 # case insensitive, let's make it lowercase to improve readability. 26541 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26542 # Now convert it back to Unix-stile (cygpath) 26543 input_path=`$CYGPATH -u "$shortmode_path"` 26544 new_path="$input_path" 26545 fi 26546 fi 26547 26548 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26549 if test "x$test_cygdrive_prefix" = x; then 26550 # As a simple fix, exclude /usr/bin since it's not a real path. 26551 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 26552 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26553 # a path prefixed by /cygdrive for fixpath to work. 26554 new_path="$CYGWIN_ROOT_PATH$input_path" 26555 fi 26556 fi 26557 26558 # remove trailing .exe if any 26559 new_path="${new_path/%.exe/}" 26560 26561 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26562 26563 # First separate the path from the arguments. This will split at the first 26564 # space. 26565 complete="$STRIP" 26566 path="${complete%% *}" 26567 tmp="$complete EOL" 26568 arguments="${tmp#* }" 26569 26570 # Input might be given as Windows format, start by converting to 26571 # unix format. 26572 new_path="$path" 26573 26574 windows_path="$new_path" 26575 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26576 unix_path=`$CYGPATH -u "$windows_path"` 26577 new_path="$unix_path" 26578 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26579 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26580 new_path="$unix_path" 26581 fi 26582 26583 26584 # Now try to locate executable using which 26585 new_path=`$WHICH "$new_path" 2> /dev/null` 26586 26587 if test "x$new_path" = x; then 26588 # Oops. Which didn't find the executable. 26589 # The splitting of arguments from the executable at a space might have been incorrect, 26590 # since paths with space are more likely in Windows. Give it another try with the whole 26591 # argument. 26592 path="$complete" 26593 arguments="EOL" 26594 new_path="$path" 26595 26596 windows_path="$new_path" 26597 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26598 unix_path=`$CYGPATH -u "$windows_path"` 26599 new_path="$unix_path" 26600 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26601 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26602 new_path="$unix_path" 26603 fi 26604 26605 26606 new_path=`$WHICH "$new_path" 2> /dev/null` 26607 26608 if test "x$new_path" = x; then 26609 # It's still not found. Now this is an unrecoverable error. 26610 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 26611 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 26612 has_space=`$ECHO "$complete" | $GREP " "` 26613 if test "x$has_space" != x; then 26614 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26615 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26616 fi 26617 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 26618 fi 26619 fi 26620 26621 # Now new_path has a complete unix path to the binary 26622 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 26623 # Keep paths in /bin as-is, but remove trailing .exe if any 26624 new_path="${new_path/%.exe/}" 26625 # Do not save /bin paths to all_fixpath_prefixes! 26626 else 26627 # Not in mixed or Windows style, start by that. 26628 new_path=`cmd //c echo $new_path` 26629 26630 input_path="$new_path" 26631 # Check if we need to convert this using DOS-style short mode. If the path 26632 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26633 # take no chances and rewrite it. 26634 # Note: m4 eats our [], so we need to use [ and ] instead. 26635 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26636 if test "x$has_forbidden_chars" != x; then 26637 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26638 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26639 fi 26640 26641 # Output is in $new_path 26642 26643 windows_path="$new_path" 26644 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26645 unix_path=`$CYGPATH -u "$windows_path"` 26646 new_path="$unix_path" 26647 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26648 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26649 new_path="$unix_path" 26650 fi 26651 26652 # remove trailing .exe if any 26653 new_path="${new_path/%.exe/}" 26654 26655 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26656 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26657 fi 26658 26659 else 26660 # We're on a posix platform. Hooray! :) 26661 # First separate the path from the arguments. This will split at the first 26662 # space. 26663 complete="$STRIP" 26664 path="${complete%% *}" 26665 tmp="$complete EOL" 26666 arguments="${tmp#* }" 26667 26668 # Cannot rely on the command "which" here since it doesn't always work. 26669 is_absolute_path=`$ECHO "$path" | $GREP ^/` 26670 if test -z "$is_absolute_path"; then 26671 # Path to executable is not absolute. Find it. 26672 IFS_save="$IFS" 26673 IFS=: 26674 for p in $PATH; do 26675 if test -f "$p/$path" && test -x "$p/$path"; then 26676 new_path="$p/$path" 26677 break 26678 fi 26679 done 26680 IFS="$IFS_save" 26681 else 26682 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving STRIP (as $path) failed, using $path directly." >&5 26683 $as_echo "$as_me: Resolving STRIP (as $path) failed, using $path directly." >&6;} 26684 new_path="$path" 26685 fi 26686 26687 if test "x$new_path" = x; then 26688 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 26689 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 26690 has_space=`$ECHO "$complete" | $GREP " "` 26691 if test "x$has_space" != x; then 26692 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 26693 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 26694 fi 26695 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 26696 fi 26697 fi 26698 26699 # Now join together the path and the arguments once again 26700 if test "x$arguments" != xEOL; then 26701 new_complete="$new_path ${arguments% *}" 26702 else 26703 new_complete="$new_path" 26704 fi 26705 26706 if test "x$complete" != "x$new_complete"; then 26707 STRIP="$new_complete" 26708 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 26709 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 26710 fi 26711 26712 # Extract the first word of "mcs", so it can be a program name with args. 26713 set dummy mcs; ac_word=$2 26714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26715 $as_echo_n "checking for $ac_word... " >&6; } 26716 if ${ac_cv_path_MCS+:} false; then : 26717 $as_echo_n "(cached) " >&6 26718 else 26719 case $MCS in 26720 [\\/]* | ?:[\\/]*) 26721 ac_cv_path_MCS="$MCS" # Let the user override the test with a path. 26722 ;; 26723 *) 26724 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26725 for as_dir in $PATH 26726 do 26727 IFS=$as_save_IFS 26728 test -z "$as_dir" && as_dir=. 26729 for ac_exec_ext in '' $ac_executable_extensions; do 26730 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 26731 ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext" 26732 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26733 break 2 26734 fi 26735 done 26736 done 26737 IFS=$as_save_IFS 26738 26739 ;; 26740 esac 26741 fi 26742 MCS=$ac_cv_path_MCS 26743 if test -n "$MCS"; then 26744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5 26745 $as_echo "$MCS" >&6; } 26746 else 26747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26748 $as_echo "no" >&6; } 26749 fi 26750 26751 26752 26753 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26754 26755 # First separate the path from the arguments. This will split at the first 26756 # space. 26757 complete="$MCS" 26758 path="${complete%% *}" 26759 tmp="$complete EOL" 26760 arguments="${tmp#* }" 26761 26762 # Input might be given as Windows format, start by converting to 26763 # unix format. 26764 new_path=`$CYGPATH -u "$path"` 26765 26766 # Now try to locate executable using which 26767 new_path=`$WHICH "$new_path" 2> /dev/null` 26768 # bat and cmd files are not always considered executable in cygwin causing which 26769 # to not find them 26770 if test "x$new_path" = x \ 26771 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26772 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26773 new_path=`$CYGPATH -u "$path"` 26774 fi 26775 if test "x$new_path" = x; then 26776 # Oops. Which didn't find the executable. 26777 # The splitting of arguments from the executable at a space might have been incorrect, 26778 # since paths with space are more likely in Windows. Give it another try with the whole 26779 # argument. 26780 path="$complete" 26781 arguments="EOL" 26782 new_path=`$CYGPATH -u "$path"` 26783 new_path=`$WHICH "$new_path" 2> /dev/null` 26784 # bat and cmd files are not always considered executable in cygwin causing which 26785 # to not find them 26786 if test "x$new_path" = x \ 26787 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26788 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26789 new_path=`$CYGPATH -u "$path"` 26790 fi 26791 if test "x$new_path" = x; then 26792 # It's still not found. Now this is an unrecoverable error. 26793 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5 26794 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;} 26795 has_space=`$ECHO "$complete" | $GREP " "` 26796 if test "x$has_space" != x; then 26797 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26798 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26799 fi 26800 as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5 26801 fi 26802 fi 26803 26804 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26805 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26806 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26807 # "foo.exe" is OK but "foo" is an error. 26808 # 26809 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26810 # It is also a way to make sure we got the proper file name for the real test later on. 26811 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26812 if test "x$test_shortpath" = x; then 26813 # Short path failed, file does not exist as specified. 26814 # Try adding .exe or .cmd 26815 if test -f "${new_path}.exe"; then 26816 input_to_shortpath="${new_path}.exe" 26817 elif test -f "${new_path}.cmd"; then 26818 input_to_shortpath="${new_path}.cmd" 26819 else 26820 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$new_path\", is invalid." >&5 26821 $as_echo "$as_me: The path of MCS, which resolves as \"$new_path\", is invalid." >&6;} 26822 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 26823 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 26824 as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5 26825 fi 26826 else 26827 input_to_shortpath="$new_path" 26828 fi 26829 26830 # Call helper function which possibly converts this using DOS-style short mode. 26831 # If so, the updated path is stored in $new_path. 26832 new_path="$input_to_shortpath" 26833 26834 input_path="$input_to_shortpath" 26835 # Check if we need to convert this using DOS-style short mode. If the path 26836 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26837 # take no chances and rewrite it. 26838 # Note: m4 eats our [], so we need to use [ and ] instead. 26839 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26840 if test "x$has_forbidden_chars" != x; then 26841 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26842 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26843 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26844 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26845 # Going to short mode and back again did indeed matter. Since short mode is 26846 # case insensitive, let's make it lowercase to improve readability. 26847 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26848 # Now convert it back to Unix-stile (cygpath) 26849 input_path=`$CYGPATH -u "$shortmode_path"` 26850 new_path="$input_path" 26851 fi 26852 fi 26853 26854 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26855 if test "x$test_cygdrive_prefix" = x; then 26856 # As a simple fix, exclude /usr/bin since it's not a real path. 26857 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 26858 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26859 # a path prefixed by /cygdrive for fixpath to work. 26860 new_path="$CYGWIN_ROOT_PATH$input_path" 26861 fi 26862 fi 26863 26864 # remove trailing .exe if any 26865 new_path="${new_path/%.exe/}" 26866 26867 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26868 26869 # First separate the path from the arguments. This will split at the first 26870 # space. 26871 complete="$MCS" 26872 path="${complete%% *}" 26873 tmp="$complete EOL" 26874 arguments="${tmp#* }" 26875 26876 # Input might be given as Windows format, start by converting to 26877 # unix format. 26878 new_path="$path" 26879 26880 windows_path="$new_path" 26881 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26882 unix_path=`$CYGPATH -u "$windows_path"` 26883 new_path="$unix_path" 26884 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26885 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26886 new_path="$unix_path" 26887 fi 26888 26889 26890 # Now try to locate executable using which 26891 new_path=`$WHICH "$new_path" 2> /dev/null` 26892 26893 if test "x$new_path" = x; then 26894 # Oops. Which didn't find the executable. 26895 # The splitting of arguments from the executable at a space might have been incorrect, 26896 # since paths with space are more likely in Windows. Give it another try with the whole 26897 # argument. 26898 path="$complete" 26899 arguments="EOL" 26900 new_path="$path" 26901 26902 windows_path="$new_path" 26903 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26904 unix_path=`$CYGPATH -u "$windows_path"` 26905 new_path="$unix_path" 26906 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26907 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26908 new_path="$unix_path" 26909 fi 26910 26911 26912 new_path=`$WHICH "$new_path" 2> /dev/null` 26913 26914 if test "x$new_path" = x; then 26915 # It's still not found. Now this is an unrecoverable error. 26916 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5 26917 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;} 26918 has_space=`$ECHO "$complete" | $GREP " "` 26919 if test "x$has_space" != x; then 26920 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26921 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26922 fi 26923 as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5 26924 fi 26925 fi 26926 26927 # Now new_path has a complete unix path to the binary 26928 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 26929 # Keep paths in /bin as-is, but remove trailing .exe if any 26930 new_path="${new_path/%.exe/}" 26931 # Do not save /bin paths to all_fixpath_prefixes! 26932 else 26933 # Not in mixed or Windows style, start by that. 26934 new_path=`cmd //c echo $new_path` 26935 26936 input_path="$new_path" 26937 # Check if we need to convert this using DOS-style short mode. If the path 26938 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26939 # take no chances and rewrite it. 26940 # Note: m4 eats our [], so we need to use [ and ] instead. 26941 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26942 if test "x$has_forbidden_chars" != x; then 26943 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26944 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26945 fi 26946 26947 # Output is in $new_path 26948 26949 windows_path="$new_path" 26950 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26951 unix_path=`$CYGPATH -u "$windows_path"` 26952 new_path="$unix_path" 26953 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26954 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26955 new_path="$unix_path" 26956 fi 26957 26958 # remove trailing .exe if any 26959 new_path="${new_path/%.exe/}" 26960 26961 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26962 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26963 fi 26964 26965 else 26966 # We're on a posix platform. Hooray! :) 26967 # First separate the path from the arguments. This will split at the first 26968 # space. 26969 complete="$MCS" 26970 path="${complete%% *}" 26971 tmp="$complete EOL" 26972 arguments="${tmp#* }" 26973 26974 # Cannot rely on the command "which" here since it doesn't always work. 26975 is_absolute_path=`$ECHO "$path" | $GREP ^/` 26976 if test -z "$is_absolute_path"; then 26977 # Path to executable is not absolute. Find it. 26978 IFS_save="$IFS" 26979 IFS=: 26980 for p in $PATH; do 26981 if test -f "$p/$path" && test -x "$p/$path"; then 26982 new_path="$p/$path" 26983 break 26984 fi 26985 done 26986 IFS="$IFS_save" 26987 else 26988 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving MCS (as $path) failed, using $path directly." >&5 26989 $as_echo "$as_me: Resolving MCS (as $path) failed, using $path directly." >&6;} 26990 new_path="$path" 26991 fi 26992 26993 if test "x$new_path" = x; then 26994 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5 26995 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;} 26996 has_space=`$ECHO "$complete" | $GREP " "` 26997 if test "x$has_space" != x; then 26998 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 26999 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 27000 fi 27001 as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5 27002 fi 27003 fi 27004 27005 # Now join together the path and the arguments once again 27006 if test "x$arguments" != xEOL; then 27007 new_complete="$new_path ${arguments% *}" 27008 else 27009 new_complete="$new_path" 27010 fi 27011 27012 if test "x$complete" != "x$new_complete"; then 27013 MCS="$new_complete" 27014 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MCS to \"$new_complete\"" >&5 27015 $as_echo "$as_me: Rewriting MCS to \"$new_complete\"" >&6;} 27016 fi 27017 27018 elif test "x$OPENJDK_TARGET_OS" != xwindows; then 27019 if test -n "$ac_tool_prefix"; then 27020 # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args. 27021 set dummy ${ac_tool_prefix}nm; ac_word=$2 27022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27023 $as_echo_n "checking for $ac_word... " >&6; } 27024 if ${ac_cv_prog_NM+:} false; then : 27025 $as_echo_n "(cached) " >&6 27026 else 27027 if test -n "$NM"; then 27028 ac_cv_prog_NM="$NM" # Let the user override the test. 27029 else 27030 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27031 for as_dir in $PATH 27032 do 27033 IFS=$as_save_IFS 27034 test -z "$as_dir" && as_dir=. 27035 for ac_exec_ext in '' $ac_executable_extensions; do 27036 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27037 ac_cv_prog_NM="${ac_tool_prefix}nm" 27038 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27039 break 2 27040 fi 27041 done 27042 done 27043 IFS=$as_save_IFS 27044 27045 fi 27046 fi 27047 NM=$ac_cv_prog_NM 27048 if test -n "$NM"; then 27049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 27050 $as_echo "$NM" >&6; } 27051 else 27052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27053 $as_echo "no" >&6; } 27054 fi 27055 27056 27057 fi 27058 if test -z "$ac_cv_prog_NM"; then 27059 ac_ct_NM=$NM 27060 # Extract the first word of "nm", so it can be a program name with args. 27061 set dummy nm; ac_word=$2 27062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27063 $as_echo_n "checking for $ac_word... " >&6; } 27064 if ${ac_cv_prog_ac_ct_NM+:} false; then : 27065 $as_echo_n "(cached) " >&6 27066 else 27067 if test -n "$ac_ct_NM"; then 27068 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 27069 else 27070 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27071 for as_dir in $PATH 27072 do 27073 IFS=$as_save_IFS 27074 test -z "$as_dir" && as_dir=. 27075 for ac_exec_ext in '' $ac_executable_extensions; do 27076 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27077 ac_cv_prog_ac_ct_NM="nm" 27078 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27079 break 2 27080 fi 27081 done 27082 done 27083 IFS=$as_save_IFS 27084 27085 fi 27086 fi 27087 ac_ct_NM=$ac_cv_prog_ac_ct_NM 27088 if test -n "$ac_ct_NM"; then 27089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 27090 $as_echo "$ac_ct_NM" >&6; } 27091 else 27092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27093 $as_echo "no" >&6; } 27094 fi 27095 27096 if test "x$ac_ct_NM" = x; then 27097 NM="" 27098 else 27099 case $cross_compiling:$ac_tool_warned in 27100 yes:) 27101 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 27102 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 27103 ac_tool_warned=yes ;; 27104 esac 27105 NM=$ac_ct_NM 27106 fi 27107 else 27108 NM="$ac_cv_prog_NM" 27109 fi 27110 27111 27112 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27113 27114 # First separate the path from the arguments. This will split at the first 27115 # space. 27116 complete="$NM" 27117 path="${complete%% *}" 27118 tmp="$complete EOL" 27119 arguments="${tmp#* }" 27120 27121 # Input might be given as Windows format, start by converting to 27122 # unix format. 27123 new_path=`$CYGPATH -u "$path"` 27124 27125 # Now try to locate executable using which 27126 new_path=`$WHICH "$new_path" 2> /dev/null` 27127 # bat and cmd files are not always considered executable in cygwin causing which 27128 # to not find them 27129 if test "x$new_path" = x \ 27130 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 27131 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 27132 new_path=`$CYGPATH -u "$path"` 27133 fi 27134 if test "x$new_path" = x; then 27135 # Oops. Which didn't find the executable. 27136 # The splitting of arguments from the executable at a space might have been incorrect, 27137 # since paths with space are more likely in Windows. Give it another try with the whole 27138 # argument. 27139 path="$complete" 27140 arguments="EOL" 27141 new_path=`$CYGPATH -u "$path"` 27142 new_path=`$WHICH "$new_path" 2> /dev/null` 27143 # bat and cmd files are not always considered executable in cygwin causing which 27144 # to not find them 27145 if test "x$new_path" = x \ 27146 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 27147 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 27148 new_path=`$CYGPATH -u "$path"` 27149 fi 27150 if test "x$new_path" = x; then 27151 # It's still not found. Now this is an unrecoverable error. 27152 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 27153 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 27154 has_space=`$ECHO "$complete" | $GREP " "` 27155 if test "x$has_space" != x; then 27156 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27157 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27158 fi 27159 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 27160 fi 27161 fi 27162 27163 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27164 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27165 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27166 # "foo.exe" is OK but "foo" is an error. 27167 # 27168 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27169 # It is also a way to make sure we got the proper file name for the real test later on. 27170 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27171 if test "x$test_shortpath" = x; then 27172 # Short path failed, file does not exist as specified. 27173 # Try adding .exe or .cmd 27174 if test -f "${new_path}.exe"; then 27175 input_to_shortpath="${new_path}.exe" 27176 elif test -f "${new_path}.cmd"; then 27177 input_to_shortpath="${new_path}.cmd" 27178 else 27179 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 27180 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 27181 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 27182 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 27183 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 27184 fi 27185 else 27186 input_to_shortpath="$new_path" 27187 fi 27188 27189 # Call helper function which possibly converts this using DOS-style short mode. 27190 # If so, the updated path is stored in $new_path. 27191 new_path="$input_to_shortpath" 27192 27193 input_path="$input_to_shortpath" 27194 # Check if we need to convert this using DOS-style short mode. If the path 27195 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27196 # take no chances and rewrite it. 27197 # Note: m4 eats our [], so we need to use [ and ] instead. 27198 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27199 if test "x$has_forbidden_chars" != x; then 27200 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27201 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27202 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27203 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27204 # Going to short mode and back again did indeed matter. Since short mode is 27205 # case insensitive, let's make it lowercase to improve readability. 27206 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27207 # Now convert it back to Unix-stile (cygpath) 27208 input_path=`$CYGPATH -u "$shortmode_path"` 27209 new_path="$input_path" 27210 fi 27211 fi 27212 27213 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27214 if test "x$test_cygdrive_prefix" = x; then 27215 # As a simple fix, exclude /usr/bin since it's not a real path. 27216 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 27217 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27218 # a path prefixed by /cygdrive for fixpath to work. 27219 new_path="$CYGWIN_ROOT_PATH$input_path" 27220 fi 27221 fi 27222 27223 # remove trailing .exe if any 27224 new_path="${new_path/%.exe/}" 27225 27226 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27227 27228 # First separate the path from the arguments. This will split at the first 27229 # space. 27230 complete="$NM" 27231 path="${complete%% *}" 27232 tmp="$complete EOL" 27233 arguments="${tmp#* }" 27234 27235 # Input might be given as Windows format, start by converting to 27236 # unix format. 27237 new_path="$path" 27238 27239 windows_path="$new_path" 27240 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27241 unix_path=`$CYGPATH -u "$windows_path"` 27242 new_path="$unix_path" 27243 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27244 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27245 new_path="$unix_path" 27246 fi 27247 27248 27249 # Now try to locate executable using which 27250 new_path=`$WHICH "$new_path" 2> /dev/null` 27251 27252 if test "x$new_path" = x; then 27253 # Oops. Which didn't find the executable. 27254 # The splitting of arguments from the executable at a space might have been incorrect, 27255 # since paths with space are more likely in Windows. Give it another try with the whole 27256 # argument. 27257 path="$complete" 27258 arguments="EOL" 27259 new_path="$path" 27260 27261 windows_path="$new_path" 27262 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27263 unix_path=`$CYGPATH -u "$windows_path"` 27264 new_path="$unix_path" 27265 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27266 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27267 new_path="$unix_path" 27268 fi 27269 27270 27271 new_path=`$WHICH "$new_path" 2> /dev/null` 27272 27273 if test "x$new_path" = x; then 27274 # It's still not found. Now this is an unrecoverable error. 27275 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 27276 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 27277 has_space=`$ECHO "$complete" | $GREP " "` 27278 if test "x$has_space" != x; then 27279 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27280 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27281 fi 27282 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 27283 fi 27284 fi 27285 27286 # Now new_path has a complete unix path to the binary 27287 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 27288 # Keep paths in /bin as-is, but remove trailing .exe if any 27289 new_path="${new_path/%.exe/}" 27290 # Do not save /bin paths to all_fixpath_prefixes! 27291 else 27292 # Not in mixed or Windows style, start by that. 27293 new_path=`cmd //c echo $new_path` 27294 27295 input_path="$new_path" 27296 # Check if we need to convert this using DOS-style short mode. If the path 27297 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27298 # take no chances and rewrite it. 27299 # Note: m4 eats our [], so we need to use [ and ] instead. 27300 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27301 if test "x$has_forbidden_chars" != x; then 27302 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27303 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27304 fi 27305 27306 # Output is in $new_path 27307 27308 windows_path="$new_path" 27309 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27310 unix_path=`$CYGPATH -u "$windows_path"` 27311 new_path="$unix_path" 27312 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27313 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27314 new_path="$unix_path" 27315 fi 27316 27317 # remove trailing .exe if any 27318 new_path="${new_path/%.exe/}" 27319 27320 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27321 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27322 fi 27323 27324 else 27325 # We're on a posix platform. Hooray! :) 27326 # First separate the path from the arguments. This will split at the first 27327 # space. 27328 complete="$NM" 27329 path="${complete%% *}" 27330 tmp="$complete EOL" 27331 arguments="${tmp#* }" 27332 27333 # Cannot rely on the command "which" here since it doesn't always work. 27334 is_absolute_path=`$ECHO "$path" | $GREP ^/` 27335 if test -z "$is_absolute_path"; then 27336 # Path to executable is not absolute. Find it. 27337 IFS_save="$IFS" 27338 IFS=: 27339 for p in $PATH; do 27340 if test -f "$p/$path" && test -x "$p/$path"; then 27341 new_path="$p/$path" 27342 break 27343 fi 27344 done 27345 IFS="$IFS_save" 27346 else 27347 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving NM (as $path) failed, using $path directly." >&5 27348 $as_echo "$as_me: Resolving NM (as $path) failed, using $path directly." >&6;} 27349 new_path="$path" 27350 fi 27351 27352 if test "x$new_path" = x; then 27353 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 27354 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 27355 has_space=`$ECHO "$complete" | $GREP " "` 27356 if test "x$has_space" != x; then 27357 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 27358 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 27359 fi 27360 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 27361 fi 27362 fi 27363 27364 # Now join together the path and the arguments once again 27365 if test "x$arguments" != xEOL; then 27366 new_complete="$new_path ${arguments% *}" 27367 else 27368 new_complete="$new_path" 27369 fi 27370 27371 if test "x$complete" != "x$new_complete"; then 27372 NM="$new_complete" 27373 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 27374 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 27375 fi 27376 27377 GNM="$NM" 27378 27379 if test -n "$ac_tool_prefix"; then 27380 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. 27381 set dummy ${ac_tool_prefix}strip; ac_word=$2 27382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27383 $as_echo_n "checking for $ac_word... " >&6; } 27384 if ${ac_cv_prog_STRIP+:} false; then : 27385 $as_echo_n "(cached) " >&6 27386 else 27387 if test -n "$STRIP"; then 27388 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 27389 else 27390 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27391 for as_dir in $PATH 27392 do 27393 IFS=$as_save_IFS 27394 test -z "$as_dir" && as_dir=. 27395 for ac_exec_ext in '' $ac_executable_extensions; do 27396 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27397 ac_cv_prog_STRIP="${ac_tool_prefix}strip" 27398 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27399 break 2 27400 fi 27401 done 27402 done 27403 IFS=$as_save_IFS 27404 27405 fi 27406 fi 27407 STRIP=$ac_cv_prog_STRIP 27408 if test -n "$STRIP"; then 27409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 27410 $as_echo "$STRIP" >&6; } 27411 else 27412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27413 $as_echo "no" >&6; } 27414 fi 27415 27416 27417 fi 27418 if test -z "$ac_cv_prog_STRIP"; then 27419 ac_ct_STRIP=$STRIP 27420 # Extract the first word of "strip", so it can be a program name with args. 27421 set dummy strip; ac_word=$2 27422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27423 $as_echo_n "checking for $ac_word... " >&6; } 27424 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 27425 $as_echo_n "(cached) " >&6 27426 else 27427 if test -n "$ac_ct_STRIP"; then 27428 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 27429 else 27430 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27431 for as_dir in $PATH 27432 do 27433 IFS=$as_save_IFS 27434 test -z "$as_dir" && as_dir=. 27435 for ac_exec_ext in '' $ac_executable_extensions; do 27436 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27437 ac_cv_prog_ac_ct_STRIP="strip" 27438 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27439 break 2 27440 fi 27441 done 27442 done 27443 IFS=$as_save_IFS 27444 27445 fi 27446 fi 27447 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 27448 if test -n "$ac_ct_STRIP"; then 27449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 27450 $as_echo "$ac_ct_STRIP" >&6; } 27451 else 27452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27453 $as_echo "no" >&6; } 27454 fi 27455 27456 if test "x$ac_ct_STRIP" = x; then 27457 STRIP="" 27458 else 27459 case $cross_compiling:$ac_tool_warned in 27460 yes:) 27461 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 27462 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 27463 ac_tool_warned=yes ;; 27464 esac 27465 STRIP=$ac_ct_STRIP 27466 fi 27467 else 27468 STRIP="$ac_cv_prog_STRIP" 27469 fi 27470 27471 27472 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27473 27474 # First separate the path from the arguments. This will split at the first 27475 # space. 27476 complete="$STRIP" 27477 path="${complete%% *}" 27478 tmp="$complete EOL" 27479 arguments="${tmp#* }" 27480 27481 # Input might be given as Windows format, start by converting to 27482 # unix format. 27483 new_path=`$CYGPATH -u "$path"` 27484 27485 # Now try to locate executable using which 27486 new_path=`$WHICH "$new_path" 2> /dev/null` 27487 # bat and cmd files are not always considered executable in cygwin causing which 27488 # to not find them 27489 if test "x$new_path" = x \ 27490 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 27491 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 27492 new_path=`$CYGPATH -u "$path"` 27493 fi 27494 if test "x$new_path" = x; then 27495 # Oops. Which didn't find the executable. 27496 # The splitting of arguments from the executable at a space might have been incorrect, 27497 # since paths with space are more likely in Windows. Give it another try with the whole 27498 # argument. 27499 path="$complete" 27500 arguments="EOL" 27501 new_path=`$CYGPATH -u "$path"` 27502 new_path=`$WHICH "$new_path" 2> /dev/null` 27503 # bat and cmd files are not always considered executable in cygwin causing which 27504 # to not find them 27505 if test "x$new_path" = x \ 27506 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 27507 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 27508 new_path=`$CYGPATH -u "$path"` 27509 fi 27510 if test "x$new_path" = x; then 27511 # It's still not found. Now this is an unrecoverable error. 27512 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 27513 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 27514 has_space=`$ECHO "$complete" | $GREP " "` 27515 if test "x$has_space" != x; then 27516 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27517 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27518 fi 27519 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 27520 fi 27521 fi 27522 27523 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27524 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27525 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27526 # "foo.exe" is OK but "foo" is an error. 27527 # 27528 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27529 # It is also a way to make sure we got the proper file name for the real test later on. 27530 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27531 if test "x$test_shortpath" = x; then 27532 # Short path failed, file does not exist as specified. 27533 # Try adding .exe or .cmd 27534 if test -f "${new_path}.exe"; then 27535 input_to_shortpath="${new_path}.exe" 27536 elif test -f "${new_path}.cmd"; then 27537 input_to_shortpath="${new_path}.cmd" 27538 else 27539 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 27540 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 27541 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 27542 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 27543 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 27544 fi 27545 else 27546 input_to_shortpath="$new_path" 27547 fi 27548 27549 # Call helper function which possibly converts this using DOS-style short mode. 27550 # If so, the updated path is stored in $new_path. 27551 new_path="$input_to_shortpath" 27552 27553 input_path="$input_to_shortpath" 27554 # Check if we need to convert this using DOS-style short mode. If the path 27555 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27556 # take no chances and rewrite it. 27557 # Note: m4 eats our [], so we need to use [ and ] instead. 27558 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27559 if test "x$has_forbidden_chars" != x; then 27560 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27561 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27562 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27563 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27564 # Going to short mode and back again did indeed matter. Since short mode is 27565 # case insensitive, let's make it lowercase to improve readability. 27566 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27567 # Now convert it back to Unix-stile (cygpath) 27568 input_path=`$CYGPATH -u "$shortmode_path"` 27569 new_path="$input_path" 27570 fi 27571 fi 27572 27573 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27574 if test "x$test_cygdrive_prefix" = x; then 27575 # As a simple fix, exclude /usr/bin since it's not a real path. 27576 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 27577 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27578 # a path prefixed by /cygdrive for fixpath to work. 27579 new_path="$CYGWIN_ROOT_PATH$input_path" 27580 fi 27581 fi 27582 27583 # remove trailing .exe if any 27584 new_path="${new_path/%.exe/}" 27585 27586 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27587 27588 # First separate the path from the arguments. This will split at the first 27589 # space. 27590 complete="$STRIP" 27591 path="${complete%% *}" 27592 tmp="$complete EOL" 27593 arguments="${tmp#* }" 27594 27595 # Input might be given as Windows format, start by converting to 27596 # unix format. 27597 new_path="$path" 27598 27599 windows_path="$new_path" 27600 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27601 unix_path=`$CYGPATH -u "$windows_path"` 27602 new_path="$unix_path" 27603 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27604 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27605 new_path="$unix_path" 27606 fi 27607 27608 27609 # Now try to locate executable using which 27610 new_path=`$WHICH "$new_path" 2> /dev/null` 27611 27612 if test "x$new_path" = x; then 27613 # Oops. Which didn't find the executable. 27614 # The splitting of arguments from the executable at a space might have been incorrect, 27615 # since paths with space are more likely in Windows. Give it another try with the whole 27616 # argument. 27617 path="$complete" 27618 arguments="EOL" 27619 new_path="$path" 27620 27621 windows_path="$new_path" 27622 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27623 unix_path=`$CYGPATH -u "$windows_path"` 27624 new_path="$unix_path" 27625 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27626 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27627 new_path="$unix_path" 27628 fi 27629 27630 27631 new_path=`$WHICH "$new_path" 2> /dev/null` 27632 27633 if test "x$new_path" = x; then 27634 # It's still not found. Now this is an unrecoverable error. 27635 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 27636 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 27637 has_space=`$ECHO "$complete" | $GREP " "` 27638 if test "x$has_space" != x; then 27639 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27640 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27641 fi 27642 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 27643 fi 27644 fi 27645 27646 # Now new_path has a complete unix path to the binary 27647 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 27648 # Keep paths in /bin as-is, but remove trailing .exe if any 27649 new_path="${new_path/%.exe/}" 27650 # Do not save /bin paths to all_fixpath_prefixes! 27651 else 27652 # Not in mixed or Windows style, start by that. 27653 new_path=`cmd //c echo $new_path` 27654 27655 input_path="$new_path" 27656 # Check if we need to convert this using DOS-style short mode. If the path 27657 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27658 # take no chances and rewrite it. 27659 # Note: m4 eats our [], so we need to use [ and ] instead. 27660 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27661 if test "x$has_forbidden_chars" != x; then 27662 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27663 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27664 fi 27665 27666 # Output is in $new_path 27667 27668 windows_path="$new_path" 27669 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27670 unix_path=`$CYGPATH -u "$windows_path"` 27671 new_path="$unix_path" 27672 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27673 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27674 new_path="$unix_path" 27675 fi 27676 27677 # remove trailing .exe if any 27678 new_path="${new_path/%.exe/}" 27679 27680 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27681 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27682 fi 27683 27684 else 27685 # We're on a posix platform. Hooray! :) 27686 # First separate the path from the arguments. This will split at the first 27687 # space. 27688 complete="$STRIP" 27689 path="${complete%% *}" 27690 tmp="$complete EOL" 27691 arguments="${tmp#* }" 27692 27693 # Cannot rely on the command "which" here since it doesn't always work. 27694 is_absolute_path=`$ECHO "$path" | $GREP ^/` 27695 if test -z "$is_absolute_path"; then 27696 # Path to executable is not absolute. Find it. 27697 IFS_save="$IFS" 27698 IFS=: 27699 for p in $PATH; do 27700 if test -f "$p/$path" && test -x "$p/$path"; then 27701 new_path="$p/$path" 27702 break 27703 fi 27704 done 27705 IFS="$IFS_save" 27706 else 27707 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving STRIP (as $path) failed, using $path directly." >&5 27708 $as_echo "$as_me: Resolving STRIP (as $path) failed, using $path directly." >&6;} 27709 new_path="$path" 27710 fi 27711 27712 if test "x$new_path" = x; then 27713 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 27714 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 27715 has_space=`$ECHO "$complete" | $GREP " "` 27716 if test "x$has_space" != x; then 27717 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 27718 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 27719 fi 27720 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 27721 fi 27722 fi 27723 27724 # Now join together the path and the arguments once again 27725 if test "x$arguments" != xEOL; then 27726 new_complete="$new_path ${arguments% *}" 27727 else 27728 new_complete="$new_path" 27729 fi 27730 27731 if test "x$complete" != "x$new_complete"; then 27732 STRIP="$new_complete" 27733 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 27734 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 27735 fi 27736 27737 fi 27738 27739 # objcopy is used for moving debug symbols to separate files when 27740 # full debug symbols are enabled. 27741 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 27742 if test -n "$ac_tool_prefix"; then 27743 for ac_prog in gobjcopy objcopy 27744 do 27745 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 27746 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 27747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27748 $as_echo_n "checking for $ac_word... " >&6; } 27749 if ${ac_cv_prog_OBJCOPY+:} false; then : 27750 $as_echo_n "(cached) " >&6 27751 else 27752 if test -n "$OBJCOPY"; then 27753 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 27754 else 27755 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27756 for as_dir in $PATH 27757 do 27758 IFS=$as_save_IFS 27759 test -z "$as_dir" && as_dir=. 27760 for ac_exec_ext in '' $ac_executable_extensions; do 27761 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27762 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 27763 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27764 break 2 27765 fi 27766 done 27767 done 27768 IFS=$as_save_IFS 27769 27770 fi 27771 fi 27772 OBJCOPY=$ac_cv_prog_OBJCOPY 27773 if test -n "$OBJCOPY"; then 27774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 27775 $as_echo "$OBJCOPY" >&6; } 27776 else 27777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27778 $as_echo "no" >&6; } 27779 fi 27780 27781 27782 test -n "$OBJCOPY" && break 27783 done 27784 fi 27785 if test -z "$OBJCOPY"; then 27786 ac_ct_OBJCOPY=$OBJCOPY 27787 for ac_prog in gobjcopy objcopy 27788 do 27789 # Extract the first word of "$ac_prog", so it can be a program name with args. 27790 set dummy $ac_prog; ac_word=$2 27791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27792 $as_echo_n "checking for $ac_word... " >&6; } 27793 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 27794 $as_echo_n "(cached) " >&6 27795 else 27796 if test -n "$ac_ct_OBJCOPY"; then 27797 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 27798 else 27799 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27800 for as_dir in $PATH 27801 do 27802 IFS=$as_save_IFS 27803 test -z "$as_dir" && as_dir=. 27804 for ac_exec_ext in '' $ac_executable_extensions; do 27805 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27806 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 27807 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27808 break 2 27809 fi 27810 done 27811 done 27812 IFS=$as_save_IFS 27813 27814 fi 27815 fi 27816 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 27817 if test -n "$ac_ct_OBJCOPY"; then 27818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 27819 $as_echo "$ac_ct_OBJCOPY" >&6; } 27820 else 27821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27822 $as_echo "no" >&6; } 27823 fi 27824 27825 27826 test -n "$ac_ct_OBJCOPY" && break 27827 done 27828 27829 if test "x$ac_ct_OBJCOPY" = x; then 27830 OBJCOPY="" 27831 else 27832 case $cross_compiling:$ac_tool_warned in 27833 yes:) 27834 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 27835 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 27836 ac_tool_warned=yes ;; 27837 esac 27838 OBJCOPY=$ac_ct_OBJCOPY 27839 fi 27840 fi 27841 27842 # Only call fixup if objcopy was found. 27843 if test -n "$OBJCOPY"; then 27844 27845 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27846 27847 # First separate the path from the arguments. This will split at the first 27848 # space. 27849 complete="$OBJCOPY" 27850 path="${complete%% *}" 27851 tmp="$complete EOL" 27852 arguments="${tmp#* }" 27853 27854 # Input might be given as Windows format, start by converting to 27855 # unix format. 27856 new_path=`$CYGPATH -u "$path"` 27857 27858 # Now try to locate executable using which 27859 new_path=`$WHICH "$new_path" 2> /dev/null` 27860 # bat and cmd files are not always considered executable in cygwin causing which 27861 # to not find them 27862 if test "x$new_path" = x \ 27863 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 27864 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 27865 new_path=`$CYGPATH -u "$path"` 27866 fi 27867 if test "x$new_path" = x; then 27868 # Oops. Which didn't find the executable. 27869 # The splitting of arguments from the executable at a space might have been incorrect, 27870 # since paths with space are more likely in Windows. Give it another try with the whole 27871 # argument. 27872 path="$complete" 27873 arguments="EOL" 27874 new_path=`$CYGPATH -u "$path"` 27875 new_path=`$WHICH "$new_path" 2> /dev/null` 27876 # bat and cmd files are not always considered executable in cygwin causing which 27877 # to not find them 27878 if test "x$new_path" = x \ 27879 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 27880 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 27881 new_path=`$CYGPATH -u "$path"` 27882 fi 27883 if test "x$new_path" = x; then 27884 # It's still not found. Now this is an unrecoverable error. 27885 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 27886 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 27887 has_space=`$ECHO "$complete" | $GREP " "` 27888 if test "x$has_space" != x; then 27889 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27890 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27891 fi 27892 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 27893 fi 27894 fi 27895 27896 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27897 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27898 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27899 # "foo.exe" is OK but "foo" is an error. 27900 # 27901 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27902 # It is also a way to make sure we got the proper file name for the real test later on. 27903 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27904 if test "x$test_shortpath" = x; then 27905 # Short path failed, file does not exist as specified. 27906 # Try adding .exe or .cmd 27907 if test -f "${new_path}.exe"; then 27908 input_to_shortpath="${new_path}.exe" 27909 elif test -f "${new_path}.cmd"; then 27910 input_to_shortpath="${new_path}.cmd" 27911 else 27912 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 27913 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 27914 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 27915 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 27916 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 27917 fi 27918 else 27919 input_to_shortpath="$new_path" 27920 fi 27921 27922 # Call helper function which possibly converts this using DOS-style short mode. 27923 # If so, the updated path is stored in $new_path. 27924 new_path="$input_to_shortpath" 27925 27926 input_path="$input_to_shortpath" 27927 # Check if we need to convert this using DOS-style short mode. If the path 27928 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27929 # take no chances and rewrite it. 27930 # Note: m4 eats our [], so we need to use [ and ] instead. 27931 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27932 if test "x$has_forbidden_chars" != x; then 27933 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27934 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27935 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27936 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27937 # Going to short mode and back again did indeed matter. Since short mode is 27938 # case insensitive, let's make it lowercase to improve readability. 27939 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27940 # Now convert it back to Unix-stile (cygpath) 27941 input_path=`$CYGPATH -u "$shortmode_path"` 27942 new_path="$input_path" 27943 fi 27944 fi 27945 27946 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27947 if test "x$test_cygdrive_prefix" = x; then 27948 # As a simple fix, exclude /usr/bin since it's not a real path. 27949 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 27950 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27951 # a path prefixed by /cygdrive for fixpath to work. 27952 new_path="$CYGWIN_ROOT_PATH$input_path" 27953 fi 27954 fi 27955 27956 # remove trailing .exe if any 27957 new_path="${new_path/%.exe/}" 27958 27959 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27960 27961 # First separate the path from the arguments. This will split at the first 27962 # space. 27963 complete="$OBJCOPY" 27964 path="${complete%% *}" 27965 tmp="$complete EOL" 27966 arguments="${tmp#* }" 27967 27968 # Input might be given as Windows format, start by converting to 27969 # unix format. 27970 new_path="$path" 27971 27972 windows_path="$new_path" 27973 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27974 unix_path=`$CYGPATH -u "$windows_path"` 27975 new_path="$unix_path" 27976 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27977 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27978 new_path="$unix_path" 27979 fi 27980 27981 27982 # Now try to locate executable using which 27983 new_path=`$WHICH "$new_path" 2> /dev/null` 27984 27985 if test "x$new_path" = x; then 27986 # Oops. Which didn't find the executable. 27987 # The splitting of arguments from the executable at a space might have been incorrect, 27988 # since paths with space are more likely in Windows. Give it another try with the whole 27989 # argument. 27990 path="$complete" 27991 arguments="EOL" 27992 new_path="$path" 27993 27994 windows_path="$new_path" 27995 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27996 unix_path=`$CYGPATH -u "$windows_path"` 27997 new_path="$unix_path" 27998 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27999 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28000 new_path="$unix_path" 28001 fi 28002 28003 28004 new_path=`$WHICH "$new_path" 2> /dev/null` 28005 28006 if test "x$new_path" = x; then 28007 # It's still not found. Now this is an unrecoverable error. 28008 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 28009 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 28010 has_space=`$ECHO "$complete" | $GREP " "` 28011 if test "x$has_space" != x; then 28012 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 28013 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 28014 fi 28015 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 28016 fi 28017 fi 28018 28019 # Now new_path has a complete unix path to the binary 28020 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 28021 # Keep paths in /bin as-is, but remove trailing .exe if any 28022 new_path="${new_path/%.exe/}" 28023 # Do not save /bin paths to all_fixpath_prefixes! 28024 else 28025 # Not in mixed or Windows style, start by that. 28026 new_path=`cmd //c echo $new_path` 28027 28028 input_path="$new_path" 28029 # Check if we need to convert this using DOS-style short mode. If the path 28030 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28031 # take no chances and rewrite it. 28032 # Note: m4 eats our [], so we need to use [ and ] instead. 28033 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28034 if test "x$has_forbidden_chars" != x; then 28035 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28036 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28037 fi 28038 28039 # Output is in $new_path 28040 28041 windows_path="$new_path" 28042 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28043 unix_path=`$CYGPATH -u "$windows_path"` 28044 new_path="$unix_path" 28045 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28046 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28047 new_path="$unix_path" 28048 fi 28049 28050 # remove trailing .exe if any 28051 new_path="${new_path/%.exe/}" 28052 28053 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28054 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28055 fi 28056 28057 else 28058 # We're on a posix platform. Hooray! :) 28059 # First separate the path from the arguments. This will split at the first 28060 # space. 28061 complete="$OBJCOPY" 28062 path="${complete%% *}" 28063 tmp="$complete EOL" 28064 arguments="${tmp#* }" 28065 28066 # Cannot rely on the command "which" here since it doesn't always work. 28067 is_absolute_path=`$ECHO "$path" | $GREP ^/` 28068 if test -z "$is_absolute_path"; then 28069 # Path to executable is not absolute. Find it. 28070 IFS_save="$IFS" 28071 IFS=: 28072 for p in $PATH; do 28073 if test -f "$p/$path" && test -x "$p/$path"; then 28074 new_path="$p/$path" 28075 break 28076 fi 28077 done 28078 IFS="$IFS_save" 28079 else 28080 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving OBJCOPY (as $path) failed, using $path directly." >&5 28081 $as_echo "$as_me: Resolving OBJCOPY (as $path) failed, using $path directly." >&6;} 28082 new_path="$path" 28083 fi 28084 28085 if test "x$new_path" = x; then 28086 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 28087 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 28088 has_space=`$ECHO "$complete" | $GREP " "` 28089 if test "x$has_space" != x; then 28090 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 28091 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 28092 fi 28093 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 28094 fi 28095 fi 28096 28097 # Now join together the path and the arguments once again 28098 if test "x$arguments" != xEOL; then 28099 new_complete="$new_path ${arguments% *}" 28100 else 28101 new_complete="$new_path" 28102 fi 28103 28104 if test "x$complete" != "x$new_complete"; then 28105 OBJCOPY="$new_complete" 28106 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5 28107 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;} 28108 fi 28109 28110 fi 28111 fi 28112 28113 if test -n "$ac_tool_prefix"; then 28114 for ac_prog in gobjdump objdump 28115 do 28116 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 28117 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 28118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 28119 $as_echo_n "checking for $ac_word... " >&6; } 28120 if ${ac_cv_prog_OBJDUMP+:} false; then : 28121 $as_echo_n "(cached) " >&6 28122 else 28123 if test -n "$OBJDUMP"; then 28124 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 28125 else 28126 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 28127 for as_dir in $PATH 28128 do 28129 IFS=$as_save_IFS 28130 test -z "$as_dir" && as_dir=. 28131 for ac_exec_ext in '' $ac_executable_extensions; do 28132 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 28133 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 28134 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 28135 break 2 28136 fi 28137 done 28138 done 28139 IFS=$as_save_IFS 28140 28141 fi 28142 fi 28143 OBJDUMP=$ac_cv_prog_OBJDUMP 28144 if test -n "$OBJDUMP"; then 28145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 28146 $as_echo "$OBJDUMP" >&6; } 28147 else 28148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 28149 $as_echo "no" >&6; } 28150 fi 28151 28152 28153 test -n "$OBJDUMP" && break 28154 done 28155 fi 28156 if test -z "$OBJDUMP"; then 28157 ac_ct_OBJDUMP=$OBJDUMP 28158 for ac_prog in gobjdump objdump 28159 do 28160 # Extract the first word of "$ac_prog", so it can be a program name with args. 28161 set dummy $ac_prog; ac_word=$2 28162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 28163 $as_echo_n "checking for $ac_word... " >&6; } 28164 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 28165 $as_echo_n "(cached) " >&6 28166 else 28167 if test -n "$ac_ct_OBJDUMP"; then 28168 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 28169 else 28170 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 28171 for as_dir in $PATH 28172 do 28173 IFS=$as_save_IFS 28174 test -z "$as_dir" && as_dir=. 28175 for ac_exec_ext in '' $ac_executable_extensions; do 28176 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 28177 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 28178 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 28179 break 2 28180 fi 28181 done 28182 done 28183 IFS=$as_save_IFS 28184 28185 fi 28186 fi 28187 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 28188 if test -n "$ac_ct_OBJDUMP"; then 28189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 28190 $as_echo "$ac_ct_OBJDUMP" >&6; } 28191 else 28192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 28193 $as_echo "no" >&6; } 28194 fi 28195 28196 28197 test -n "$ac_ct_OBJDUMP" && break 28198 done 28199 28200 if test "x$ac_ct_OBJDUMP" = x; then 28201 OBJDUMP="" 28202 else 28203 case $cross_compiling:$ac_tool_warned in 28204 yes:) 28205 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 28206 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 28207 ac_tool_warned=yes ;; 28208 esac 28209 OBJDUMP=$ac_ct_OBJDUMP 28210 fi 28211 fi 28212 28213 if test "x$OBJDUMP" != x; then 28214 # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE bails if argument is missing. 28215 28216 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28217 28218 # First separate the path from the arguments. This will split at the first 28219 # space. 28220 complete="$OBJDUMP" 28221 path="${complete%% *}" 28222 tmp="$complete EOL" 28223 arguments="${tmp#* }" 28224 28225 # Input might be given as Windows format, start by converting to 28226 # unix format. 28227 new_path=`$CYGPATH -u "$path"` 28228 28229 # Now try to locate executable using which 28230 new_path=`$WHICH "$new_path" 2> /dev/null` 28231 # bat and cmd files are not always considered executable in cygwin causing which 28232 # to not find them 28233 if test "x$new_path" = x \ 28234 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 28235 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 28236 new_path=`$CYGPATH -u "$path"` 28237 fi 28238 if test "x$new_path" = x; then 28239 # Oops. Which didn't find the executable. 28240 # The splitting of arguments from the executable at a space might have been incorrect, 28241 # since paths with space are more likely in Windows. Give it another try with the whole 28242 # argument. 28243 path="$complete" 28244 arguments="EOL" 28245 new_path=`$CYGPATH -u "$path"` 28246 new_path=`$WHICH "$new_path" 2> /dev/null` 28247 # bat and cmd files are not always considered executable in cygwin causing which 28248 # to not find them 28249 if test "x$new_path" = x \ 28250 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 28251 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 28252 new_path=`$CYGPATH -u "$path"` 28253 fi 28254 if test "x$new_path" = x; then 28255 # It's still not found. Now this is an unrecoverable error. 28256 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 28257 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 28258 has_space=`$ECHO "$complete" | $GREP " "` 28259 if test "x$has_space" != x; then 28260 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 28261 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 28262 fi 28263 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 28264 fi 28265 fi 28266 28267 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28268 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28269 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28270 # "foo.exe" is OK but "foo" is an error. 28271 # 28272 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28273 # It is also a way to make sure we got the proper file name for the real test later on. 28274 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28275 if test "x$test_shortpath" = x; then 28276 # Short path failed, file does not exist as specified. 28277 # Try adding .exe or .cmd 28278 if test -f "${new_path}.exe"; then 28279 input_to_shortpath="${new_path}.exe" 28280 elif test -f "${new_path}.cmd"; then 28281 input_to_shortpath="${new_path}.cmd" 28282 else 28283 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5 28284 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;} 28285 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 28286 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 28287 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 28288 fi 28289 else 28290 input_to_shortpath="$new_path" 28291 fi 28292 28293 # Call helper function which possibly converts this using DOS-style short mode. 28294 # If so, the updated path is stored in $new_path. 28295 new_path="$input_to_shortpath" 28296 28297 input_path="$input_to_shortpath" 28298 # Check if we need to convert this using DOS-style short mode. If the path 28299 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28300 # take no chances and rewrite it. 28301 # Note: m4 eats our [], so we need to use [ and ] instead. 28302 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28303 if test "x$has_forbidden_chars" != x; then 28304 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28305 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28306 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28307 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28308 # Going to short mode and back again did indeed matter. Since short mode is 28309 # case insensitive, let's make it lowercase to improve readability. 28310 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28311 # Now convert it back to Unix-stile (cygpath) 28312 input_path=`$CYGPATH -u "$shortmode_path"` 28313 new_path="$input_path" 28314 fi 28315 fi 28316 28317 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28318 if test "x$test_cygdrive_prefix" = x; then 28319 # As a simple fix, exclude /usr/bin since it's not a real path. 28320 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 28321 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28322 # a path prefixed by /cygdrive for fixpath to work. 28323 new_path="$CYGWIN_ROOT_PATH$input_path" 28324 fi 28325 fi 28326 28327 # remove trailing .exe if any 28328 new_path="${new_path/%.exe/}" 28329 28330 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28331 28332 # First separate the path from the arguments. This will split at the first 28333 # space. 28334 complete="$OBJDUMP" 28335 path="${complete%% *}" 28336 tmp="$complete EOL" 28337 arguments="${tmp#* }" 28338 28339 # Input might be given as Windows format, start by converting to 28340 # unix format. 28341 new_path="$path" 28342 28343 windows_path="$new_path" 28344 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28345 unix_path=`$CYGPATH -u "$windows_path"` 28346 new_path="$unix_path" 28347 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28348 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28349 new_path="$unix_path" 28350 fi 28351 28352 28353 # Now try to locate executable using which 28354 new_path=`$WHICH "$new_path" 2> /dev/null` 28355 28356 if test "x$new_path" = x; then 28357 # Oops. Which didn't find the executable. 28358 # The splitting of arguments from the executable at a space might have been incorrect, 28359 # since paths with space are more likely in Windows. Give it another try with the whole 28360 # argument. 28361 path="$complete" 28362 arguments="EOL" 28363 new_path="$path" 28364 28365 windows_path="$new_path" 28366 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28367 unix_path=`$CYGPATH -u "$windows_path"` 28368 new_path="$unix_path" 28369 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28370 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28371 new_path="$unix_path" 28372 fi 28373 28374 28375 new_path=`$WHICH "$new_path" 2> /dev/null` 28376 28377 if test "x$new_path" = x; then 28378 # It's still not found. Now this is an unrecoverable error. 28379 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 28380 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 28381 has_space=`$ECHO "$complete" | $GREP " "` 28382 if test "x$has_space" != x; then 28383 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 28384 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 28385 fi 28386 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 28387 fi 28388 fi 28389 28390 # Now new_path has a complete unix path to the binary 28391 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 28392 # Keep paths in /bin as-is, but remove trailing .exe if any 28393 new_path="${new_path/%.exe/}" 28394 # Do not save /bin paths to all_fixpath_prefixes! 28395 else 28396 # Not in mixed or Windows style, start by that. 28397 new_path=`cmd //c echo $new_path` 28398 28399 input_path="$new_path" 28400 # Check if we need to convert this using DOS-style short mode. If the path 28401 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28402 # take no chances and rewrite it. 28403 # Note: m4 eats our [], so we need to use [ and ] instead. 28404 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28405 if test "x$has_forbidden_chars" != x; then 28406 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28407 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28408 fi 28409 28410 # Output is in $new_path 28411 28412 windows_path="$new_path" 28413 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28414 unix_path=`$CYGPATH -u "$windows_path"` 28415 new_path="$unix_path" 28416 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28417 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28418 new_path="$unix_path" 28419 fi 28420 28421 # remove trailing .exe if any 28422 new_path="${new_path/%.exe/}" 28423 28424 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28425 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28426 fi 28427 28428 else 28429 # We're on a posix platform. Hooray! :) 28430 # First separate the path from the arguments. This will split at the first 28431 # space. 28432 complete="$OBJDUMP" 28433 path="${complete%% *}" 28434 tmp="$complete EOL" 28435 arguments="${tmp#* }" 28436 28437 # Cannot rely on the command "which" here since it doesn't always work. 28438 is_absolute_path=`$ECHO "$path" | $GREP ^/` 28439 if test -z "$is_absolute_path"; then 28440 # Path to executable is not absolute. Find it. 28441 IFS_save="$IFS" 28442 IFS=: 28443 for p in $PATH; do 28444 if test -f "$p/$path" && test -x "$p/$path"; then 28445 new_path="$p/$path" 28446 break 28447 fi 28448 done 28449 IFS="$IFS_save" 28450 else 28451 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving OBJDUMP (as $path) failed, using $path directly." >&5 28452 $as_echo "$as_me: Resolving OBJDUMP (as $path) failed, using $path directly." >&6;} 28453 new_path="$path" 28454 fi 28455 28456 if test "x$new_path" = x; then 28457 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 28458 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 28459 has_space=`$ECHO "$complete" | $GREP " "` 28460 if test "x$has_space" != x; then 28461 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 28462 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 28463 fi 28464 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 28465 fi 28466 fi 28467 28468 # Now join together the path and the arguments once again 28469 if test "x$arguments" != xEOL; then 28470 new_complete="$new_path ${arguments% *}" 28471 else 28472 new_complete="$new_path" 28473 fi 28474 28475 if test "x$complete" != "x$new_complete"; then 28476 OBJDUMP="$new_complete" 28477 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5 28478 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;} 28479 fi 28480 28481 fi 28482 28483 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 28484 # Extract the first word of "lipo", so it can be a program name with args. 28485 set dummy lipo; ac_word=$2 28486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 28487 $as_echo_n "checking for $ac_word... " >&6; } 28488 if ${ac_cv_path_LIPO+:} false; then : 28489 $as_echo_n "(cached) " >&6 28490 else 28491 case $LIPO in 28492 [\\/]* | ?:[\\/]*) 28493 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 28494 ;; 28495 *) 28496 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 28497 for as_dir in $PATH 28498 do 28499 IFS=$as_save_IFS 28500 test -z "$as_dir" && as_dir=. 28501 for ac_exec_ext in '' $ac_executable_extensions; do 28502 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 28503 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 28504 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 28505 break 2 28506 fi 28507 done 28508 done 28509 IFS=$as_save_IFS 28510 28511 ;; 28512 esac 28513 fi 28514 LIPO=$ac_cv_path_LIPO 28515 if test -n "$LIPO"; then 28516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 28517 $as_echo "$LIPO" >&6; } 28518 else 28519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 28520 $as_echo "no" >&6; } 28521 fi 28522 28523 28524 28525 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28526 28527 # First separate the path from the arguments. This will split at the first 28528 # space. 28529 complete="$LIPO" 28530 path="${complete%% *}" 28531 tmp="$complete EOL" 28532 arguments="${tmp#* }" 28533 28534 # Input might be given as Windows format, start by converting to 28535 # unix format. 28536 new_path=`$CYGPATH -u "$path"` 28537 28538 # Now try to locate executable using which 28539 new_path=`$WHICH "$new_path" 2> /dev/null` 28540 # bat and cmd files are not always considered executable in cygwin causing which 28541 # to not find them 28542 if test "x$new_path" = x \ 28543 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 28544 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 28545 new_path=`$CYGPATH -u "$path"` 28546 fi 28547 if test "x$new_path" = x; then 28548 # Oops. Which didn't find the executable. 28549 # The splitting of arguments from the executable at a space might have been incorrect, 28550 # since paths with space are more likely in Windows. Give it another try with the whole 28551 # argument. 28552 path="$complete" 28553 arguments="EOL" 28554 new_path=`$CYGPATH -u "$path"` 28555 new_path=`$WHICH "$new_path" 2> /dev/null` 28556 # bat and cmd files are not always considered executable in cygwin causing which 28557 # to not find them 28558 if test "x$new_path" = x \ 28559 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 28560 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 28561 new_path=`$CYGPATH -u "$path"` 28562 fi 28563 if test "x$new_path" = x; then 28564 # It's still not found. Now this is an unrecoverable error. 28565 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 28566 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 28567 has_space=`$ECHO "$complete" | $GREP " "` 28568 if test "x$has_space" != x; then 28569 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 28570 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 28571 fi 28572 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 28573 fi 28574 fi 28575 28576 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28577 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28578 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28579 # "foo.exe" is OK but "foo" is an error. 28580 # 28581 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28582 # It is also a way to make sure we got the proper file name for the real test later on. 28583 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28584 if test "x$test_shortpath" = x; then 28585 # Short path failed, file does not exist as specified. 28586 # Try adding .exe or .cmd 28587 if test -f "${new_path}.exe"; then 28588 input_to_shortpath="${new_path}.exe" 28589 elif test -f "${new_path}.cmd"; then 28590 input_to_shortpath="${new_path}.cmd" 28591 else 28592 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5 28593 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;} 28594 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 28595 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 28596 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 28597 fi 28598 else 28599 input_to_shortpath="$new_path" 28600 fi 28601 28602 # Call helper function which possibly converts this using DOS-style short mode. 28603 # If so, the updated path is stored in $new_path. 28604 new_path="$input_to_shortpath" 28605 28606 input_path="$input_to_shortpath" 28607 # Check if we need to convert this using DOS-style short mode. If the path 28608 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28609 # take no chances and rewrite it. 28610 # Note: m4 eats our [], so we need to use [ and ] instead. 28611 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28612 if test "x$has_forbidden_chars" != x; then 28613 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28614 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28615 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28616 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28617 # Going to short mode and back again did indeed matter. Since short mode is 28618 # case insensitive, let's make it lowercase to improve readability. 28619 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28620 # Now convert it back to Unix-stile (cygpath) 28621 input_path=`$CYGPATH -u "$shortmode_path"` 28622 new_path="$input_path" 28623 fi 28624 fi 28625 28626 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28627 if test "x$test_cygdrive_prefix" = x; then 28628 # As a simple fix, exclude /usr/bin since it's not a real path. 28629 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 28630 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28631 # a path prefixed by /cygdrive for fixpath to work. 28632 new_path="$CYGWIN_ROOT_PATH$input_path" 28633 fi 28634 fi 28635 28636 # remove trailing .exe if any 28637 new_path="${new_path/%.exe/}" 28638 28639 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28640 28641 # First separate the path from the arguments. This will split at the first 28642 # space. 28643 complete="$LIPO" 28644 path="${complete%% *}" 28645 tmp="$complete EOL" 28646 arguments="${tmp#* }" 28647 28648 # Input might be given as Windows format, start by converting to 28649 # unix format. 28650 new_path="$path" 28651 28652 windows_path="$new_path" 28653 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28654 unix_path=`$CYGPATH -u "$windows_path"` 28655 new_path="$unix_path" 28656 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28657 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28658 new_path="$unix_path" 28659 fi 28660 28661 28662 # Now try to locate executable using which 28663 new_path=`$WHICH "$new_path" 2> /dev/null` 28664 28665 if test "x$new_path" = x; then 28666 # Oops. Which didn't find the executable. 28667 # The splitting of arguments from the executable at a space might have been incorrect, 28668 # since paths with space are more likely in Windows. Give it another try with the whole 28669 # argument. 28670 path="$complete" 28671 arguments="EOL" 28672 new_path="$path" 28673 28674 windows_path="$new_path" 28675 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28676 unix_path=`$CYGPATH -u "$windows_path"` 28677 new_path="$unix_path" 28678 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28679 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28680 new_path="$unix_path" 28681 fi 28682 28683 28684 new_path=`$WHICH "$new_path" 2> /dev/null` 28685 28686 if test "x$new_path" = x; then 28687 # It's still not found. Now this is an unrecoverable error. 28688 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 28689 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 28690 has_space=`$ECHO "$complete" | $GREP " "` 28691 if test "x$has_space" != x; then 28692 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 28693 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 28694 fi 28695 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 28696 fi 28697 fi 28698 28699 # Now new_path has a complete unix path to the binary 28700 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 28701 # Keep paths in /bin as-is, but remove trailing .exe if any 28702 new_path="${new_path/%.exe/}" 28703 # Do not save /bin paths to all_fixpath_prefixes! 28704 else 28705 # Not in mixed or Windows style, start by that. 28706 new_path=`cmd //c echo $new_path` 28707 28708 input_path="$new_path" 28709 # Check if we need to convert this using DOS-style short mode. If the path 28710 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28711 # take no chances and rewrite it. 28712 # Note: m4 eats our [], so we need to use [ and ] instead. 28713 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28714 if test "x$has_forbidden_chars" != x; then 28715 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28716 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28717 fi 28718 28719 # Output is in $new_path 28720 28721 windows_path="$new_path" 28722 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28723 unix_path=`$CYGPATH -u "$windows_path"` 28724 new_path="$unix_path" 28725 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28726 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28727 new_path="$unix_path" 28728 fi 28729 28730 # remove trailing .exe if any 28731 new_path="${new_path/%.exe/}" 28732 28733 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28734 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28735 fi 28736 28737 else 28738 # We're on a posix platform. Hooray! :) 28739 # First separate the path from the arguments. This will split at the first 28740 # space. 28741 complete="$LIPO" 28742 path="${complete%% *}" 28743 tmp="$complete EOL" 28744 arguments="${tmp#* }" 28745 28746 # Cannot rely on the command "which" here since it doesn't always work. 28747 is_absolute_path=`$ECHO "$path" | $GREP ^/` 28748 if test -z "$is_absolute_path"; then 28749 # Path to executable is not absolute. Find it. 28750 IFS_save="$IFS" 28751 IFS=: 28752 for p in $PATH; do 28753 if test -f "$p/$path" && test -x "$p/$path"; then 28754 new_path="$p/$path" 28755 break 28756 fi 28757 done 28758 IFS="$IFS_save" 28759 else 28760 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving LIPO (as $path) failed, using $path directly." >&5 28761 $as_echo "$as_me: Resolving LIPO (as $path) failed, using $path directly." >&6;} 28762 new_path="$path" 28763 fi 28764 28765 if test "x$new_path" = x; then 28766 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 28767 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 28768 has_space=`$ECHO "$complete" | $GREP " "` 28769 if test "x$has_space" != x; then 28770 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 28771 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 28772 fi 28773 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 28774 fi 28775 fi 28776 28777 # Now join together the path and the arguments once again 28778 if test "x$arguments" != xEOL; then 28779 new_complete="$new_path ${arguments% *}" 28780 else 28781 new_complete="$new_path" 28782 fi 28783 28784 if test "x$complete" != "x$new_complete"; then 28785 LIPO="$new_complete" 28786 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5 28787 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;} 28788 fi 28789 28790 fi 28791 28792 # Restore old path without tools dir 28793 PATH="$OLD_PATH" 28794 28795 28796 # FIXME: Currently we must test this after paths but before flags. Fix! 28797 28798 # And we can test some aspects on the target using configure macros. 28799 28800 28801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 28802 $as_echo_n "checking for ANSI C header files... " >&6; } 28803 if ${ac_cv_header_stdc+:} false; then : 28804 $as_echo_n "(cached) " >&6 28805 else 28806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28807 /* end confdefs.h. */ 28808 #include <stdlib.h> 28809 #include <stdarg.h> 28810 #include <string.h> 28811 #include <float.h> 28812 28813 int 28814 main () 28815 { 28816 28817 ; 28818 return 0; 28819 } 28820 _ACEOF 28821 if ac_fn_cxx_try_compile "$LINENO"; then : 28822 ac_cv_header_stdc=yes 28823 else 28824 ac_cv_header_stdc=no 28825 fi 28826 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 28827 28828 if test $ac_cv_header_stdc = yes; then 28829 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 28830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28831 /* end confdefs.h. */ 28832 #include <string.h> 28833 28834 _ACEOF 28835 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 28836 $EGREP "memchr" >/dev/null 2>&1; then : 28837 28838 else 28839 ac_cv_header_stdc=no 28840 fi 28841 rm -f conftest* 28842 28843 fi 28844 28845 if test $ac_cv_header_stdc = yes; then 28846 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 28847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28848 /* end confdefs.h. */ 28849 #include <stdlib.h> 28850 28851 _ACEOF 28852 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 28853 $EGREP "free" >/dev/null 2>&1; then : 28854 28855 else 28856 ac_cv_header_stdc=no 28857 fi 28858 rm -f conftest* 28859 28860 fi 28861 28862 if test $ac_cv_header_stdc = yes; then 28863 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 28864 if test "$cross_compiling" = yes; then : 28865 : 28866 else 28867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28868 /* end confdefs.h. */ 28869 #include <ctype.h> 28870 #include <stdlib.h> 28871 #if ((' ' & 0x0FF) == 0x020) 28872 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 28873 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 28874 #else 28875 # define ISLOWER(c) \ 28876 (('a' <= (c) && (c) <= 'i') \ 28877 || ('j' <= (c) && (c) <= 'r') \ 28878 || ('s' <= (c) && (c) <= 'z')) 28879 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 28880 #endif 28881 28882 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 28883 int 28884 main () 28885 { 28886 int i; 28887 for (i = 0; i < 256; i++) 28888 if (XOR (islower (i), ISLOWER (i)) 28889 || toupper (i) != TOUPPER (i)) 28890 return 2; 28891 return 0; 28892 } 28893 _ACEOF 28894 if ac_fn_cxx_try_run "$LINENO"; then : 28895 28896 else 28897 ac_cv_header_stdc=no 28898 fi 28899 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 28900 conftest.$ac_objext conftest.beam conftest.$ac_ext 28901 fi 28902 28903 fi 28904 fi 28905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 28906 $as_echo "$ac_cv_header_stdc" >&6; } 28907 if test $ac_cv_header_stdc = yes; then 28908 28909 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 28910 28911 fi 28912 28913 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 28914 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 28915 inttypes.h stdint.h unistd.h 28916 do : 28917 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 28918 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 28919 " 28920 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 28921 cat >>confdefs.h <<_ACEOF 28922 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 28923 _ACEOF 28924 28925 fi 28926 28927 done 28928 28929 28930 28931 ############################################################################### 28932 # 28933 # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code. 28934 # (The JVM can use 32 or 64 bit Java pointers but that decision 28935 # is made at runtime.) 28936 # 28937 28938 28939 28940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"\"-m${OPENJDK_TARGET_CPU_BITS}\"\"" >&5 28941 $as_echo_n "checking if compiler supports \"\"-m${OPENJDK_TARGET_CPU_BITS}\"\"... " >&6; } 28942 saved_cflags="$CFLAGS" 28943 CFLAGS=""-m${OPENJDK_TARGET_CPU_BITS}"" 28944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28945 /* end confdefs.h. */ 28946 28947 28948 int main() { return 0; } 28949 28950 28951 _ACEOF 28952 if ac_fn_cxx_try_compile "$LINENO"; then : 28953 supports=yes 28954 else 28955 supports=no 28956 fi 28957 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 28958 CFLAGS="$saved_cflags" 28959 if "x$supports" = "xyes" ; then 28960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 28961 $as_echo "$supports" >&6; } 28962 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 28963 else 28964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 28965 $as_echo "$supports" >&6; } 28966 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 28967 fi 28968 28969 28970 28971 28972 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 28973 # Always specify -m flags on Solaris 28974 28975 28976 # keep track of c/cxx flags that we added outselves... 28977 # to prevent emitting warning... 28978 ADDED_CFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}" 28979 ADDED_CXXFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}" 28980 ADDED_LDFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}" 28981 28982 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 28983 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 28984 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 28985 28986 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 28987 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 28988 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 28989 28990 elif test "x$COMPILE_TYPE" = xreduced; then 28991 if test "x$OPENJDK_TARGET_OS" != xwindows; then 28992 # Specify -m if running reduced on other Posix platforms 28993 28994 28995 # keep track of c/cxx flags that we added outselves... 28996 # to prevent emitting warning... 28997 ADDED_CFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}" 28998 ADDED_CXXFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}" 28999 ADDED_LDFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}" 29000 29001 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 29002 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 29003 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 29004 29005 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 29006 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 29007 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 29008 29009 fi 29010 fi 29011 29012 # Make compilation sanity check 29013 for ac_header in stdio.h 29014 do : 29015 ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default" 29016 if test "x$ac_cv_header_stdio_h" = xyes; then : 29017 cat >>confdefs.h <<_ACEOF 29018 #define HAVE_STDIO_H 1 29019 _ACEOF 29020 29021 else 29022 29023 { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5 29024 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;} 29025 if test "x$COMPILE_TYPE" = xreduced; then 29026 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed." >&5 29027 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed." >&6;} 29028 elif test "x$COMPILE_TYPE" = xcross; then 29029 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 29030 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 29031 fi 29032 as_fn_error $? "Cannot continue." "$LINENO" 5 29033 29034 fi 29035 29036 done 29037 29038 29039 # The cast to long int works around a bug in the HP C Compiler 29040 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 29041 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 29042 # This bug is HP SR number 8606223364. 29043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 29044 $as_echo_n "checking size of int *... " >&6; } 29045 if ${ac_cv_sizeof_int_p+:} false; then : 29046 $as_echo_n "(cached) " >&6 29047 else 29048 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 29049 29050 else 29051 if test "$ac_cv_type_int_p" = yes; then 29052 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 29053 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 29054 as_fn_error 77 "cannot compute sizeof (int *) 29055 See \`config.log' for more details" "$LINENO" 5; } 29056 else 29057 ac_cv_sizeof_int_p=0 29058 fi 29059 fi 29060 29061 fi 29062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 29063 $as_echo "$ac_cv_sizeof_int_p" >&6; } 29064 29065 29066 29067 cat >>confdefs.h <<_ACEOF 29068 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 29069 _ACEOF 29070 29071 29072 29073 if test "x$SIZEOF_INT_P" != "x$ac_cv_sizeof_int_p"; then 29074 # Workaround autoconf bug, see http://lists.gnu.org/archive/html/autoconf/2010-07/msg00004.html 29075 SIZEOF_INT_P="$ac_cv_sizeof_int_p" 29076 fi 29077 29078 if test "x$SIZEOF_INT_P" = x; then 29079 # The test failed, lets stick to the assumed value. 29080 { $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 29081 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;} 29082 else 29083 TESTED_TARGET_CPU_BITS=`expr 8 \* $SIZEOF_INT_P` 29084 29085 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 29086 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 29087 fi 29088 fi 29089 29090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5 29091 $as_echo_n "checking for target address size... " >&6; } 29092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5 29093 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; } 29094 29095 29096 ############################################################################### 29097 # 29098 # Is the target little of big endian? 29099 # 29100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 29101 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } 29102 if ${ac_cv_c_bigendian+:} false; then : 29103 $as_echo_n "(cached) " >&6 29104 else 29105 ac_cv_c_bigendian=unknown 29106 # See if we're dealing with a universal compiler. 29107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29108 /* end confdefs.h. */ 29109 #ifndef __APPLE_CC__ 29110 not a universal capable compiler 29111 #endif 29112 typedef int dummy; 29113 29114 _ACEOF 29115 if ac_fn_cxx_try_compile "$LINENO"; then : 29116 29117 # Check for potential -arch flags. It is not universal unless 29118 # there are at least two -arch flags with different values. 29119 ac_arch= 29120 ac_prev= 29121 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 29122 if test -n "$ac_prev"; then 29123 case $ac_word in 29124 i?86 | x86_64 | ppc | ppc64) 29125 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 29126 ac_arch=$ac_word 29127 else 29128 ac_cv_c_bigendian=universal 29129 break 29130 fi 29131 ;; 29132 esac 29133 ac_prev= 29134 elif test "x$ac_word" = "x-arch"; then 29135 ac_prev=arch 29136 fi 29137 done 29138 fi 29139 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29140 if test $ac_cv_c_bigendian = unknown; then 29141 # See if sys/param.h defines the BYTE_ORDER macro. 29142 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29143 /* end confdefs.h. */ 29144 #include <sys/types.h> 29145 #include <sys/param.h> 29146 29147 int 29148 main () 29149 { 29150 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 29151 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 29152 && LITTLE_ENDIAN) 29153 bogus endian macros 29154 #endif 29155 29156 ; 29157 return 0; 29158 } 29159 _ACEOF 29160 if ac_fn_cxx_try_compile "$LINENO"; then : 29161 # It does; now see whether it defined to BIG_ENDIAN or not. 29162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29163 /* end confdefs.h. */ 29164 #include <sys/types.h> 29165 #include <sys/param.h> 29166 29167 int 29168 main () 29169 { 29170 #if BYTE_ORDER != BIG_ENDIAN 29171 not big endian 29172 #endif 29173 29174 ; 29175 return 0; 29176 } 29177 _ACEOF 29178 if ac_fn_cxx_try_compile "$LINENO"; then : 29179 ac_cv_c_bigendian=yes 29180 else 29181 ac_cv_c_bigendian=no 29182 fi 29183 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29184 fi 29185 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29186 fi 29187 if test $ac_cv_c_bigendian = unknown; then 29188 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 29189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29190 /* end confdefs.h. */ 29191 #include <limits.h> 29192 29193 int 29194 main () 29195 { 29196 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 29197 bogus endian macros 29198 #endif 29199 29200 ; 29201 return 0; 29202 } 29203 _ACEOF 29204 if ac_fn_cxx_try_compile "$LINENO"; then : 29205 # It does; now see whether it defined to _BIG_ENDIAN or not. 29206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29207 /* end confdefs.h. */ 29208 #include <limits.h> 29209 29210 int 29211 main () 29212 { 29213 #ifndef _BIG_ENDIAN 29214 not big endian 29215 #endif 29216 29217 ; 29218 return 0; 29219 } 29220 _ACEOF 29221 if ac_fn_cxx_try_compile "$LINENO"; then : 29222 ac_cv_c_bigendian=yes 29223 else 29224 ac_cv_c_bigendian=no 29225 fi 29226 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29227 fi 29228 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29229 fi 29230 if test $ac_cv_c_bigendian = unknown; then 29231 # Compile a test program. 29232 if test "$cross_compiling" = yes; then : 29233 # Try to guess by grepping values from an object file. 29234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29235 /* end confdefs.h. */ 29236 short int ascii_mm[] = 29237 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 29238 short int ascii_ii[] = 29239 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 29240 int use_ascii (int i) { 29241 return ascii_mm[i] + ascii_ii[i]; 29242 } 29243 short int ebcdic_ii[] = 29244 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 29245 short int ebcdic_mm[] = 29246 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 29247 int use_ebcdic (int i) { 29248 return ebcdic_mm[i] + ebcdic_ii[i]; 29249 } 29250 extern int foo; 29251 29252 int 29253 main () 29254 { 29255 return use_ascii (foo) == use_ebcdic (foo); 29256 ; 29257 return 0; 29258 } 29259 _ACEOF 29260 if ac_fn_cxx_try_compile "$LINENO"; then : 29261 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 29262 ac_cv_c_bigendian=yes 29263 fi 29264 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 29265 if test "$ac_cv_c_bigendian" = unknown; then 29266 ac_cv_c_bigendian=no 29267 else 29268 # finding both strings is unlikely to happen, but who knows? 29269 ac_cv_c_bigendian=unknown 29270 fi 29271 fi 29272 fi 29273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29274 else 29275 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29276 /* end confdefs.h. */ 29277 $ac_includes_default 29278 int 29279 main () 29280 { 29281 29282 /* Are we little or big endian? From Harbison&Steele. */ 29283 union 29284 { 29285 long int l; 29286 char c[sizeof (long int)]; 29287 } u; 29288 u.l = 1; 29289 return u.c[sizeof (long int) - 1] == 1; 29290 29291 ; 29292 return 0; 29293 } 29294 _ACEOF 29295 if ac_fn_cxx_try_run "$LINENO"; then : 29296 ac_cv_c_bigendian=no 29297 else 29298 ac_cv_c_bigendian=yes 29299 fi 29300 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 29301 conftest.$ac_objext conftest.beam conftest.$ac_ext 29302 fi 29303 29304 fi 29305 fi 29306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 29307 $as_echo "$ac_cv_c_bigendian" >&6; } 29308 case $ac_cv_c_bigendian in #( 29309 yes) 29310 ENDIAN="big";; #( 29311 no) 29312 ENDIAN="little" ;; #( 29313 universal) 29314 ENDIAN="universal_endianness" 29315 ;; #( 29316 *) 29317 ENDIAN="unknown" ;; 29318 esac 29319 29320 29321 if test "x$ENDIAN" = xuniversal_endianness; then 29322 as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5 29323 fi 29324 if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then 29325 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 29326 fi 29327 29328 29329 # Configure flags for the tools 29330 29331 29332 ############################################################################### 29333 # 29334 # How to compile shared libraries. 29335 # 29336 29337 if test "x$GCC" = xyes; then 29338 COMPILER_NAME=gcc 29339 PICFLAG="-fPIC" 29340 LIBRARY_PREFIX=lib 29341 SHARED_LIBRARY='lib$1.so' 29342 STATIC_LIBRARY='lib$1.a' 29343 SHARED_LIBRARY_FLAGS="-shared" 29344 SHARED_LIBRARY_SUFFIX='.so' 29345 STATIC_LIBRARY_SUFFIX='.a' 29346 OBJ_SUFFIX='.o' 29347 EXE_SUFFIX='' 29348 SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1' 29349 SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1' 29350 C_FLAG_REORDER='' 29351 CXX_FLAG_REORDER='' 29352 SET_SHARED_LIBRARY_ORIGIN='-Xlinker -z -Xlinker origin -Xlinker -rpath -Xlinker \$$$$ORIGIN$1' 29353 SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1' 29354 LD="$CC" 29355 LDEXE="$CC" 29356 LDCXX="$CXX" 29357 LDEXECXX="$CXX" 29358 POST_STRIP_CMD="$STRIP -g" 29359 29360 # Linking is different on MacOSX 29361 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 29362 # Might change in the future to clang. 29363 COMPILER_NAME=gcc 29364 SHARED_LIBRARY='lib$1.dylib' 29365 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 29366 SHARED_LIBRARY_SUFFIX='.dylib' 29367 EXE_SUFFIX='' 29368 SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1' 29369 SET_SHARED_LIBRARY_MAPFILE='' 29370 SET_SHARED_LIBRARY_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.' 29371 SET_EXECUTABLE_ORIGIN="$SET_SHARED_LIBRARY_ORIGIN" 29372 POST_STRIP_CMD="$STRIP -S" 29373 fi 29374 else 29375 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29376 # If it is not gcc, then assume it is the Oracle Solaris Studio Compiler 29377 COMPILER_NAME=ossc 29378 PICFLAG="-KPIC" 29379 LIBRARY_PREFIX=lib 29380 SHARED_LIBRARY='lib$1.so' 29381 STATIC_LIBRARY='lib$1.a' 29382 SHARED_LIBRARY_FLAGS="-G" 29383 SHARED_LIBRARY_SUFFIX='.so' 29384 STATIC_LIBRARY_SUFFIX='.a' 29385 OBJ_SUFFIX='.o' 29386 EXE_SUFFIX='' 29387 SET_SHARED_LIBRARY_NAME='' 29388 SET_SHARED_LIBRARY_MAPFILE='-M$1' 29389 C_FLAG_REORDER='-xF' 29390 CXX_FLAG_REORDER='-xF' 29391 SET_SHARED_LIBRARY_ORIGIN='-R\$$$$ORIGIN$1' 29392 SET_EXECUTABLE_ORIGIN="$SET_SHARED_LIBRARY_ORIGIN" 29393 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 29394 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 29395 CFLAGS_JDKLIB_EXTRA='-xstrconst' 29396 POST_STRIP_CMD="$STRIP -x" 29397 POST_MCS_CMD="$MCS -d -a \"JDK $FULL_VERSION\"" 29398 fi 29399 if test "x$OPENJDK_TARGET_OS" = xwindows; then 29400 # If it is not gcc, then assume it is the MS Visual Studio compiler 29401 COMPILER_NAME=cl 29402 PICFLAG="" 29403 LIBRARY_PREFIX= 29404 SHARED_LIBRARY='$1.dll' 29405 STATIC_LIBRARY='$1.lib' 29406 SHARED_LIBRARY_FLAGS="-LD" 29407 SHARED_LIBRARY_SUFFIX='.dll' 29408 STATIC_LIBRARY_SUFFIX='.lib' 29409 OBJ_SUFFIX='.obj' 29410 EXE_SUFFIX='.exe' 29411 SET_SHARED_LIBRARY_NAME='' 29412 SET_SHARED_LIBRARY_MAPFILE='' 29413 SET_SHARED_LIBRARY_ORIGIN='' 29414 SET_EXECUTABLE_ORIGIN='' 29415 fi 29416 fi 29417 29418 29419 29420 29421 29422 29423 29424 29425 29426 29427 29428 29429 29430 29431 29432 29433 29434 29435 # The (cross) compiler is now configured, we can now test capabilities 29436 # of the target platform. 29437 29438 29439 29440 ############################################################################### 29441 # 29442 # Setup the opt flags for different compilers 29443 # and different operating systems. 29444 # 29445 29446 # 29447 # NOTE: check for -mstackrealign needs to be below potential addition of -m32 29448 # 29449 if test "x$OPENJDK_TARGET_CPU_BITS" = x32 && test "x$OPENJDK_TARGET_OS" = xmacosx; then 29450 # On 32-bit MacOSX the OS requires C-entry points to be 16 byte aligned. 29451 # While waiting for a better solution, the current workaround is to use -mstackrealign. 29452 CFLAGS="$CFLAGS -mstackrealign" 29453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if 32-bit compiler supports -mstackrealign" >&5 29454 $as_echo_n "checking if 32-bit compiler supports -mstackrealign... " >&6; } 29455 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29456 /* end confdefs.h. */ 29457 int main() { return 0; } 29458 _ACEOF 29459 if ac_fn_cxx_try_link "$LINENO"; then : 29460 29461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 29462 $as_echo "yes" >&6; } 29463 29464 else 29465 29466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 29467 $as_echo "no" >&6; } 29468 as_fn_error $? "The selected compiler $CXX does not support -mstackrealign! Try to put another compiler in the path." "$LINENO" 5 29469 29470 fi 29471 rm -f core conftest.err conftest.$ac_objext \ 29472 conftest$ac_exeext conftest.$ac_ext 29473 fi 29474 29475 C_FLAG_DEPS="-MMD -MF" 29476 CXX_FLAG_DEPS="-MMD -MF" 29477 29478 case $COMPILER_TYPE in 29479 CC ) 29480 D_FLAG="-g" 29481 case $COMPILER_NAME in 29482 gcc ) 29483 case $OPENJDK_TARGET_OS in 29484 macosx ) 29485 # On MacOSX we optimize for size, something 29486 # we should do for all platforms? 29487 C_O_FLAG_HI="-Os" 29488 C_O_FLAG_NORM="-Os" 29489 C_O_FLAG_NONE="" 29490 ;; 29491 *) 29492 C_O_FLAG_HI="-O3" 29493 C_O_FLAG_NORM="-O2" 29494 C_O_FLAG_NONE="-O0" 29495 CFLAGS_DEBUG_SYMBOLS="-g" 29496 CXXFLAGS_DEBUG_SYMBOLS="-g" 29497 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then 29498 CFLAGS_DEBUG_SYMBOLS="-g1" 29499 CXXFLAGS_DEBUG_SYMBOLS="-g1" 29500 fi 29501 ;; 29502 esac 29503 CXX_O_FLAG_HI="$C_O_FLAG_HI" 29504 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 29505 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 29506 ;; 29507 ossc ) 29508 # 29509 # Forte has different names for this with their C++ compiler... 29510 # 29511 C_FLAG_DEPS="-xMMD -xMF" 29512 CXX_FLAG_DEPS="-xMMD -xMF" 29513 29514 # Extra options used with HIGHEST 29515 # 29516 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be 29517 # done with care, there are some assumptions below that need to 29518 # be understood about the use of pointers, and IEEE behavior. 29519 # 29520 # Use non-standard floating point mode (not IEEE 754) 29521 CC_HIGHEST="$CC_HIGHEST -fns" 29522 # Do some simplification of floating point arithmetic (not IEEE 754) 29523 CC_HIGHEST="$CC_HIGHEST -fsimple" 29524 # Use single precision floating point with 'float' 29525 CC_HIGHEST="$CC_HIGHEST -fsingle" 29526 # Assume memory references via basic pointer types do not alias 29527 # (Source with excessing pointer casting and data access with mixed 29528 # pointer types are not recommended) 29529 CC_HIGHEST="$CC_HIGHEST -xalias_level=basic" 29530 # Use intrinsic or inline versions for math/std functions 29531 # (If you expect perfect errno behavior, do not use this) 29532 CC_HIGHEST="$CC_HIGHEST -xbuiltin=%all" 29533 # Loop data dependency optimizations (need -xO3 or higher) 29534 CC_HIGHEST="$CC_HIGHEST -xdepend" 29535 # Pointer parameters to functions do not overlap 29536 # (Similar to -xalias_level=basic usage, but less obvious sometimes. 29537 # If you pass in multiple pointers to the same data, do not use this) 29538 CC_HIGHEST="$CC_HIGHEST -xrestrict" 29539 # Inline some library routines 29540 # (If you expect perfect errno behavior, do not use this) 29541 CC_HIGHEST="$CC_HIGHEST -xlibmil" 29542 # Use optimized math routines 29543 # (If you expect perfect errno behavior, do not use this) 29544 # Can cause undefined external on Solaris 8 X86 on __sincos, removing for now 29545 #CC_HIGHEST="$CC_HIGHEST -xlibmopt" 29546 29547 if test "x$OPENJDK_TARGET_CPU" = xsparc; then 29548 CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s" 29549 CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s" 29550 fi 29551 29552 case $OPENJDK_TARGET_CPU_ARCH in 29553 x86) 29554 C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xregs=no%frameptr" 29555 C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr" 29556 C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr" 29557 C_O_FLAG_NONE="-xregs=no%frameptr" 29558 CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr" 29559 CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr" 29560 CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr" 29561 CXX_O_FLAG_NONE="-xregs=no%frameptr" 29562 if test "x$OPENJDK_TARGET_CPU" = xx86; then 29563 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium" 29564 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium" 29565 fi 29566 ;; 29567 sparc) 29568 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 29569 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 29570 C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 29571 C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0" 29572 C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0" 29573 C_O_FLAG_NONE="" 29574 CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 29575 CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 29576 CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 29577 CXX_O_FLAG_NONE="" 29578 ;; 29579 esac 29580 29581 CFLAGS_DEBUG_SYMBOLS="-g -xs" 29582 CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs" 29583 esac 29584 ;; 29585 CL ) 29586 D_FLAG= 29587 C_O_FLAG_HIGHEST="-O2" 29588 C_O_FLAG_HI="-O1" 29589 C_O_FLAG_NORM="-O1" 29590 C_O_FLAG_NONE="-Od" 29591 CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST" 29592 CXX_O_FLAG_HI="$C_O_FLAG_HI" 29593 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 29594 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 29595 ;; 29596 esac 29597 29598 if test -z "$C_O_FLAG_HIGHEST"; then 29599 C_O_FLAG_HIGHEST="$C_O_FLAG_HI" 29600 fi 29601 29602 if test -z "$CXX_O_FLAG_HIGHEST"; then 29603 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HI" 29604 fi 29605 29606 29607 29608 29609 29610 29611 29612 29613 29614 29615 29616 29617 29618 29619 if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then 29620 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5 29621 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;} 29622 fi 29623 29624 if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then 29625 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5 29626 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;} 29627 fi 29628 29629 if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then 29630 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5 29631 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;} 29632 fi 29633 29634 29635 # Check whether --with-extra-cflags was given. 29636 if test "${with_extra_cflags+set}" = set; then : 29637 withval=$with_extra_cflags; 29638 fi 29639 29640 29641 29642 # Check whether --with-extra-cxxflags was given. 29643 if test "${with_extra_cxxflags+set}" = set; then : 29644 withval=$with_extra_cxxflags; 29645 fi 29646 29647 29648 29649 # Check whether --with-extra-ldflags was given. 29650 if test "${with_extra_ldflags+set}" = set; then : 29651 withval=$with_extra_ldflags; 29652 fi 29653 29654 29655 CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags" 29656 CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags" 29657 LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags" 29658 29659 # Hotspot needs these set in their legacy form 29660 LEGACY_EXTRA_CFLAGS=$with_extra_cflags 29661 LEGACY_EXTRA_CXXFLAGS=$with_extra_cxxflags 29662 LEGACY_EXTRA_LDFLAGS=$with_extra_ldflags 29663 29664 29665 29666 29667 29668 ############################################################################### 29669 # 29670 # Now setup the CFLAGS and LDFLAGS for the JDK build. 29671 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 29672 # 29673 case $COMPILER_NAME in 29674 gcc ) 29675 CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -W -Wall -Wno-unused -Wno-parentheses \ 29676 -pipe \ 29677 -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 29678 case $OPENJDK_TARGET_CPU_ARCH in 29679 arm ) 29680 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 29681 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 29682 ;; 29683 ppc ) 29684 # on ppc we don't prevent gcc to omit frame pointer nor strict-aliasing 29685 ;; 29686 * ) 29687 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -fno-omit-frame-pointer" 29688 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 29689 ;; 29690 esac 29691 ;; 29692 ossc ) 29693 CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 29694 case $OPENJDK_TARGET_CPU_ARCH in 29695 x86 ) 29696 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 29697 CFLAGS_JDK="$CFLAGS_JDK -erroff=E_BAD_PRAGMA_PACK_VALUE" 29698 ;; 29699 esac 29700 29701 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 29702 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 29703 29704 LDFLAGS_JDK="$LDFLAGS_JDK -z defs -xildoff -ztext" 29705 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib" 29706 ;; 29707 cl ) 29708 CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Zi -MD -Zc:wchar_t- -W3 -wd4800 \ 29709 -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB -DWIN32_LEAN_AND_MEAN \ 29710 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 29711 -DWIN32 -DIAL" 29712 case $OPENJDK_TARGET_CPU in 29713 x86 ) 29714 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_X86_ -Dx86" 29715 ;; 29716 x86_64 ) 29717 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_AMD64_ -Damd64" 29718 ;; 29719 esac 29720 ;; 29721 esac 29722 29723 ############################################################################### 29724 29725 CCXXFLAGS_JDK="$CCXXFLAGS_JDK $ADD_LP64" 29726 29727 # The package path is used only on macosx? 29728 PACKAGE_PATH=/opt/local 29729 29730 29731 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 29732 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 29733 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 29734 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 29735 # Note: -Dmacro is the same as #define macro 1 29736 # -Dmacro= is the same as #define macro 29737 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29738 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 29739 else 29740 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 29741 fi 29742 else 29743 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN" 29744 fi 29745 if test "x$OPENJDK_TARGET_OS" = xlinux; then 29746 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DLINUX" 29747 fi 29748 if test "x$OPENJDK_TARGET_OS" = xwindows; then 29749 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DWINDOWS" 29750 fi 29751 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29752 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DSOLARIS" 29753 fi 29754 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 29755 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMACOSX -D_ALLBSD_SOURCE" 29756 # Setting these parameters makes it an error to link to macosx APIs that are 29757 # newer than the given OS version and makes the linked binaries compatible even 29758 # if built on a newer version of the OS. 29759 # The expected format is X.Y.Z 29760 MACOSX_VERSION_MIN=10.7.0 29761 29762 # The macro takes the version with no dots, ex: 1070 29763 # Let the flags variables get resolved in make for easier override on make 29764 # command line. 29765 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 29766 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 29767 fi 29768 if test "x$OPENJDK_TARGET_OS" = xbsd; then 29769 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DBSD -D_ALLBSD_SOURCE" 29770 fi 29771 if test "x$DEBUG_LEVEL" = xrelease; then 29772 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DNDEBUG" 29773 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29774 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DTRIMMED" 29775 fi 29776 else 29777 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DDEBUG" 29778 fi 29779 29780 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 29781 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DRELEASE='\"$RELEASE\"'" 29782 29783 CCXXFLAGS_JDK="$CCXXFLAGS_JDK \ 29784 -I${JDK_OUTPUTDIR}/include \ 29785 -I${JDK_OUTPUTDIR}/include/$OPENJDK_TARGET_OS \ 29786 -I${JDK_TOPDIR}/src/share/javavm/export \ 29787 -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_API_DIR/javavm/export \ 29788 -I${JDK_TOPDIR}/src/share/native/common \ 29789 -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_API_DIR/native/common" 29790 29791 # The shared libraries are compiled using the picflag. 29792 CFLAGS_JDKLIB="$CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 29793 CXXFLAGS_JDKLIB="$CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA " 29794 29795 # Executable flags 29796 CFLAGS_JDKEXE="$CCXXFLAGS_JDK $CFLAGS_JDK" 29797 CXXFLAGS_JDKEXE="$CCXXFLAGS_JDK $CXXFLAGS_JDK" 29798 29799 # Now this is odd. The JDK native libraries have to link against libjvm.so 29800 # On 32-bit machines there is normally two distinct libjvm.so:s, client and server. 29801 # Which should we link to? Are we lucky enough that the binary api to the libjvm.so library 29802 # is identical for client and server? Yes. Which is picked at runtime (client or server)? 29803 # Neither, since the chosen libjvm.so has already been loaded by the launcher, all the following 29804 # libraries will link to whatever is in memory. Yuck. 29805 # 29806 # Thus we offer the compiler to find libjvm.so first in server then in client. It works. Ugh. 29807 if test "x$COMPILER_NAME" = xcl; then 29808 LDFLAGS_JDK="$LDFLAGS_JDK -nologo -opt:ref -incremental:no" 29809 if test "x$OPENJDK_TARGET_CPU" = xx86; then 29810 LDFLAGS_JDK="$LDFLAGS_JDK -safeseh" 29811 fi 29812 # TODO: make -debug optional "--disable-full-debug-symbols" 29813 LDFLAGS_JDK="$LDFLAGS_JDK -debug" 29814 LDFLAGS_JDKLIB="${LDFLAGS_JDK} -dll -libpath:${JDK_OUTPUTDIR}/lib" 29815 LDFLAGS_JDKLIB_SUFFIX="" 29816 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 29817 LDFLAGS_STACK_SIZE=1048576 29818 else 29819 LDFLAGS_STACK_SIZE=327680 29820 fi 29821 LDFLAGS_JDKEXE="${LDFLAGS_JDK} /STACK:$LDFLAGS_STACK_SIZE" 29822 else 29823 if test "x$COMPILER_NAME" = xgcc; then 29824 # If this is a --hash-style=gnu system, use --hash-style=both, why? 29825 HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'` 29826 if test -n "$HAS_GNU_HASH"; then 29827 LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker --hash-style=both " 29828 fi 29829 if test "x$OPENJDK_TARGET_OS" = xlinux; then 29830 # And since we now know that the linker is gnu, then add -z defs, to forbid 29831 # undefined symbols in object files. 29832 LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -z -Xlinker defs" 29833 if test "x$DEBUG_LEVEL" = "xrelease"; then 29834 # When building release libraries, tell the linker optimize them. 29835 # Should this be supplied to the OSS linker as well? 29836 LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -O1" 29837 fi 29838 fi 29839 fi 29840 LDFLAGS_JDKLIB="${LDFLAGS_JDK} $SHARED_LIBRARY_FLAGS \ 29841 -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}" 29842 29843 # On some platforms (mac) the linker warns about non existing -L dirs. 29844 # Add server first if available. Linking aginst client does not always produce the same results. 29845 # Only add client dir if client is being built. Add minimal (note not minimal1) if only building minimal1. 29846 # Default to server for other variants. 29847 if test "x$JVM_VARIANT_SERVER" = xtrue; then 29848 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server" 29849 elif test "x$JVM_VARIANT_CLIENT" = xtrue; then 29850 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/client" 29851 elif test "x$JVM_VARIANT_MINIMAL1" = xtrue; then 29852 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/minimal" 29853 else 29854 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server" 29855 fi 29856 29857 LDFLAGS_JDKLIB_SUFFIX="-ljava -ljvm" 29858 if test "x$COMPILER_NAME" = xossc; then 29859 LDFLAGS_JDKLIB_SUFFIX="$LDFLAGS_JDKLIB_SUFFIX -lc" 29860 fi 29861 29862 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 29863 if test "x$OPENJDK_TARGET_OS" = xlinux; then 29864 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Xlinker --allow-shlib-undefined" 29865 fi 29866 fi 29867 29868 # Adjust flags according to debug level. 29869 case $DEBUG_LEVEL in 29870 fastdebug ) 29871 CFLAGS="$CFLAGS $D_FLAG" 29872 JAVAC_FLAGS="$JAVAC_FLAGS -g" 29873 ;; 29874 slowdebug ) 29875 CFLAGS="$CFLAGS $D_FLAG" 29876 C_O_FLAG_HI="$C_O_FLAG_NONE" 29877 C_O_FLAG_NORM="$C_O_FLAG_NONE" 29878 CXX_O_FLAG_HI="$CXX_O_FLAG_NONE" 29879 CXX_O_FLAG_NORM="$CXX_O_FLAG_NONE" 29880 JAVAC_FLAGS="$JAVAC_FLAGS -g" 29881 ;; 29882 esac 29883 29884 29885 29886 29887 29888 29889 29890 29891 29892 29893 29894 29895 29896 29897 29898 # Setup debug symbols (need objcopy from the toolchain for that) 29899 29900 # 29901 # ENABLE_DEBUG_SYMBOLS 29902 # This must be done after the toolchain is setup, since we're looking at objcopy. 29903 # 29904 # Check whether --enable-debug-symbols was given. 29905 if test "${enable_debug_symbols+set}" = set; then : 29906 enableval=$enable_debug_symbols; 29907 fi 29908 29909 29910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should generate debug symbols" >&5 29911 $as_echo_n "checking if we should generate debug symbols... " >&6; } 29912 29913 if test "x$enable_debug_symbols" = "xyes" && test "x$OBJCOPY" = x; then 29914 # explicit enabling of enable-debug-symbols and can't find objcopy 29915 # this is an error 29916 as_fn_error $? "Unable to find objcopy, cannot enable debug-symbols" "$LINENO" 5 29917 fi 29918 29919 if test "x$enable_debug_symbols" = "xyes"; then 29920 ENABLE_DEBUG_SYMBOLS=true 29921 elif test "x$enable_debug_symbols" = "xno"; then 29922 ENABLE_DEBUG_SYMBOLS=false 29923 else 29924 # default on macosx is false 29925 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 29926 ENABLE_DEBUG_SYMBOLS=false 29927 # Default is on if objcopy is found, otherwise off 29928 elif test "x$OBJCOPY" != x || test "x$OPENJDK_TARGET_OS" = xwindows; then 29929 ENABLE_DEBUG_SYMBOLS=true 29930 else 29931 ENABLE_DEBUG_SYMBOLS=false 29932 fi 29933 fi 29934 29935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_DEBUG_SYMBOLS" >&5 29936 $as_echo "$ENABLE_DEBUG_SYMBOLS" >&6; } 29937 29938 # 29939 # ZIP_DEBUGINFO_FILES 29940 # 29941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should zip debug-info files" >&5 29942 $as_echo_n "checking if we should zip debug-info files... " >&6; } 29943 # Check whether --enable-zip-debug-info was given. 29944 if test "${enable_zip_debug_info+set}" = set; then : 29945 enableval=$enable_zip_debug_info; enable_zip_debug_info="${enableval}" 29946 else 29947 enable_zip_debug_info="yes" 29948 fi 29949 29950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_zip_debug_info}" >&5 29951 $as_echo "${enable_zip_debug_info}" >&6; } 29952 29953 if test "x${enable_zip_debug_info}" = "xno"; then 29954 ZIP_DEBUGINFO_FILES=false 29955 else 29956 ZIP_DEBUGINFO_FILES=true 29957 fi 29958 29959 29960 29961 29962 29963 29964 29965 ############################################################################### 29966 # 29967 # Check dependencies for external and internal libraries. 29968 # 29969 ############################################################################### 29970 29971 29972 29973 ############################################################################### 29974 # 29975 # OS specific settings that we never will need to probe. 29976 # 29977 if test "x$OPENJDK_TARGET_OS" = xlinux; then 29978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Linux?" >&5 29979 $as_echo_n "checking what is not needed on Linux?... " >&6; } 29980 PULSE_NOT_NEEDED=yes 29981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pulse" >&5 29982 $as_echo "pulse" >&6; } 29983 fi 29984 29985 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Solaris?" >&5 29987 $as_echo_n "checking what is not needed on Solaris?... " >&6; } 29988 ALSA_NOT_NEEDED=yes 29989 PULSE_NOT_NEEDED=yes 29990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5 29991 $as_echo "alsa pulse" >&6; } 29992 fi 29993 29994 if test "x$OPENJDK_TARGET_OS" = xwindows; then 29995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Windows?" >&5 29996 $as_echo_n "checking what is not needed on Windows?... " >&6; } 29997 CUPS_NOT_NEEDED=yes 29998 ALSA_NOT_NEEDED=yes 29999 PULSE_NOT_NEEDED=yes 30000 X11_NOT_NEEDED=yes 30001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa cups pulse x11" >&5 30002 $as_echo "alsa cups pulse x11" >&6; } 30003 fi 30004 30005 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 30006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on MacOSX?" >&5 30007 $as_echo_n "checking what is not needed on MacOSX?... " >&6; } 30008 ALSA_NOT_NEEDED=yes 30009 PULSE_NOT_NEEDED=yes 30010 X11_NOT_NEEDED=yes 30011 FREETYPE2_NOT_NEEDED=yes 30012 # If the java runtime framework is disabled, then we need X11. 30013 # This will be adjusted below. 30014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse x11" >&5 30015 $as_echo "alsa pulse x11" >&6; } 30016 fi 30017 30018 if test "x$OPENJDK_TARGET_OS" = xbsd; then 30019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on bsd?" >&5 30020 $as_echo_n "checking what is not needed on bsd?... " >&6; } 30021 ALSA_NOT_NEEDED=yes 30022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa" >&5 30023 $as_echo "alsa" >&6; } 30024 fi 30025 30026 if test "x$OPENJDK" = "xfalse"; then 30027 FREETYPE2_NOT_NEEDED=yes 30028 fi 30029 30030 if test "x$SUPPORT_HEADFUL" = xno; then 30031 X11_NOT_NEEDED=yes 30032 fi 30033 30034 ############################################################################### 30035 # 30036 # Check for MacOSX support for OpenJDK. If this exists, try to build a JVM 30037 # that uses this API. 30038 # 30039 # Check whether --enable-macosx-runtime-support was given. 30040 if test "${enable_macosx_runtime_support+set}" = set; then : 30041 enableval=$enable_macosx_runtime_support; MACOSX_RUNTIME_SUPPORT="${enableval}" 30042 else 30043 MACOSX_RUNTIME_SUPPORT="no" 30044 fi 30045 30046 30047 USE_MACOSX_RUNTIME_SUPPORT=no 30048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for explicit Java runtime support in the OS" >&5 30049 $as_echo_n "checking for explicit Java runtime support in the OS... " >&6; } 30050 if test -f /System/Library/Frameworks/JavaVM.framework/Frameworks/JavaRuntimeSupport.framework/Headers/JavaRuntimeSupport.h; then 30051 if test "x$MACOSX_RUNTIME_SUPPORT" != xno; then 30052 MACOSX_RUNTIME_SUPPORT=yes 30053 USE_MACOSX_RUNTIME_SUPPORT=yes 30054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, does not need alsa freetype2 pulse and X11" >&5 30055 $as_echo "yes, does not need alsa freetype2 pulse and X11" >&6; } 30056 else 30057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, but explicitly disabled." >&5 30058 $as_echo "yes, but explicitly disabled." >&6; } 30059 fi 30060 else 30061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30062 $as_echo "no" >&6; } 30063 fi 30064 30065 if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$USE_MACOSX_RUNTIME_SUPPORT" = xno; then 30066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on an X11 build on MacOSX?" >&5 30067 $as_echo_n "checking what is not needed on an X11 build on MacOSX?... " >&6; } 30068 X11_NOT_NEEDED= 30069 FREETYPE2_NOT_NEEDED= 30070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5 30071 $as_echo "alsa pulse" >&6; } 30072 fi 30073 30074 30075 30076 ############################################################################### 30077 # 30078 # Check for X Windows 30079 # 30080 30081 # Check if the user has specified sysroot, but not --x-includes or --x-libraries. 30082 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 30083 # --x-libraries for the sysroot, if that seems to be correct. 30084 if test "x$SYS_ROOT" != "x/"; then 30085 if test "x$x_includes" = xNONE; then 30086 if test -f "$SYS_ROOT/usr/X11R6/include/X11/Xlib.h"; then 30087 x_includes="$SYS_ROOT/usr/X11R6/include" 30088 fi 30089 fi 30090 if test "x$x_libraries" = xNONE; then 30091 if test -f "$SYS_ROOT/usr/X11R6/lib/libX11.so"; then 30092 x_libraries="$SYS_ROOT/usr/X11R6/lib" 30093 fi 30094 fi 30095 fi 30096 30097 # Now let autoconf do it's magic 30098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 30099 $as_echo_n "checking for X... " >&6; } 30100 30101 30102 # Check whether --with-x was given. 30103 if test "${with_x+set}" = set; then : 30104 withval=$with_x; 30105 fi 30106 30107 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 30108 if test "x$with_x" = xno; then 30109 # The user explicitly disabled X. 30110 have_x=disabled 30111 else 30112 case $x_includes,$x_libraries in #( 30113 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 30114 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 30115 $as_echo_n "(cached) " >&6 30116 else 30117 # One or both of the vars are not set, and there is no cached value. 30118 ac_x_includes=no ac_x_libraries=no 30119 rm -f -r conftest.dir 30120 if mkdir conftest.dir; then 30121 cd conftest.dir 30122 cat >Imakefile <<'_ACEOF' 30123 incroot: 30124 @echo incroot='${INCROOT}' 30125 usrlibdir: 30126 @echo usrlibdir='${USRLIBDIR}' 30127 libdir: 30128 @echo libdir='${LIBDIR}' 30129 _ACEOF 30130 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 30131 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 30132 for ac_var in incroot usrlibdir libdir; do 30133 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 30134 done 30135 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 30136 for ac_extension in a so sl dylib la dll; do 30137 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 30138 test -f "$ac_im_libdir/libX11.$ac_extension"; then 30139 ac_im_usrlibdir=$ac_im_libdir; break 30140 fi 30141 done 30142 # Screen out bogus values from the imake configuration. They are 30143 # bogus both because they are the default anyway, and because 30144 # using them would break gcc on systems where it needs fixed includes. 30145 case $ac_im_incroot in 30146 /usr/include) ac_x_includes= ;; 30147 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 30148 esac 30149 case $ac_im_usrlibdir in 30150 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 30151 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 30152 esac 30153 fi 30154 cd .. 30155 rm -f -r conftest.dir 30156 fi 30157 30158 # Standard set of common directories for X headers. 30159 # Check X11 before X11Rn because it is often a symlink to the current release. 30160 ac_x_header_dirs=' 30161 /usr/X11/include 30162 /usr/X11R7/include 30163 /usr/X11R6/include 30164 /usr/X11R5/include 30165 /usr/X11R4/include 30166 30167 /usr/include/X11 30168 /usr/include/X11R7 30169 /usr/include/X11R6 30170 /usr/include/X11R5 30171 /usr/include/X11R4 30172 30173 /usr/local/X11/include 30174 /usr/local/X11R7/include 30175 /usr/local/X11R6/include 30176 /usr/local/X11R5/include 30177 /usr/local/X11R4/include 30178 30179 /usr/local/include/X11 30180 /usr/local/include/X11R7 30181 /usr/local/include/X11R6 30182 /usr/local/include/X11R5 30183 /usr/local/include/X11R4 30184 30185 /usr/X386/include 30186 /usr/x386/include 30187 /usr/XFree86/include/X11 30188 30189 /usr/include 30190 /usr/local/include 30191 /usr/unsupported/include 30192 /usr/athena/include 30193 /usr/local/x11r5/include 30194 /usr/lpp/Xamples/include 30195 30196 /usr/openwin/include 30197 /usr/openwin/share/include' 30198 30199 if test "$ac_x_includes" = no; then 30200 # Guess where to find include files, by looking for Xlib.h. 30201 # First, try using that file with no special directory specified. 30202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30203 /* end confdefs.h. */ 30204 #include <X11/Xlib.h> 30205 _ACEOF 30206 if ac_fn_cxx_try_cpp "$LINENO"; then : 30207 # We can compile using X headers with no special include directory. 30208 ac_x_includes= 30209 else 30210 for ac_dir in $ac_x_header_dirs; do 30211 if test -r "$ac_dir/X11/Xlib.h"; then 30212 ac_x_includes=$ac_dir 30213 break 30214 fi 30215 done 30216 fi 30217 rm -f conftest.err conftest.i conftest.$ac_ext 30218 fi # $ac_x_includes = no 30219 30220 if test "$ac_x_libraries" = no; then 30221 # Check for the libraries. 30222 # See if we find them without any special options. 30223 # Don't add to $LIBS permanently. 30224 ac_save_LIBS=$LIBS 30225 LIBS="-lX11 $LIBS" 30226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30227 /* end confdefs.h. */ 30228 #include <X11/Xlib.h> 30229 int 30230 main () 30231 { 30232 XrmInitialize () 30233 ; 30234 return 0; 30235 } 30236 _ACEOF 30237 if ac_fn_cxx_try_link "$LINENO"; then : 30238 LIBS=$ac_save_LIBS 30239 # We can link X programs with no special library path. 30240 ac_x_libraries= 30241 else 30242 LIBS=$ac_save_LIBS 30243 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 30244 do 30245 # Don't even attempt the hair of trying to link an X program! 30246 for ac_extension in a so sl dylib la dll; do 30247 if test -r "$ac_dir/libX11.$ac_extension"; then 30248 ac_x_libraries=$ac_dir 30249 break 2 30250 fi 30251 done 30252 done 30253 fi 30254 rm -f core conftest.err conftest.$ac_objext \ 30255 conftest$ac_exeext conftest.$ac_ext 30256 fi # $ac_x_libraries = no 30257 30258 case $ac_x_includes,$ac_x_libraries in #( 30259 no,* | *,no | *\'*) 30260 # Didn't find X, or a directory has "'" in its name. 30261 ac_cv_have_x="have_x=no";; #( 30262 *) 30263 # Record where we found X for the cache. 30264 ac_cv_have_x="have_x=yes\ 30265 ac_x_includes='$ac_x_includes'\ 30266 ac_x_libraries='$ac_x_libraries'" 30267 esac 30268 fi 30269 ;; #( 30270 *) have_x=yes;; 30271 esac 30272 eval "$ac_cv_have_x" 30273 fi # $with_x != no 30274 30275 if test "$have_x" != yes; then 30276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 30277 $as_echo "$have_x" >&6; } 30278 no_x=yes 30279 else 30280 # If each of the values was on the command line, it overrides each guess. 30281 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 30282 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 30283 # Update the cache value to reflect the command line values. 30284 ac_cv_have_x="have_x=yes\ 30285 ac_x_includes='$x_includes'\ 30286 ac_x_libraries='$x_libraries'" 30287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 30288 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 30289 fi 30290 30291 if test "$no_x" = yes; then 30292 # Not all programs may use this symbol, but it does not hurt to define it. 30293 30294 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 30295 30296 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 30297 else 30298 if test -n "$x_includes"; then 30299 X_CFLAGS="$X_CFLAGS -I$x_includes" 30300 fi 30301 30302 # It would also be nice to do this for all -L options, not just this one. 30303 if test -n "$x_libraries"; then 30304 X_LIBS="$X_LIBS -L$x_libraries" 30305 # For Solaris; some versions of Sun CC require a space after -R and 30306 # others require no space. Words are not sufficient . . . . 30307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 30308 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 30309 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 30310 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 30311 ac_cxx_werror_flag=yes 30312 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30313 /* end confdefs.h. */ 30314 30315 int 30316 main () 30317 { 30318 30319 ; 30320 return 0; 30321 } 30322 _ACEOF 30323 if ac_fn_cxx_try_link "$LINENO"; then : 30324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30325 $as_echo "no" >&6; } 30326 X_LIBS="$X_LIBS -R$x_libraries" 30327 else 30328 LIBS="$ac_xsave_LIBS -R $x_libraries" 30329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30330 /* end confdefs.h. */ 30331 30332 int 30333 main () 30334 { 30335 30336 ; 30337 return 0; 30338 } 30339 _ACEOF 30340 if ac_fn_cxx_try_link "$LINENO"; then : 30341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 30342 $as_echo "yes" >&6; } 30343 X_LIBS="$X_LIBS -R $x_libraries" 30344 else 30345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 30346 $as_echo "neither works" >&6; } 30347 fi 30348 rm -f core conftest.err conftest.$ac_objext \ 30349 conftest$ac_exeext conftest.$ac_ext 30350 fi 30351 rm -f core conftest.err conftest.$ac_objext \ 30352 conftest$ac_exeext conftest.$ac_ext 30353 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 30354 LIBS=$ac_xsave_LIBS 30355 fi 30356 30357 # Check for system-dependent libraries X programs must link with. 30358 # Do this before checking for the system-independent R6 libraries 30359 # (-lICE), since we may need -lsocket or whatever for X linking. 30360 30361 if test "$ISC" = yes; then 30362 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 30363 else 30364 # Martyn Johnson says this is needed for Ultrix, if the X 30365 # libraries were built with DECnet support. And Karl Berry says 30366 # the Alpha needs dnet_stub (dnet does not exist). 30367 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 30368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30369 /* end confdefs.h. */ 30370 30371 /* Override any GCC internal prototype to avoid an error. 30372 Use char because int might match the return type of a GCC 30373 builtin and then its argument prototype would still apply. */ 30374 #ifdef __cplusplus 30375 extern "C" 30376 #endif 30377 char XOpenDisplay (); 30378 int 30379 main () 30380 { 30381 return XOpenDisplay (); 30382 ; 30383 return 0; 30384 } 30385 _ACEOF 30386 if ac_fn_cxx_try_link "$LINENO"; then : 30387 30388 else 30389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 30390 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 30391 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 30392 $as_echo_n "(cached) " >&6 30393 else 30394 ac_check_lib_save_LIBS=$LIBS 30395 LIBS="-ldnet $LIBS" 30396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30397 /* end confdefs.h. */ 30398 30399 /* Override any GCC internal prototype to avoid an error. 30400 Use char because int might match the return type of a GCC 30401 builtin and then its argument prototype would still apply. */ 30402 #ifdef __cplusplus 30403 extern "C" 30404 #endif 30405 char dnet_ntoa (); 30406 int 30407 main () 30408 { 30409 return dnet_ntoa (); 30410 ; 30411 return 0; 30412 } 30413 _ACEOF 30414 if ac_fn_cxx_try_link "$LINENO"; then : 30415 ac_cv_lib_dnet_dnet_ntoa=yes 30416 else 30417 ac_cv_lib_dnet_dnet_ntoa=no 30418 fi 30419 rm -f core conftest.err conftest.$ac_objext \ 30420 conftest$ac_exeext conftest.$ac_ext 30421 LIBS=$ac_check_lib_save_LIBS 30422 fi 30423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 30424 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 30425 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 30426 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 30427 fi 30428 30429 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 30430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 30431 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 30432 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 30433 $as_echo_n "(cached) " >&6 30434 else 30435 ac_check_lib_save_LIBS=$LIBS 30436 LIBS="-ldnet_stub $LIBS" 30437 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30438 /* end confdefs.h. */ 30439 30440 /* Override any GCC internal prototype to avoid an error. 30441 Use char because int might match the return type of a GCC 30442 builtin and then its argument prototype would still apply. */ 30443 #ifdef __cplusplus 30444 extern "C" 30445 #endif 30446 char dnet_ntoa (); 30447 int 30448 main () 30449 { 30450 return dnet_ntoa (); 30451 ; 30452 return 0; 30453 } 30454 _ACEOF 30455 if ac_fn_cxx_try_link "$LINENO"; then : 30456 ac_cv_lib_dnet_stub_dnet_ntoa=yes 30457 else 30458 ac_cv_lib_dnet_stub_dnet_ntoa=no 30459 fi 30460 rm -f core conftest.err conftest.$ac_objext \ 30461 conftest$ac_exeext conftest.$ac_ext 30462 LIBS=$ac_check_lib_save_LIBS 30463 fi 30464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 30465 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 30466 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 30467 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 30468 fi 30469 30470 fi 30471 fi 30472 rm -f core conftest.err conftest.$ac_objext \ 30473 conftest$ac_exeext conftest.$ac_ext 30474 LIBS="$ac_xsave_LIBS" 30475 30476 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 30477 # to get the SysV transport functions. 30478 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 30479 # needs -lnsl. 30480 # The nsl library prevents programs from opening the X display 30481 # on Irix 5.2, according to T.E. Dickey. 30482 # The functions gethostbyname, getservbyname, and inet_addr are 30483 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 30484 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 30485 if test "x$ac_cv_func_gethostbyname" = xyes; then : 30486 30487 fi 30488 30489 if test $ac_cv_func_gethostbyname = no; then 30490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 30491 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 30492 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 30493 $as_echo_n "(cached) " >&6 30494 else 30495 ac_check_lib_save_LIBS=$LIBS 30496 LIBS="-lnsl $LIBS" 30497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30498 /* end confdefs.h. */ 30499 30500 /* Override any GCC internal prototype to avoid an error. 30501 Use char because int might match the return type of a GCC 30502 builtin and then its argument prototype would still apply. */ 30503 #ifdef __cplusplus 30504 extern "C" 30505 #endif 30506 char gethostbyname (); 30507 int 30508 main () 30509 { 30510 return gethostbyname (); 30511 ; 30512 return 0; 30513 } 30514 _ACEOF 30515 if ac_fn_cxx_try_link "$LINENO"; then : 30516 ac_cv_lib_nsl_gethostbyname=yes 30517 else 30518 ac_cv_lib_nsl_gethostbyname=no 30519 fi 30520 rm -f core conftest.err conftest.$ac_objext \ 30521 conftest$ac_exeext conftest.$ac_ext 30522 LIBS=$ac_check_lib_save_LIBS 30523 fi 30524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 30525 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 30526 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 30527 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 30528 fi 30529 30530 if test $ac_cv_lib_nsl_gethostbyname = no; then 30531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 30532 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 30533 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 30534 $as_echo_n "(cached) " >&6 30535 else 30536 ac_check_lib_save_LIBS=$LIBS 30537 LIBS="-lbsd $LIBS" 30538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30539 /* end confdefs.h. */ 30540 30541 /* Override any GCC internal prototype to avoid an error. 30542 Use char because int might match the return type of a GCC 30543 builtin and then its argument prototype would still apply. */ 30544 #ifdef __cplusplus 30545 extern "C" 30546 #endif 30547 char gethostbyname (); 30548 int 30549 main () 30550 { 30551 return gethostbyname (); 30552 ; 30553 return 0; 30554 } 30555 _ACEOF 30556 if ac_fn_cxx_try_link "$LINENO"; then : 30557 ac_cv_lib_bsd_gethostbyname=yes 30558 else 30559 ac_cv_lib_bsd_gethostbyname=no 30560 fi 30561 rm -f core conftest.err conftest.$ac_objext \ 30562 conftest$ac_exeext conftest.$ac_ext 30563 LIBS=$ac_check_lib_save_LIBS 30564 fi 30565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 30566 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 30567 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 30568 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 30569 fi 30570 30571 fi 30572 fi 30573 30574 # lieder@skyler.mavd.honeywell.com says without -lsocket, 30575 # socket/setsockopt and other routines are undefined under SCO ODT 30576 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 30577 # on later versions), says Simon Leinen: it contains gethostby* 30578 # variants that don't use the name server (or something). -lsocket 30579 # must be given before -lnsl if both are needed. We assume that 30580 # if connect needs -lnsl, so does gethostbyname. 30581 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 30582 if test "x$ac_cv_func_connect" = xyes; then : 30583 30584 fi 30585 30586 if test $ac_cv_func_connect = no; then 30587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 30588 $as_echo_n "checking for connect in -lsocket... " >&6; } 30589 if ${ac_cv_lib_socket_connect+:} false; then : 30590 $as_echo_n "(cached) " >&6 30591 else 30592 ac_check_lib_save_LIBS=$LIBS 30593 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 30594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30595 /* end confdefs.h. */ 30596 30597 /* Override any GCC internal prototype to avoid an error. 30598 Use char because int might match the return type of a GCC 30599 builtin and then its argument prototype would still apply. */ 30600 #ifdef __cplusplus 30601 extern "C" 30602 #endif 30603 char connect (); 30604 int 30605 main () 30606 { 30607 return connect (); 30608 ; 30609 return 0; 30610 } 30611 _ACEOF 30612 if ac_fn_cxx_try_link "$LINENO"; then : 30613 ac_cv_lib_socket_connect=yes 30614 else 30615 ac_cv_lib_socket_connect=no 30616 fi 30617 rm -f core conftest.err conftest.$ac_objext \ 30618 conftest$ac_exeext conftest.$ac_ext 30619 LIBS=$ac_check_lib_save_LIBS 30620 fi 30621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 30622 $as_echo "$ac_cv_lib_socket_connect" >&6; } 30623 if test "x$ac_cv_lib_socket_connect" = xyes; then : 30624 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 30625 fi 30626 30627 fi 30628 30629 # Guillermo Gomez says -lposix is necessary on A/UX. 30630 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 30631 if test "x$ac_cv_func_remove" = xyes; then : 30632 30633 fi 30634 30635 if test $ac_cv_func_remove = no; then 30636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 30637 $as_echo_n "checking for remove in -lposix... " >&6; } 30638 if ${ac_cv_lib_posix_remove+:} false; then : 30639 $as_echo_n "(cached) " >&6 30640 else 30641 ac_check_lib_save_LIBS=$LIBS 30642 LIBS="-lposix $LIBS" 30643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30644 /* end confdefs.h. */ 30645 30646 /* Override any GCC internal prototype to avoid an error. 30647 Use char because int might match the return type of a GCC 30648 builtin and then its argument prototype would still apply. */ 30649 #ifdef __cplusplus 30650 extern "C" 30651 #endif 30652 char remove (); 30653 int 30654 main () 30655 { 30656 return remove (); 30657 ; 30658 return 0; 30659 } 30660 _ACEOF 30661 if ac_fn_cxx_try_link "$LINENO"; then : 30662 ac_cv_lib_posix_remove=yes 30663 else 30664 ac_cv_lib_posix_remove=no 30665 fi 30666 rm -f core conftest.err conftest.$ac_objext \ 30667 conftest$ac_exeext conftest.$ac_ext 30668 LIBS=$ac_check_lib_save_LIBS 30669 fi 30670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 30671 $as_echo "$ac_cv_lib_posix_remove" >&6; } 30672 if test "x$ac_cv_lib_posix_remove" = xyes; then : 30673 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 30674 fi 30675 30676 fi 30677 30678 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 30679 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 30680 if test "x$ac_cv_func_shmat" = xyes; then : 30681 30682 fi 30683 30684 if test $ac_cv_func_shmat = no; then 30685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 30686 $as_echo_n "checking for shmat in -lipc... " >&6; } 30687 if ${ac_cv_lib_ipc_shmat+:} false; then : 30688 $as_echo_n "(cached) " >&6 30689 else 30690 ac_check_lib_save_LIBS=$LIBS 30691 LIBS="-lipc $LIBS" 30692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30693 /* end confdefs.h. */ 30694 30695 /* Override any GCC internal prototype to avoid an error. 30696 Use char because int might match the return type of a GCC 30697 builtin and then its argument prototype would still apply. */ 30698 #ifdef __cplusplus 30699 extern "C" 30700 #endif 30701 char shmat (); 30702 int 30703 main () 30704 { 30705 return shmat (); 30706 ; 30707 return 0; 30708 } 30709 _ACEOF 30710 if ac_fn_cxx_try_link "$LINENO"; then : 30711 ac_cv_lib_ipc_shmat=yes 30712 else 30713 ac_cv_lib_ipc_shmat=no 30714 fi 30715 rm -f core conftest.err conftest.$ac_objext \ 30716 conftest$ac_exeext conftest.$ac_ext 30717 LIBS=$ac_check_lib_save_LIBS 30718 fi 30719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 30720 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 30721 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 30722 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 30723 fi 30724 30725 fi 30726 fi 30727 30728 # Check for libraries that X11R6 Xt/Xaw programs need. 30729 ac_save_LDFLAGS=$LDFLAGS 30730 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 30731 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 30732 # check for ICE first), but we must link in the order -lSM -lICE or 30733 # we get undefined symbols. So assume we have SM if we have ICE. 30734 # These have to be linked with before -lX11, unlike the other 30735 # libraries we check for below, so use a different variable. 30736 # John Interrante, Karl Berry 30737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 30738 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 30739 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 30740 $as_echo_n "(cached) " >&6 30741 else 30742 ac_check_lib_save_LIBS=$LIBS 30743 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 30744 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30745 /* end confdefs.h. */ 30746 30747 /* Override any GCC internal prototype to avoid an error. 30748 Use char because int might match the return type of a GCC 30749 builtin and then its argument prototype would still apply. */ 30750 #ifdef __cplusplus 30751 extern "C" 30752 #endif 30753 char IceConnectionNumber (); 30754 int 30755 main () 30756 { 30757 return IceConnectionNumber (); 30758 ; 30759 return 0; 30760 } 30761 _ACEOF 30762 if ac_fn_cxx_try_link "$LINENO"; then : 30763 ac_cv_lib_ICE_IceConnectionNumber=yes 30764 else 30765 ac_cv_lib_ICE_IceConnectionNumber=no 30766 fi 30767 rm -f core conftest.err conftest.$ac_objext \ 30768 conftest$ac_exeext conftest.$ac_ext 30769 LIBS=$ac_check_lib_save_LIBS 30770 fi 30771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 30772 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 30773 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 30774 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 30775 fi 30776 30777 LDFLAGS=$ac_save_LDFLAGS 30778 30779 fi 30780 30781 30782 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 30783 # this doesn't make sense so we remove it. 30784 if test "x$COMPILE_TYPE" = xcross; then 30785 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 30786 fi 30787 30788 if test "x$no_x" = xyes && test "x$X11_NOT_NEEDED" != xyes; then 30789 30790 # Print a helpful message on how to acquire the necessary build dependency. 30791 # x11 is the help tag: freetyp2, cups, pulse, alsa etc 30792 MISSING_DEPENDENCY=x11 30793 PKGHANDLER_COMMAND= 30794 30795 case $PKGHANDLER in 30796 apt-get) 30797 apt_help $MISSING_DEPENDENCY ;; 30798 yum) 30799 yum_help $MISSING_DEPENDENCY ;; 30800 port) 30801 port_help $MISSING_DEPENDENCY ;; 30802 pkgutil) 30803 pkgutil_help $MISSING_DEPENDENCY ;; 30804 pkgadd) 30805 pkgadd_help $MISSING_DEPENDENCY ;; 30806 * ) 30807 break ;; 30808 esac 30809 30810 if test "x$PKGHANDLER_COMMAND" != x; then 30811 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 30812 fi 30813 30814 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 30815 fi 30816 30817 # Some of the old makefiles require a setting of OPENWIN_HOME 30818 # Since the X11R6 directory has disappeared on later Linuxes, 30819 # we need to probe for it. 30820 if test "x$OPENJDK_TARGET_OS" = xlinux; then 30821 if test -d "$SYS_ROOT/usr/X11R6"; then 30822 OPENWIN_HOME="$SYS_ROOT/usr/X11R6" 30823 fi 30824 if test -d "$SYS_ROOT/usr/include/X11"; then 30825 OPENWIN_HOME="$SYS_ROOT/usr" 30826 fi 30827 fi 30828 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 30829 OPENWIN_HOME="/usr/openwin" 30830 fi 30831 30832 30833 30834 # 30835 # Weird Sol10 something check...TODO change to try compile 30836 # 30837 if test "x${OPENJDK_TARGET_OS}" = xsolaris; then 30838 if test "`uname -r`" = "5.10"; then 30839 if test "`${EGREP} -c XLinearGradient ${OPENWIN_HOME}/share/include/X11/extensions/Xrender.h`" = "0"; then 30840 X_CFLAGS="${X_CFLAGS} -DSOLARIS10_NO_XRENDER_STRUCTS" 30841 fi 30842 fi 30843 fi 30844 30845 ac_ext=c 30846 ac_cpp='$CPP $CPPFLAGS' 30847 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 30848 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 30849 ac_compiler_gnu=$ac_cv_c_compiler_gnu 30850 30851 OLD_CFLAGS="$CFLAGS" 30852 CFLAGS="$CFLAGS $X_CFLAGS" 30853 30854 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 30855 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h 30856 do : 30857 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 30858 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " # include <X11/Xlib.h> 30859 # include <X11/Xutil.h> 30860 30861 " 30862 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 30863 cat >>confdefs.h <<_ACEOF 30864 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 30865 _ACEOF 30866 X11_A_OK=yes 30867 else 30868 X11_A_OK=no; break 30869 fi 30870 30871 done 30872 30873 30874 CFLAGS="$OLD_CFLAGS" 30875 ac_ext=cpp 30876 ac_cpp='$CXXCPP $CPPFLAGS' 30877 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 30878 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 30879 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 30880 30881 30882 if test "x$X11_A_OK" = xno && test "x$X11_NOT_NEEDED" != xyes; then 30883 30884 # Print a helpful message on how to acquire the necessary build dependency. 30885 # x11 is the help tag: freetyp2, cups, pulse, alsa etc 30886 MISSING_DEPENDENCY=x11 30887 PKGHANDLER_COMMAND= 30888 30889 case $PKGHANDLER in 30890 apt-get) 30891 apt_help $MISSING_DEPENDENCY ;; 30892 yum) 30893 yum_help $MISSING_DEPENDENCY ;; 30894 port) 30895 port_help $MISSING_DEPENDENCY ;; 30896 pkgutil) 30897 pkgutil_help $MISSING_DEPENDENCY ;; 30898 pkgadd) 30899 pkgadd_help $MISSING_DEPENDENCY ;; 30900 * ) 30901 break ;; 30902 esac 30903 30904 if test "x$PKGHANDLER_COMMAND" != x; then 30905 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 30906 fi 30907 30908 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h). $HELP_MSG" "$LINENO" 5 30909 fi 30910 30911 30912 30913 30914 30915 30916 ############################################################################### 30917 # 30918 # The common unix printing system cups is used to print from java. 30919 # 30920 30921 # Check whether --with-cups was given. 30922 if test "${with_cups+set}" = set; then : 30923 withval=$with_cups; 30924 fi 30925 30926 30927 # Check whether --with-cups-include was given. 30928 if test "${with_cups_include+set}" = set; then : 30929 withval=$with_cups_include; 30930 fi 30931 30932 30933 if test "x$CUPS_NOT_NEEDED" = xyes; then 30934 if test "x${with_cups}" != x || test "x${with_cups_include}" != x; then 30935 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups is ignored" >&5 30936 $as_echo "$as_me: WARNING: cups not used, so --with-cups is ignored" >&2;} 30937 fi 30938 CUPS_CFLAGS= 30939 else 30940 CUPS_FOUND=no 30941 30942 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 30943 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 30944 fi 30945 30946 if test "x${with_cups}" != x; then 30947 CUPS_CFLAGS="-I${with_cups}/include" 30948 CUPS_FOUND=yes 30949 fi 30950 if test "x${with_cups_include}" != x; then 30951 CUPS_CFLAGS="-I${with_cups_include}" 30952 CUPS_FOUND=yes 30953 fi 30954 if test "x$CUPS_FOUND" = xno; then 30955 30956 30957 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 30958 # Source the builddeps file again, to make sure it uses the latest variables! 30959 . $builddepsfile 30960 # Look for a target and build machine specific resource! 30961 eval resource=\${builddep_cups_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}} 30962 if test "x$resource" = x; then 30963 # Ok, lets instead look for a target specific resource 30964 eval resource=\${builddep_cups_TARGET_${rewritten_target_var}} 30965 fi 30966 if test "x$resource" = x; then 30967 # Ok, lets instead look for a build specific resource 30968 eval resource=\${builddep_cups_BUILD_${rewritten_build_var}} 30969 fi 30970 if test "x$resource" = x; then 30971 # Ok, lets instead look for a generic resource 30972 # (The cups comes from M4 and not the shell, thus no need for eval here.) 30973 resource=${builddep_cups} 30974 fi 30975 if test "x$resource" != x; then 30976 { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for cups" >&5 30977 $as_echo "$as_me: Using builddeps $resource for cups" >&6;} 30978 # If the resource in the builddeps.conf file is an existing directory, 30979 # for example /java/linux/cups 30980 if test -d ${resource}; then 30981 depdir=${resource} 30982 else 30983 30984 # cups is for example mymodule 30985 # $resource is for example libs/general/libmymod_1_2_3.zip 30986 # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps 30987 # $with_builddeps_dir is for example /localhome/builddeps 30988 # depdir is the name of the variable into which we store the depdir, eg MYMOD 30989 # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and 30990 # unzip into the directory: /localhome/builddeps/libmymod_1_2_3 30991 filename=`basename $resource` 30992 filebase=`echo $filename | sed 's/\.[^\.]*$//'` 30993 filebase=${filename%%.*} 30994 extension=${filename#*.} 30995 installdir=$with_builddeps_dir/$filebase 30996 if test ! -f $installdir/$filename.unpacked; then 30997 { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&5 30998 $as_echo "$as_me: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&6;} 30999 if test ! -d $installdir; then 31000 mkdir -p $installdir 31001 fi 31002 if test ! -d $installdir; then 31003 as_fn_error $? "Could not create directory $installdir" "$LINENO" 5 31004 fi 31005 tmpfile=`mktemp $installdir/cups.XXXXXXXXX` 31006 touch $tmpfile 31007 if test ! -f $tmpfile; then 31008 as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5 31009 fi 31010 31011 # $with_builddeps_server/$resource is the ftp://abuilddeps.server.com/libs/cups.zip 31012 # $tmpfile is the local file name for the downloaded file. 31013 VALID_TOOL=no 31014 if test "x$BDEPS_FTP" = xwget; then 31015 VALID_TOOL=yes 31016 wget -O $tmpfile $with_builddeps_server/$resource 31017 fi 31018 if test "x$BDEPS_FTP" = xlftp; then 31019 VALID_TOOL=yes 31020 lftp -c "get $with_builddeps_server/$resource -o $tmpfile" 31021 fi 31022 if test "x$BDEPS_FTP" = xftp; then 31023 VALID_TOOL=yes 31024 FTPSERVER=`echo $with_builddeps_server/$resource | cut -f 3 -d '/'` 31025 FTPPATH=`echo $with_builddeps_server/$resource | cut -f 4- -d '/'` 31026 FTPUSERPWD=${FTPSERVER%%@*} 31027 if test "x$FTPSERVER" != "x$FTPUSERPWD"; then 31028 FTPUSER=${userpwd%%:*} 31029 FTPPWD=${userpwd#*@} 31030 FTPSERVER=${FTPSERVER#*@} 31031 else 31032 FTPUSER=ftp 31033 FTPPWD=ftp 31034 fi 31035 # the "pass" command does not work on some 31036 # ftp clients (read ftp.exe) but if it works, 31037 # passive mode is better! 31038 (\ 31039 echo "user $FTPUSER $FTPPWD" ;\ 31040 echo "pass" ;\ 31041 echo "bin" ;\ 31042 echo "get $FTPPATH $tmpfile" ;\ 31043 ) | ftp -in $FTPSERVER 31044 fi 31045 if test "x$VALID_TOOL" != xyes; then 31046 as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5 31047 fi 31048 31049 mv $tmpfile $installdir/$filename 31050 if test ! -s $installdir/$filename; then 31051 as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5 31052 fi 31053 case "$extension" in 31054 zip) echo "Unzipping $installdir/$filename..." 31055 (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked) 31056 ;; 31057 tar.gz) echo "Untaring $installdir/$filename..." 31058 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31059 ;; 31060 tgz) echo "Untaring $installdir/$filename..." 31061 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31062 ;; 31063 *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5 31064 ;; 31065 esac 31066 fi 31067 if test -f $installdir/$filename.unpacked; then 31068 depdir=$installdir 31069 fi 31070 31071 fi 31072 # Source the builddeps file again, because in the previous command, the depdir 31073 # was updated to point at the current build dependency install directory. 31074 . $builddepsfile 31075 # Now extract variables from the builddeps.conf files. 31076 theroot=${builddep_cups_ROOT} 31077 thecflags=${builddep_cups_CFLAGS} 31078 thelibs=${builddep_cups_LIBS} 31079 if test "x$depdir" = x; then 31080 as_fn_error $? "Could not download build dependency cups" "$LINENO" 5 31081 fi 31082 CUPS=$depdir 31083 if test "x$theroot" != x; then 31084 CUPS="$theroot" 31085 fi 31086 if test "x$thecflags" != x; then 31087 CUPS_CFLAGS="$thecflags" 31088 fi 31089 if test "x$thelibs" != x; then 31090 CUPS_LIBS="$thelibs" 31091 fi 31092 CUPS_FOUND=yes 31093 31094 fi 31095 31096 fi 31097 31098 fi 31099 if test "x$CUPS_FOUND" = xno; then 31100 # Are the cups headers installed in the default /usr/include location? 31101 for ac_header in cups/cups.h cups/ppd.h 31102 do : 31103 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 31104 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 31105 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 31106 cat >>confdefs.h <<_ACEOF 31107 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 31108 _ACEOF 31109 CUPS_FOUND=yes 31110 CUPS_CFLAGS= 31111 DEFAULT_CUPS=yes 31112 fi 31113 31114 done 31115 31116 fi 31117 if test "x$CUPS_FOUND" = xno; then 31118 # Getting nervous now? Lets poke around for standard Solaris third-party 31119 # package installation locations. 31120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 31121 $as_echo_n "checking for cups headers... " >&6; } 31122 if test -s /opt/sfw/cups/include/cups/cups.h; then 31123 # An SFW package seems to be installed! 31124 CUPS_FOUND=yes 31125 CUPS_CFLAGS="-I/opt/sfw/cups/include" 31126 elif test -s /opt/csw/include/cups/cups.h; then 31127 # A CSW package seems to be installed! 31128 CUPS_FOUND=yes 31129 CUPS_CFLAGS="-I/opt/csw/include" 31130 fi 31131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 31132 $as_echo "$CUPS_FOUND" >&6; } 31133 fi 31134 if test "x$CUPS_FOUND" = xno; then 31135 31136 # Print a helpful message on how to acquire the necessary build dependency. 31137 # cups is the help tag: freetyp2, cups, pulse, alsa etc 31138 MISSING_DEPENDENCY=cups 31139 PKGHANDLER_COMMAND= 31140 31141 case $PKGHANDLER in 31142 apt-get) 31143 apt_help $MISSING_DEPENDENCY ;; 31144 yum) 31145 yum_help $MISSING_DEPENDENCY ;; 31146 port) 31147 port_help $MISSING_DEPENDENCY ;; 31148 pkgutil) 31149 pkgutil_help $MISSING_DEPENDENCY ;; 31150 pkgadd) 31151 pkgadd_help $MISSING_DEPENDENCY ;; 31152 * ) 31153 break ;; 31154 esac 31155 31156 if test "x$PKGHANDLER_COMMAND" != x; then 31157 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 31158 fi 31159 31160 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 31161 fi 31162 fi 31163 31164 31165 31166 31167 31168 31169 ############################################################################### 31170 # 31171 # The ubiquitous freetype2 library is used to render fonts. 31172 # 31173 31174 # Check whether --with-freetype was given. 31175 if test "${with_freetype+set}" = set; then : 31176 withval=$with_freetype; 31177 fi 31178 31179 31180 # If we are using the OS installed system lib for freetype, then we do not need to copy it to the build tree 31181 USING_SYSTEM_FT_LIB=false 31182 31183 if test "x$FREETYPE2_NOT_NEEDED" = xyes; then 31184 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 31185 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype is ignored" >&5 31186 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype is ignored" >&2;} 31187 fi 31188 FREETYPE2_CFLAGS= 31189 FREETYPE2_LIBS= 31190 FREETYPE2_LIB_PATH= 31191 else 31192 FREETYPE2_FOUND=no 31193 31194 if test "x$with_freetype" != x; then 31195 31196 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31197 31198 # Input might be given as Windows format, start by converting to 31199 # unix format. 31200 path="$with_freetype" 31201 new_path=`$CYGPATH -u "$path"` 31202 31203 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31204 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31205 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31206 # "foo.exe" is OK but "foo" is an error. 31207 # 31208 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31209 # It is also a way to make sure we got the proper file name for the real test later on. 31210 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31211 if test "x$test_shortpath" = x; then 31212 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_freetype, which resolves as \"$path\", is invalid." >&5 31213 $as_echo "$as_me: The path of with_freetype, which resolves as \"$path\", is invalid." >&6;} 31214 as_fn_error $? "Cannot locate the the path of with_freetype" "$LINENO" 5 31215 fi 31216 31217 # Call helper function which possibly converts this using DOS-style short mode. 31218 # If so, the updated path is stored in $new_path. 31219 31220 input_path="$new_path" 31221 # Check if we need to convert this using DOS-style short mode. If the path 31222 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31223 # take no chances and rewrite it. 31224 # Note: m4 eats our [], so we need to use [ and ] instead. 31225 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31226 if test "x$has_forbidden_chars" != x; then 31227 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31228 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31229 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31230 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31231 # Going to short mode and back again did indeed matter. Since short mode is 31232 # case insensitive, let's make it lowercase to improve readability. 31233 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31234 # Now convert it back to Unix-stile (cygpath) 31235 input_path=`$CYGPATH -u "$shortmode_path"` 31236 new_path="$input_path" 31237 fi 31238 fi 31239 31240 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31241 if test "x$test_cygdrive_prefix" = x; then 31242 # As a simple fix, exclude /usr/bin since it's not a real path. 31243 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31244 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31245 # a path prefixed by /cygdrive for fixpath to work. 31246 new_path="$CYGWIN_ROOT_PATH$input_path" 31247 fi 31248 fi 31249 31250 31251 if test "x$path" != "x$new_path"; then 31252 with_freetype="$new_path" 31253 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_freetype to \"$new_path\"" >&5 31254 $as_echo "$as_me: Rewriting with_freetype to \"$new_path\"" >&6;} 31255 fi 31256 31257 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31258 31259 path="$with_freetype" 31260 has_colon=`$ECHO $path | $GREP ^.:` 31261 new_path="$path" 31262 if test "x$has_colon" = x; then 31263 # Not in mixed or Windows style, start by that. 31264 new_path=`cmd //c echo $path` 31265 fi 31266 31267 31268 input_path="$new_path" 31269 # Check if we need to convert this using DOS-style short mode. If the path 31270 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31271 # take no chances and rewrite it. 31272 # Note: m4 eats our [], so we need to use [ and ] instead. 31273 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31274 if test "x$has_forbidden_chars" != x; then 31275 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31276 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31277 fi 31278 31279 31280 windows_path="$new_path" 31281 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31282 unix_path=`$CYGPATH -u "$windows_path"` 31283 new_path="$unix_path" 31284 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31285 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31286 new_path="$unix_path" 31287 fi 31288 31289 if test "x$path" != "x$new_path"; then 31290 with_freetype="$new_path" 31291 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_freetype to \"$new_path\"" >&5 31292 $as_echo "$as_me: Rewriting with_freetype to \"$new_path\"" >&6;} 31293 fi 31294 31295 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31296 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31297 31298 else 31299 # We're on a posix platform. Hooray! :) 31300 path="$with_freetype" 31301 31302 if test ! -f "$path" && test ! -d "$path"; then 31303 as_fn_error $? "The path of with_freetype, which resolves as \"$path\", is not found." "$LINENO" 5 31304 fi 31305 31306 has_space=`$ECHO "$path" | $GREP " "` 31307 if test "x$has_space" != x; then 31308 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_freetype, which resolves as \"$path\", is invalid." >&5 31309 $as_echo "$as_me: The path of with_freetype, which resolves as \"$path\", is invalid." >&6;} 31310 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31311 fi 31312 fi 31313 31314 FREETYPE2_LIBS="-L$with_freetype/lib -lfreetype" 31315 FREETYPE2_LIB_PATH="$with_freetype/lib" 31316 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -d "$with_freetype/lib/amd64"; then 31317 FREETYPE2_LIBS="-L$with_freetype/lib/amd64 -lfreetype" 31318 FREETYPE2_LIB_PATH="$with_freetype/lib/amd64" 31319 fi 31320 if test "x$OPENJDK_TARGET_OS" = xwindows; then 31321 FREETYPE2_LIBS="$with_freetype/lib/freetype.lib" 31322 fi 31323 FREETYPE2_CFLAGS="-I$with_freetype/include" 31324 if test -s $with_freetype/include/ft2build.h && test -d $with_freetype/include/freetype2/freetype; then 31325 FREETYPE2_CFLAGS="-I$with_freetype/include/freetype2 -I$with_freetype/include" 31326 fi 31327 FREETYPE2_FOUND=yes 31328 if test "x$FREETYPE2_FOUND" = xyes; then 31329 # Verify that the directories exist 31330 if ! test -d "$with_freetype/lib" || ! test -d "$with_freetype/include"; then 31331 as_fn_error $? "Could not find the expected directories $with_freetype/lib and $with_freetype/include" "$LINENO" 5 31332 fi 31333 # List the contents of the lib. 31334 FREETYPELIB=`ls $with_freetype/lib/libfreetype.so $with_freetype/lib/freetype.dll 2> /dev/null` 31335 if test "x$FREETYPELIB" = x; then 31336 as_fn_error $? "Could not find libfreetype.so nor freetype.dll in $with_freetype/lib" "$LINENO" 5 31337 fi 31338 # Check one h-file 31339 if ! test -s "$with_freetype/include/ft2build.h"; then 31340 as_fn_error $? "Could not find $with_freetype/include/ft2build.h" "$LINENO" 5 31341 fi 31342 fi 31343 fi 31344 if test "x$FREETYPE2_FOUND" = xno; then 31345 31346 31347 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 31348 # Source the builddeps file again, to make sure it uses the latest variables! 31349 . $builddepsfile 31350 # Look for a target and build machine specific resource! 31351 eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}} 31352 if test "x$resource" = x; then 31353 # Ok, lets instead look for a target specific resource 31354 eval resource=\${builddep_freetype2_TARGET_${rewritten_target_var}} 31355 fi 31356 if test "x$resource" = x; then 31357 # Ok, lets instead look for a build specific resource 31358 eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}} 31359 fi 31360 if test "x$resource" = x; then 31361 # Ok, lets instead look for a generic resource 31362 # (The freetype2 comes from M4 and not the shell, thus no need for eval here.) 31363 resource=${builddep_freetype2} 31364 fi 31365 if test "x$resource" != x; then 31366 { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for freetype2" >&5 31367 $as_echo "$as_me: Using builddeps $resource for freetype2" >&6;} 31368 # If the resource in the builddeps.conf file is an existing directory, 31369 # for example /java/linux/cups 31370 if test -d ${resource}; then 31371 depdir=${resource} 31372 else 31373 31374 # freetype2 is for example mymodule 31375 # $resource is for example libs/general/libmymod_1_2_3.zip 31376 # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps 31377 # $with_builddeps_dir is for example /localhome/builddeps 31378 # depdir is the name of the variable into which we store the depdir, eg MYMOD 31379 # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and 31380 # unzip into the directory: /localhome/builddeps/libmymod_1_2_3 31381 filename=`basename $resource` 31382 filebase=`echo $filename | sed 's/\.[^\.]*$//'` 31383 filebase=${filename%%.*} 31384 extension=${filename#*.} 31385 installdir=$with_builddeps_dir/$filebase 31386 if test ! -f $installdir/$filename.unpacked; then 31387 { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&5 31388 $as_echo "$as_me: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&6;} 31389 if test ! -d $installdir; then 31390 mkdir -p $installdir 31391 fi 31392 if test ! -d $installdir; then 31393 as_fn_error $? "Could not create directory $installdir" "$LINENO" 5 31394 fi 31395 tmpfile=`mktemp $installdir/freetype2.XXXXXXXXX` 31396 touch $tmpfile 31397 if test ! -f $tmpfile; then 31398 as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5 31399 fi 31400 31401 # $with_builddeps_server/$resource is the ftp://abuilddeps.server.com/libs/cups.zip 31402 # $tmpfile is the local file name for the downloaded file. 31403 VALID_TOOL=no 31404 if test "x$BDEPS_FTP" = xwget; then 31405 VALID_TOOL=yes 31406 wget -O $tmpfile $with_builddeps_server/$resource 31407 fi 31408 if test "x$BDEPS_FTP" = xlftp; then 31409 VALID_TOOL=yes 31410 lftp -c "get $with_builddeps_server/$resource -o $tmpfile" 31411 fi 31412 if test "x$BDEPS_FTP" = xftp; then 31413 VALID_TOOL=yes 31414 FTPSERVER=`echo $with_builddeps_server/$resource | cut -f 3 -d '/'` 31415 FTPPATH=`echo $with_builddeps_server/$resource | cut -f 4- -d '/'` 31416 FTPUSERPWD=${FTPSERVER%%@*} 31417 if test "x$FTPSERVER" != "x$FTPUSERPWD"; then 31418 FTPUSER=${userpwd%%:*} 31419 FTPPWD=${userpwd#*@} 31420 FTPSERVER=${FTPSERVER#*@} 31421 else 31422 FTPUSER=ftp 31423 FTPPWD=ftp 31424 fi 31425 # the "pass" command does not work on some 31426 # ftp clients (read ftp.exe) but if it works, 31427 # passive mode is better! 31428 (\ 31429 echo "user $FTPUSER $FTPPWD" ;\ 31430 echo "pass" ;\ 31431 echo "bin" ;\ 31432 echo "get $FTPPATH $tmpfile" ;\ 31433 ) | ftp -in $FTPSERVER 31434 fi 31435 if test "x$VALID_TOOL" != xyes; then 31436 as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5 31437 fi 31438 31439 mv $tmpfile $installdir/$filename 31440 if test ! -s $installdir/$filename; then 31441 as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5 31442 fi 31443 case "$extension" in 31444 zip) echo "Unzipping $installdir/$filename..." 31445 (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked) 31446 ;; 31447 tar.gz) echo "Untaring $installdir/$filename..." 31448 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31449 ;; 31450 tgz) echo "Untaring $installdir/$filename..." 31451 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31452 ;; 31453 *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5 31454 ;; 31455 esac 31456 fi 31457 if test -f $installdir/$filename.unpacked; then 31458 depdir=$installdir 31459 fi 31460 31461 fi 31462 # Source the builddeps file again, because in the previous command, the depdir 31463 # was updated to point at the current build dependency install directory. 31464 . $builddepsfile 31465 # Now extract variables from the builddeps.conf files. 31466 theroot=${builddep_freetype2_ROOT} 31467 thecflags=${builddep_freetype2_CFLAGS} 31468 thelibs=${builddep_freetype2_LIBS} 31469 if test "x$depdir" = x; then 31470 as_fn_error $? "Could not download build dependency freetype2" "$LINENO" 5 31471 fi 31472 FREETYPE2=$depdir 31473 if test "x$theroot" != x; then 31474 FREETYPE2="$theroot" 31475 fi 31476 if test "x$thecflags" != x; then 31477 FREETYPE2_CFLAGS="$thecflags" 31478 fi 31479 if test "x$thelibs" != x; then 31480 FREETYPE2_LIBS="$thelibs" 31481 fi 31482 FREETYPE2_FOUND=yes 31483 else FREETYPE2_FOUND=no 31484 31485 fi 31486 else FREETYPE2_FOUND=no 31487 31488 fi 31489 31490 USING_SYSTEM_FT_LIB=true 31491 fi 31492 if test "x$FREETYPE2_FOUND" = xno && test "x$OPENJDK_TARGET_OS" = xwindows; then 31493 FREETYPELOCATION="$PROGRAMFILES/GnuWin32" 31494 31495 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31496 31497 # Input might be given as Windows format, start by converting to 31498 # unix format. 31499 path="$FREETYPELOCATION" 31500 new_path=`$CYGPATH -u "$path"` 31501 31502 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31503 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31504 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31505 # "foo.exe" is OK but "foo" is an error. 31506 # 31507 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31508 # It is also a way to make sure we got the proper file name for the real test later on. 31509 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31510 if test "x$test_shortpath" = x; then 31511 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPELOCATION, which resolves as \"$path\", is invalid." >&5 31512 $as_echo "$as_me: The path of FREETYPELOCATION, which resolves as \"$path\", is invalid." >&6;} 31513 as_fn_error $? "Cannot locate the the path of FREETYPELOCATION" "$LINENO" 5 31514 fi 31515 31516 # Call helper function which possibly converts this using DOS-style short mode. 31517 # If so, the updated path is stored in $new_path. 31518 31519 input_path="$new_path" 31520 # Check if we need to convert this using DOS-style short mode. If the path 31521 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31522 # take no chances and rewrite it. 31523 # Note: m4 eats our [], so we need to use [ and ] instead. 31524 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31525 if test "x$has_forbidden_chars" != x; then 31526 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31527 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31528 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31529 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31530 # Going to short mode and back again did indeed matter. Since short mode is 31531 # case insensitive, let's make it lowercase to improve readability. 31532 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31533 # Now convert it back to Unix-stile (cygpath) 31534 input_path=`$CYGPATH -u "$shortmode_path"` 31535 new_path="$input_path" 31536 fi 31537 fi 31538 31539 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31540 if test "x$test_cygdrive_prefix" = x; then 31541 # As a simple fix, exclude /usr/bin since it's not a real path. 31542 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31543 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31544 # a path prefixed by /cygdrive for fixpath to work. 31545 new_path="$CYGWIN_ROOT_PATH$input_path" 31546 fi 31547 fi 31548 31549 31550 if test "x$path" != "x$new_path"; then 31551 FREETYPELOCATION="$new_path" 31552 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPELOCATION to \"$new_path\"" >&5 31553 $as_echo "$as_me: Rewriting FREETYPELOCATION to \"$new_path\"" >&6;} 31554 fi 31555 31556 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31557 31558 path="$FREETYPELOCATION" 31559 has_colon=`$ECHO $path | $GREP ^.:` 31560 new_path="$path" 31561 if test "x$has_colon" = x; then 31562 # Not in mixed or Windows style, start by that. 31563 new_path=`cmd //c echo $path` 31564 fi 31565 31566 31567 input_path="$new_path" 31568 # Check if we need to convert this using DOS-style short mode. If the path 31569 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31570 # take no chances and rewrite it. 31571 # Note: m4 eats our [], so we need to use [ and ] instead. 31572 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31573 if test "x$has_forbidden_chars" != x; then 31574 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31575 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31576 fi 31577 31578 31579 windows_path="$new_path" 31580 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31581 unix_path=`$CYGPATH -u "$windows_path"` 31582 new_path="$unix_path" 31583 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31584 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31585 new_path="$unix_path" 31586 fi 31587 31588 if test "x$path" != "x$new_path"; then 31589 FREETYPELOCATION="$new_path" 31590 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPELOCATION to \"$new_path\"" >&5 31591 $as_echo "$as_me: Rewriting FREETYPELOCATION to \"$new_path\"" >&6;} 31592 fi 31593 31594 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31595 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31596 31597 else 31598 # We're on a posix platform. Hooray! :) 31599 path="$FREETYPELOCATION" 31600 31601 if test ! -f "$path" && test ! -d "$path"; then 31602 as_fn_error $? "The path of FREETYPELOCATION, which resolves as \"$path\", is not found." "$LINENO" 5 31603 fi 31604 31605 has_space=`$ECHO "$path" | $GREP " "` 31606 if test "x$has_space" != x; then 31607 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPELOCATION, which resolves as \"$path\", is invalid." >&5 31608 $as_echo "$as_me: The path of FREETYPELOCATION, which resolves as \"$path\", is invalid." >&6;} 31609 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31610 fi 31611 fi 31612 31613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype in some standard windows locations" >&5 31614 $as_echo_n "checking for freetype in some standard windows locations... " >&6; } 31615 if test -s "$FREETYPELOCATION/include/ft2build.h" && test -d "$FREETYPELOCATION/include/freetype2/freetype"; then 31616 FREETYPE2_CFLAGS="-I$FREETYPELOCATION/include/freetype2 -I$FREETYPELOCATION/include" 31617 FREETYPE2_LIBS="$FREETYPELOCATION/lib/freetype.lib" 31618 FREETYPE2_LIB_PATH="$FREETYPELOCATION/lib" 31619 if ! test -s "$FREETYPE2_LIBS"; then 31620 as_fn_error $? "Could not find $FREETYPE2_LIBS" "$LINENO" 5 31621 fi 31622 if ! test -s "$FREETYPE2_LIB_PATH/freetype.dll"; then 31623 as_fn_error $? "Could not find $FREETYPE2_LIB_PATH/freetype.dll" "$LINENO" 5 31624 fi 31625 USING_SYSTEM_FT_LIB=true 31626 FREETYPE2_FOUND=yes 31627 fi 31628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE2_FOUND" >&5 31629 $as_echo "$FREETYPE2_FOUND" >&6; } 31630 fi 31631 if test "x$FREETYPE2_FOUND" = xno; then 31632 31633 pkg_failed=no 31634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE2" >&5 31635 $as_echo_n "checking for FREETYPE2... " >&6; } 31636 31637 if test -n "$FREETYPE2_CFLAGS"; then 31638 pkg_cv_FREETYPE2_CFLAGS="$FREETYPE2_CFLAGS" 31639 elif test -n "$PKG_CONFIG"; then 31640 if test -n "$PKG_CONFIG" && \ 31641 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 31642 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 31643 ac_status=$? 31644 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 31645 test $ac_status = 0; }; then 31646 pkg_cv_FREETYPE2_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 31647 else 31648 pkg_failed=yes 31649 fi 31650 else 31651 pkg_failed=untried 31652 fi 31653 if test -n "$FREETYPE2_LIBS"; then 31654 pkg_cv_FREETYPE2_LIBS="$FREETYPE2_LIBS" 31655 elif test -n "$PKG_CONFIG"; then 31656 if test -n "$PKG_CONFIG" && \ 31657 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 31658 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 31659 ac_status=$? 31660 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 31661 test $ac_status = 0; }; then 31662 pkg_cv_FREETYPE2_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 31663 else 31664 pkg_failed=yes 31665 fi 31666 else 31667 pkg_failed=untried 31668 fi 31669 31670 31671 31672 if test $pkg_failed = yes; then 31673 31674 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 31675 _pkg_short_errors_supported=yes 31676 else 31677 _pkg_short_errors_supported=no 31678 fi 31679 if test $_pkg_short_errors_supported = yes; then 31680 FREETYPE2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 31681 else 31682 FREETYPE2_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 31683 fi 31684 # Put the nasty error message in config.log where it belongs 31685 echo "$FREETYPE2_PKG_ERRORS" >&5 31686 31687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31688 $as_echo "no" >&6; } 31689 FREETYPE2_FOUND=no 31690 elif test $pkg_failed = untried; then 31691 FREETYPE2_FOUND=no 31692 else 31693 FREETYPE2_CFLAGS=$pkg_cv_FREETYPE2_CFLAGS 31694 FREETYPE2_LIBS=$pkg_cv_FREETYPE2_LIBS 31695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31696 $as_echo "yes" >&6; } 31697 FREETYPE2_FOUND=yes 31698 fi 31699 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 31700 FREETYPE2_LIBS=`$ECHO $FREETYPE2_LIBS | $SED 's/-lz//g'` 31701 USING_SYSTEM_FT_LIB=true 31702 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 31703 if test "x$FREETYPE2_FOUND" = xyes && test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 31704 FREETYPE2_LIBS=`$ECHO $FREETYPE2_LIBS | $SED 's?/lib?/lib/amd64?g'` 31705 fi 31706 fi 31707 if test "x$FREETYPE2_FOUND" = xno; then 31708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype in some standard locations" >&5 31709 $as_echo_n "checking for freetype in some standard locations... " >&6; } 31710 31711 if test -s /usr/X11/include/ft2build.h && test -d /usr/X11/include/freetype2/freetype; then 31712 DEFAULT_FREETYPE_CFLAGS="-I/usr/X11/include/freetype2 -I/usr/X11/include" 31713 DEFAULT_FREETYPE_LIBS="-L/usr/X11/lib -lfreetype" 31714 fi 31715 if test -s /usr/include/ft2build.h && test -d /usr/include/freetype2/freetype; then 31716 DEFAULT_FREETYPE_CFLAGS="-I/usr/include/freetype2" 31717 DEFAULT_FREETYPE_LIBS="-lfreetype" 31718 fi 31719 31720 PREV_CXXCFLAGS="$CXXFLAGS" 31721 PREV_LDFLAGS="$LDFLAGS" 31722 CXXFLAGS="$CXXFLAGS $DEFAULT_FREETYPE_CFLAGS" 31723 LDFLAGS="$LDFLAGS $DEFAULT_FREETYPE_LIBS" 31724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 31725 /* end confdefs.h. */ 31726 #include<ft2build.h> 31727 #include FT_FREETYPE_H 31728 int main() { return 0; } 31729 31730 _ACEOF 31731 if ac_fn_cxx_try_link "$LINENO"; then : 31732 31733 # Yes, the default cflags and libs did the trick. 31734 FREETYPE2_FOUND=yes 31735 FREETYPE2_CFLAGS="$DEFAULT_FREETYPE_CFLAGS" 31736 FREETYPE2_LIBS="$DEFAULT_FREETYPE_LIBS" 31737 31738 else 31739 31740 FREETYPE2_FOUND=no 31741 31742 fi 31743 rm -f core conftest.err conftest.$ac_objext \ 31744 conftest$ac_exeext conftest.$ac_ext 31745 CXXCFLAGS="$PREV_CXXFLAGS" 31746 LDFLAGS="$PREV_LDFLAGS" 31747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE2_FOUND" >&5 31748 $as_echo "$FREETYPE2_FOUND" >&6; } 31749 USING_SYSTEM_FT_LIB=true 31750 fi 31751 if test "x$FREETYPE2_FOUND" = xno; then 31752 31753 # Print a helpful message on how to acquire the necessary build dependency. 31754 # freetype2 is the help tag: freetyp2, cups, pulse, alsa etc 31755 MISSING_DEPENDENCY=freetype2 31756 PKGHANDLER_COMMAND= 31757 31758 case $PKGHANDLER in 31759 apt-get) 31760 apt_help $MISSING_DEPENDENCY ;; 31761 yum) 31762 yum_help $MISSING_DEPENDENCY ;; 31763 port) 31764 port_help $MISSING_DEPENDENCY ;; 31765 pkgutil) 31766 pkgutil_help $MISSING_DEPENDENCY ;; 31767 pkgadd) 31768 pkgadd_help $MISSING_DEPENDENCY ;; 31769 * ) 31770 break ;; 31771 esac 31772 31773 if test "x$PKGHANDLER_COMMAND" != x; then 31774 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 31775 fi 31776 31777 as_fn_error $? "Could not find freetype2! $HELP_MSG " "$LINENO" 5 31778 fi 31779 31780 if test "x$OPENJDK_TARGET_OS" != xwindows; then 31781 # AC_CHECK_LIB does not support use of cl.exe 31782 PREV_LDFLAGS="$LDFLAGS" 31783 LDFLAGS="$FREETYPE2_LIBS" 31784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FT_Init_FreeType in -lfreetype" >&5 31785 $as_echo_n "checking for FT_Init_FreeType in -lfreetype... " >&6; } 31786 if ${ac_cv_lib_freetype_FT_Init_FreeType+:} false; then : 31787 $as_echo_n "(cached) " >&6 31788 else 31789 ac_check_lib_save_LIBS=$LIBS 31790 LIBS="-lfreetype $LIBS" 31791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 31792 /* end confdefs.h. */ 31793 31794 /* Override any GCC internal prototype to avoid an error. 31795 Use char because int might match the return type of a GCC 31796 builtin and then its argument prototype would still apply. */ 31797 #ifdef __cplusplus 31798 extern "C" 31799 #endif 31800 char FT_Init_FreeType (); 31801 int 31802 main () 31803 { 31804 return FT_Init_FreeType (); 31805 ; 31806 return 0; 31807 } 31808 _ACEOF 31809 if ac_fn_cxx_try_link "$LINENO"; then : 31810 ac_cv_lib_freetype_FT_Init_FreeType=yes 31811 else 31812 ac_cv_lib_freetype_FT_Init_FreeType=no 31813 fi 31814 rm -f core conftest.err conftest.$ac_objext \ 31815 conftest$ac_exeext conftest.$ac_ext 31816 LIBS=$ac_check_lib_save_LIBS 31817 fi 31818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_freetype_FT_Init_FreeType" >&5 31819 $as_echo "$ac_cv_lib_freetype_FT_Init_FreeType" >&6; } 31820 if test "x$ac_cv_lib_freetype_FT_Init_FreeType" = xyes; then : 31821 FREETYPE2_FOUND=true 31822 else 31823 as_fn_error $? "Could not find freetype2! $HELP_MSG " "$LINENO" 5 31824 fi 31825 31826 LDFLAGS="$PREV_LDFLAGS" 31827 fi 31828 fi 31829 31830 31831 31832 31833 31834 31835 31836 31837 31838 ############################################################################### 31839 # 31840 # Check for alsa headers and libraries. Used on Linux/GNU systems. 31841 # 31842 31843 # Check whether --with-alsa was given. 31844 if test "${with_alsa+set}" = set; then : 31845 withval=$with_alsa; 31846 fi 31847 31848 31849 # Check whether --with-alsa-include was given. 31850 if test "${with_alsa_include+set}" = set; then : 31851 withval=$with_alsa_include; 31852 fi 31853 31854 31855 # Check whether --with-alsa-lib was given. 31856 if test "${with_alsa_lib+set}" = set; then : 31857 withval=$with_alsa_lib; 31858 fi 31859 31860 31861 if test "x$ALSA_NOT_NEEDED" = xyes; then 31862 if test "x${with_alsa}" != x || test "x${with_alsa_include}" != x || test "x${with_alsa_lib}" != x; then 31863 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa is ignored" >&5 31864 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa is ignored" >&2;} 31865 fi 31866 ALSA_CFLAGS= 31867 ALSA_LIBS= 31868 else 31869 ALSA_FOUND=no 31870 31871 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 31872 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 31873 fi 31874 31875 if test "x${with_alsa}" != x; then 31876 ALSA_LIBS="-L${with_alsa}/lib -lalsa" 31877 ALSA_CFLAGS="-I${with_alsa}/include" 31878 ALSA_FOUND=yes 31879 fi 31880 if test "x${with_alsa_include}" != x; then 31881 ALSA_CFLAGS="-I${with_alsa_include}" 31882 ALSA_FOUND=yes 31883 fi 31884 if test "x${with_alsa_lib}" != x; then 31885 ALSA_LIBS="-L${with_alsa_lib} -lalsa" 31886 ALSA_FOUND=yes 31887 fi 31888 if test "x$ALSA_FOUND" = xno; then 31889 31890 31891 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 31892 # Source the builddeps file again, to make sure it uses the latest variables! 31893 . $builddepsfile 31894 # Look for a target and build machine specific resource! 31895 eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}} 31896 if test "x$resource" = x; then 31897 # Ok, lets instead look for a target specific resource 31898 eval resource=\${builddep_alsa_TARGET_${rewritten_target_var}} 31899 fi 31900 if test "x$resource" = x; then 31901 # Ok, lets instead look for a build specific resource 31902 eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}} 31903 fi 31904 if test "x$resource" = x; then 31905 # Ok, lets instead look for a generic resource 31906 # (The alsa comes from M4 and not the shell, thus no need for eval here.) 31907 resource=${builddep_alsa} 31908 fi 31909 if test "x$resource" != x; then 31910 { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for alsa" >&5 31911 $as_echo "$as_me: Using builddeps $resource for alsa" >&6;} 31912 # If the resource in the builddeps.conf file is an existing directory, 31913 # for example /java/linux/cups 31914 if test -d ${resource}; then 31915 depdir=${resource} 31916 else 31917 31918 # alsa is for example mymodule 31919 # $resource is for example libs/general/libmymod_1_2_3.zip 31920 # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps 31921 # $with_builddeps_dir is for example /localhome/builddeps 31922 # depdir is the name of the variable into which we store the depdir, eg MYMOD 31923 # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and 31924 # unzip into the directory: /localhome/builddeps/libmymod_1_2_3 31925 filename=`basename $resource` 31926 filebase=`echo $filename | sed 's/\.[^\.]*$//'` 31927 filebase=${filename%%.*} 31928 extension=${filename#*.} 31929 installdir=$with_builddeps_dir/$filebase 31930 if test ! -f $installdir/$filename.unpacked; then 31931 { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&5 31932 $as_echo "$as_me: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&6;} 31933 if test ! -d $installdir; then 31934 mkdir -p $installdir 31935 fi 31936 if test ! -d $installdir; then 31937 as_fn_error $? "Could not create directory $installdir" "$LINENO" 5 31938 fi 31939 tmpfile=`mktemp $installdir/alsa.XXXXXXXXX` 31940 touch $tmpfile 31941 if test ! -f $tmpfile; then 31942 as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5 31943 fi 31944 31945 # $with_builddeps_server/$resource is the ftp://abuilddeps.server.com/libs/cups.zip 31946 # $tmpfile is the local file name for the downloaded file. 31947 VALID_TOOL=no 31948 if test "x$BDEPS_FTP" = xwget; then 31949 VALID_TOOL=yes 31950 wget -O $tmpfile $with_builddeps_server/$resource 31951 fi 31952 if test "x$BDEPS_FTP" = xlftp; then 31953 VALID_TOOL=yes 31954 lftp -c "get $with_builddeps_server/$resource -o $tmpfile" 31955 fi 31956 if test "x$BDEPS_FTP" = xftp; then 31957 VALID_TOOL=yes 31958 FTPSERVER=`echo $with_builddeps_server/$resource | cut -f 3 -d '/'` 31959 FTPPATH=`echo $with_builddeps_server/$resource | cut -f 4- -d '/'` 31960 FTPUSERPWD=${FTPSERVER%%@*} 31961 if test "x$FTPSERVER" != "x$FTPUSERPWD"; then 31962 FTPUSER=${userpwd%%:*} 31963 FTPPWD=${userpwd#*@} 31964 FTPSERVER=${FTPSERVER#*@} 31965 else 31966 FTPUSER=ftp 31967 FTPPWD=ftp 31968 fi 31969 # the "pass" command does not work on some 31970 # ftp clients (read ftp.exe) but if it works, 31971 # passive mode is better! 31972 (\ 31973 echo "user $FTPUSER $FTPPWD" ;\ 31974 echo "pass" ;\ 31975 echo "bin" ;\ 31976 echo "get $FTPPATH $tmpfile" ;\ 31977 ) | ftp -in $FTPSERVER 31978 fi 31979 if test "x$VALID_TOOL" != xyes; then 31980 as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5 31981 fi 31982 31983 mv $tmpfile $installdir/$filename 31984 if test ! -s $installdir/$filename; then 31985 as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5 31986 fi 31987 case "$extension" in 31988 zip) echo "Unzipping $installdir/$filename..." 31989 (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked) 31990 ;; 31991 tar.gz) echo "Untaring $installdir/$filename..." 31992 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31993 ;; 31994 tgz) echo "Untaring $installdir/$filename..." 31995 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31996 ;; 31997 *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5 31998 ;; 31999 esac 32000 fi 32001 if test -f $installdir/$filename.unpacked; then 32002 depdir=$installdir 32003 fi 32004 32005 fi 32006 # Source the builddeps file again, because in the previous command, the depdir 32007 # was updated to point at the current build dependency install directory. 32008 . $builddepsfile 32009 # Now extract variables from the builddeps.conf files. 32010 theroot=${builddep_alsa_ROOT} 32011 thecflags=${builddep_alsa_CFLAGS} 32012 thelibs=${builddep_alsa_LIBS} 32013 if test "x$depdir" = x; then 32014 as_fn_error $? "Could not download build dependency alsa" "$LINENO" 5 32015 fi 32016 ALSA=$depdir 32017 if test "x$theroot" != x; then 32018 ALSA="$theroot" 32019 fi 32020 if test "x$thecflags" != x; then 32021 ALSA_CFLAGS="$thecflags" 32022 fi 32023 if test "x$thelibs" != x; then 32024 ALSA_LIBS="$thelibs" 32025 fi 32026 ALSA_FOUND=yes 32027 else ALSA_FOUND=no 32028 32029 fi 32030 else ALSA_FOUND=no 32031 32032 fi 32033 32034 fi 32035 if test "x$ALSA_FOUND" = xno; then 32036 32037 pkg_failed=no 32038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 32039 $as_echo_n "checking for ALSA... " >&6; } 32040 32041 if test -n "$ALSA_CFLAGS"; then 32042 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 32043 elif test -n "$PKG_CONFIG"; then 32044 if test -n "$PKG_CONFIG" && \ 32045 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 32046 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 32047 ac_status=$? 32048 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32049 test $ac_status = 0; }; then 32050 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 32051 else 32052 pkg_failed=yes 32053 fi 32054 else 32055 pkg_failed=untried 32056 fi 32057 if test -n "$ALSA_LIBS"; then 32058 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 32059 elif test -n "$PKG_CONFIG"; then 32060 if test -n "$PKG_CONFIG" && \ 32061 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 32062 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 32063 ac_status=$? 32064 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32065 test $ac_status = 0; }; then 32066 pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 32067 else 32068 pkg_failed=yes 32069 fi 32070 else 32071 pkg_failed=untried 32072 fi 32073 32074 32075 32076 if test $pkg_failed = yes; then 32077 32078 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 32079 _pkg_short_errors_supported=yes 32080 else 32081 _pkg_short_errors_supported=no 32082 fi 32083 if test $_pkg_short_errors_supported = yes; then 32084 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 32085 else 32086 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 32087 fi 32088 # Put the nasty error message in config.log where it belongs 32089 echo "$ALSA_PKG_ERRORS" >&5 32090 32091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32092 $as_echo "no" >&6; } 32093 ALSA_FOUND=no 32094 elif test $pkg_failed = untried; then 32095 ALSA_FOUND=no 32096 else 32097 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 32098 ALSA_LIBS=$pkg_cv_ALSA_LIBS 32099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32100 $as_echo "yes" >&6; } 32101 ALSA_FOUND=yes 32102 fi 32103 fi 32104 if test "x$ALSA_FOUND" = xno; then 32105 for ac_header in alsa/asoundlib.h 32106 do : 32107 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 32108 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 32109 cat >>confdefs.h <<_ACEOF 32110 #define HAVE_ALSA_ASOUNDLIB_H 1 32111 _ACEOF 32112 ALSA_FOUND=yes 32113 ALSA_CFLAGS=-Iignoreme 32114 ALSA_LIBS=-lasound 32115 DEFAULT_ALSA=yes 32116 else 32117 ALSA_FOUND=no 32118 fi 32119 32120 done 32121 32122 fi 32123 if test "x$ALSA_FOUND" = xno; then 32124 32125 # Print a helpful message on how to acquire the necessary build dependency. 32126 # alsa is the help tag: freetyp2, cups, pulse, alsa etc 32127 MISSING_DEPENDENCY=alsa 32128 PKGHANDLER_COMMAND= 32129 32130 case $PKGHANDLER in 32131 apt-get) 32132 apt_help $MISSING_DEPENDENCY ;; 32133 yum) 32134 yum_help $MISSING_DEPENDENCY ;; 32135 port) 32136 port_help $MISSING_DEPENDENCY ;; 32137 pkgutil) 32138 pkgutil_help $MISSING_DEPENDENCY ;; 32139 pkgadd) 32140 pkgadd_help $MISSING_DEPENDENCY ;; 32141 * ) 32142 break ;; 32143 esac 32144 32145 if test "x$PKGHANDLER_COMMAND" != x; then 32146 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 32147 fi 32148 32149 as_fn_error $? "Could not find alsa! $HELP_MSG " "$LINENO" 5 32150 fi 32151 fi 32152 32153 32154 32155 32156 32157 32158 32159 ############################################################################### 32160 # 32161 # Check for the jpeg library 32162 # 32163 32164 USE_EXTERNAL_LIBJPEG=true 32165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -ljpeg" >&5 32166 $as_echo_n "checking for main in -ljpeg... " >&6; } 32167 if ${ac_cv_lib_jpeg_main+:} false; then : 32168 $as_echo_n "(cached) " >&6 32169 else 32170 ac_check_lib_save_LIBS=$LIBS 32171 LIBS="-ljpeg $LIBS" 32172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32173 /* end confdefs.h. */ 32174 32175 32176 int 32177 main () 32178 { 32179 return main (); 32180 ; 32181 return 0; 32182 } 32183 _ACEOF 32184 if ac_fn_cxx_try_link "$LINENO"; then : 32185 ac_cv_lib_jpeg_main=yes 32186 else 32187 ac_cv_lib_jpeg_main=no 32188 fi 32189 rm -f core conftest.err conftest.$ac_objext \ 32190 conftest$ac_exeext conftest.$ac_ext 32191 LIBS=$ac_check_lib_save_LIBS 32192 fi 32193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_main" >&5 32194 $as_echo "$ac_cv_lib_jpeg_main" >&6; } 32195 if test "x$ac_cv_lib_jpeg_main" = xyes; then : 32196 cat >>confdefs.h <<_ACEOF 32197 #define HAVE_LIBJPEG 1 32198 _ACEOF 32199 32200 LIBS="-ljpeg $LIBS" 32201 32202 else 32203 USE_EXTERNAL_LIBJPEG=false 32204 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use jpeg decoder bundled with the OpenJDK source" >&5 32205 $as_echo "$as_me: Will use jpeg decoder bundled with the OpenJDK source" >&6;} 32206 32207 fi 32208 32209 32210 32211 ############################################################################### 32212 # 32213 # Check for the gif library 32214 # 32215 32216 32217 # Check whether --with-giflib was given. 32218 if test "${with_giflib+set}" = set; then : 32219 withval=$with_giflib; 32220 fi 32221 32222 32223 32224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 32225 $as_echo_n "checking for which giflib to use... " >&6; } 32226 32227 # default is bundled 32228 DEFAULT_GIFLIB=bundled 32229 32230 # 32231 # if user didn't specify, use DEFAULT_GIFLIB 32232 # 32233 if test "x${with_giflib}" = "x"; then 32234 with_giflib=${DEFAULT_GIFLIB} 32235 fi 32236 32237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 32238 $as_echo "${with_giflib}" >&6; } 32239 32240 if test "x${with_giflib}" = "xbundled"; then 32241 USE_EXTERNAL_LIBGIF=false 32242 elif test "x${with_giflib}" = "xsystem"; then 32243 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 32244 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 32245 32246 else 32247 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 32248 fi 32249 32250 32251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 32252 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 32253 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 32254 $as_echo_n "(cached) " >&6 32255 else 32256 ac_check_lib_save_LIBS=$LIBS 32257 LIBS="-lgif $LIBS" 32258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32259 /* end confdefs.h. */ 32260 32261 /* Override any GCC internal prototype to avoid an error. 32262 Use char because int might match the return type of a GCC 32263 builtin and then its argument prototype would still apply. */ 32264 #ifdef __cplusplus 32265 extern "C" 32266 #endif 32267 char DGifGetCode (); 32268 int 32269 main () 32270 { 32271 return DGifGetCode (); 32272 ; 32273 return 0; 32274 } 32275 _ACEOF 32276 if ac_fn_cxx_try_link "$LINENO"; then : 32277 ac_cv_lib_gif_DGifGetCode=yes 32278 else 32279 ac_cv_lib_gif_DGifGetCode=no 32280 fi 32281 rm -f core conftest.err conftest.$ac_objext \ 32282 conftest$ac_exeext conftest.$ac_ext 32283 LIBS=$ac_check_lib_save_LIBS 32284 fi 32285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 32286 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 32287 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 32288 cat >>confdefs.h <<_ACEOF 32289 #define HAVE_LIBGIF 1 32290 _ACEOF 32291 32292 LIBS="-lgif $LIBS" 32293 32294 else 32295 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 32296 fi 32297 32298 32299 USE_EXTERNAL_LIBGIF=true 32300 else 32301 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 32302 fi 32303 32304 32305 ############################################################################### 32306 # 32307 # Check for the zlib library 32308 # 32309 32310 32311 # Check whether --with-zlib was given. 32312 if test "${with_zlib+set}" = set; then : 32313 withval=$with_zlib; 32314 fi 32315 32316 32317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 32318 $as_echo_n "checking for compress in -lz... " >&6; } 32319 if ${ac_cv_lib_z_compress+:} false; then : 32320 $as_echo_n "(cached) " >&6 32321 else 32322 ac_check_lib_save_LIBS=$LIBS 32323 LIBS="-lz $LIBS" 32324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32325 /* end confdefs.h. */ 32326 32327 /* Override any GCC internal prototype to avoid an error. 32328 Use char because int might match the return type of a GCC 32329 builtin and then its argument prototype would still apply. */ 32330 #ifdef __cplusplus 32331 extern "C" 32332 #endif 32333 char compress (); 32334 int 32335 main () 32336 { 32337 return compress (); 32338 ; 32339 return 0; 32340 } 32341 _ACEOF 32342 if ac_fn_cxx_try_link "$LINENO"; then : 32343 ac_cv_lib_z_compress=yes 32344 else 32345 ac_cv_lib_z_compress=no 32346 fi 32347 rm -f core conftest.err conftest.$ac_objext \ 32348 conftest$ac_exeext conftest.$ac_ext 32349 LIBS=$ac_check_lib_save_LIBS 32350 fi 32351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 32352 $as_echo "$ac_cv_lib_z_compress" >&6; } 32353 if test "x$ac_cv_lib_z_compress" = xyes; then : 32354 ZLIB_FOUND=yes 32355 else 32356 ZLIB_FOUND=no 32357 fi 32358 32359 32360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 32361 $as_echo_n "checking for which zlib to use... " >&6; } 32362 32363 DEFAULT_ZLIB=bundled 32364 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 32365 # 32366 # On macosx default is system...on others default is 32367 # 32368 DEFAULT_ZLIB=system 32369 fi 32370 32371 if test "x${ZLIB_FOUND}" != "xyes"; then 32372 # 32373 # If we don't find any system...set default to bundled 32374 # 32375 DEFAULT_ZLIB=bundled 32376 fi 32377 32378 # 32379 # If user didn't specify, use DEFAULT_ZLIB 32380 # 32381 if test "x${with_zlib}" = "x"; then 32382 with_zlib=${DEFAULT_ZLIB} 32383 fi 32384 32385 if test "x${with_zlib}" = "xbundled"; then 32386 USE_EXTERNAL_LIBZ=false 32387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 32388 $as_echo "bundled" >&6; } 32389 elif test "x${with_zlib}" = "xsystem"; then 32390 if test "x${ZLIB_FOUND}" = "xyes"; then 32391 USE_EXTERNAL_LIBZ=true 32392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 32393 $as_echo "system" >&6; } 32394 else 32395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 32396 $as_echo "system not found" >&6; } 32397 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 32398 fi 32399 else 32400 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 32401 fi 32402 32403 32404 32405 ############################################################################### 32406 LIBZIP_CAN_USE_MMAP=true 32407 32408 32409 32410 ############################################################################### 32411 # 32412 # Check if altzone exists in time.h 32413 # 32414 32415 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32416 /* end confdefs.h. */ 32417 #include <time.h> 32418 int 32419 main () 32420 { 32421 return (int)altzone; 32422 ; 32423 return 0; 32424 } 32425 _ACEOF 32426 if ac_fn_cxx_try_link "$LINENO"; then : 32427 has_altzone=yes 32428 else 32429 has_altzone=no 32430 fi 32431 rm -f core conftest.err conftest.$ac_objext \ 32432 conftest$ac_exeext conftest.$ac_ext 32433 if test "x$has_altzone" = xyes; then 32434 32435 $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h 32436 32437 fi 32438 32439 ############################################################################### 32440 # 32441 # Check the maths library 32442 # 32443 32444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 32445 $as_echo_n "checking for cos in -lm... " >&6; } 32446 if ${ac_cv_lib_m_cos+:} false; then : 32447 $as_echo_n "(cached) " >&6 32448 else 32449 ac_check_lib_save_LIBS=$LIBS 32450 LIBS="-lm $LIBS" 32451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32452 /* end confdefs.h. */ 32453 32454 /* Override any GCC internal prototype to avoid an error. 32455 Use char because int might match the return type of a GCC 32456 builtin and then its argument prototype would still apply. */ 32457 #ifdef __cplusplus 32458 extern "C" 32459 #endif 32460 char cos (); 32461 int 32462 main () 32463 { 32464 return cos (); 32465 ; 32466 return 0; 32467 } 32468 _ACEOF 32469 if ac_fn_cxx_try_link "$LINENO"; then : 32470 ac_cv_lib_m_cos=yes 32471 else 32472 ac_cv_lib_m_cos=no 32473 fi 32474 rm -f core conftest.err conftest.$ac_objext \ 32475 conftest$ac_exeext conftest.$ac_ext 32476 LIBS=$ac_check_lib_save_LIBS 32477 fi 32478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 32479 $as_echo "$ac_cv_lib_m_cos" >&6; } 32480 if test "x$ac_cv_lib_m_cos" = xyes; then : 32481 cat >>confdefs.h <<_ACEOF 32482 #define HAVE_LIBM 1 32483 _ACEOF 32484 32485 LIBS="-lm $LIBS" 32486 32487 else 32488 32489 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 32490 $as_echo "$as_me: Maths library was not found" >&6;} 32491 32492 fi 32493 32494 32495 32496 ############################################################################### 32497 # 32498 # Check for libdl.so 32499 32500 save_LIBS="$LIBS" 32501 LIBS="" 32502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 32503 $as_echo_n "checking for dlopen in -ldl... " >&6; } 32504 if ${ac_cv_lib_dl_dlopen+:} false; then : 32505 $as_echo_n "(cached) " >&6 32506 else 32507 ac_check_lib_save_LIBS=$LIBS 32508 LIBS="-ldl $LIBS" 32509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32510 /* end confdefs.h. */ 32511 32512 /* Override any GCC internal prototype to avoid an error. 32513 Use char because int might match the return type of a GCC 32514 builtin and then its argument prototype would still apply. */ 32515 #ifdef __cplusplus 32516 extern "C" 32517 #endif 32518 char dlopen (); 32519 int 32520 main () 32521 { 32522 return dlopen (); 32523 ; 32524 return 0; 32525 } 32526 _ACEOF 32527 if ac_fn_cxx_try_link "$LINENO"; then : 32528 ac_cv_lib_dl_dlopen=yes 32529 else 32530 ac_cv_lib_dl_dlopen=no 32531 fi 32532 rm -f core conftest.err conftest.$ac_objext \ 32533 conftest$ac_exeext conftest.$ac_ext 32534 LIBS=$ac_check_lib_save_LIBS 32535 fi 32536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 32537 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 32538 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 32539 cat >>confdefs.h <<_ACEOF 32540 #define HAVE_LIBDL 1 32541 _ACEOF 32542 32543 LIBS="-ldl $LIBS" 32544 32545 fi 32546 32547 LIBDL="$LIBS" 32548 32549 LIBS="$save_LIBS" 32550 32551 32552 32553 ############################################################################### 32554 # 32555 # statically link libstdc++ before C++ ABI is stablized on Linux unless 32556 # dynamic build is configured on command line. 32557 # 32558 32559 # Check whether --with-stdc++lib was given. 32560 if test "${with_stdc__lib+set}" = set; then : 32561 withval=$with_stdc__lib; 32562 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 32563 && test "x$with_stdc__lib" != xdefault; then 32564 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 32565 fi 32566 32567 else 32568 with_stdc__lib=default 32569 32570 fi 32571 32572 32573 if test "x$OPENJDK_TARGET_OS" = xlinux; then 32574 # Test if -lstdc++ works. 32575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5 32576 $as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; } 32577 ac_ext=cpp 32578 ac_cpp='$CXXCPP $CPPFLAGS' 32579 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32580 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32581 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32582 32583 OLD_CXXFLAGS="$CXXFLAGS" 32584 CXXFLAGS="$CXXFLAGS -lstdc++" 32585 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32586 /* end confdefs.h. */ 32587 32588 int 32589 main () 32590 { 32591 return 0; 32592 ; 32593 return 0; 32594 } 32595 _ACEOF 32596 if ac_fn_cxx_try_link "$LINENO"; then : 32597 has_dynamic_libstdcxx=yes 32598 else 32599 has_dynamic_libstdcxx=no 32600 fi 32601 rm -f core conftest.err conftest.$ac_objext \ 32602 conftest$ac_exeext conftest.$ac_ext 32603 CXXFLAGS="$OLD_CXXFLAGS" 32604 ac_ext=cpp 32605 ac_cpp='$CXXCPP $CPPFLAGS' 32606 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32607 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32608 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32609 32610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5 32611 $as_echo "$has_dynamic_libstdcxx" >&6; } 32612 32613 # Test if stdc++ can be linked statically. 32614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 32615 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 32616 STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic" 32617 ac_ext=cpp 32618 ac_cpp='$CXXCPP $CPPFLAGS' 32619 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32620 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32621 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32622 32623 OLD_LIBS="$LIBS" 32624 OLD_CXX="$CXX" 32625 LIBS="$STATIC_STDCXX_FLAGS" 32626 CXX="$CC" 32627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32628 /* end confdefs.h. */ 32629 32630 int 32631 main () 32632 { 32633 return 0; 32634 ; 32635 return 0; 32636 } 32637 _ACEOF 32638 if ac_fn_cxx_try_link "$LINENO"; then : 32639 has_static_libstdcxx=yes 32640 else 32641 has_static_libstdcxx=no 32642 fi 32643 rm -f core conftest.err conftest.$ac_objext \ 32644 conftest$ac_exeext conftest.$ac_ext 32645 LIBS="$OLD_LIBS" 32646 CXX="$OLD_CXX" 32647 ac_ext=cpp 32648 ac_cpp='$CXXCPP $CPPFLAGS' 32649 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32650 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32651 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32652 32653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 32654 $as_echo "$has_static_libstdcxx" >&6; } 32655 32656 if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then 32657 as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5 32658 fi 32659 32660 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 32661 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 32662 fi 32663 32664 if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then 32665 as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5 32666 fi 32667 32668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 32669 $as_echo_n "checking how to link with libstdc++... " >&6; } 32670 # If dynamic was requested, it's available since it would fail above otherwise. 32671 # If dynamic wasn't requested, go with static unless it isn't available. 32672 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 32673 LIBCXX="$LIBCXX -lstdc++" 32674 LDCXX="$CXX" 32675 STATIC_CXX_SETTING="STATIC_CXX=false" 32676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 32677 $as_echo "dynamic" >&6; } 32678 else 32679 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 32680 LDCXX="$CC" 32681 STATIC_CXX_SETTING="STATIC_CXX=true" 32682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 32683 $as_echo "static" >&6; } 32684 fi 32685 fi 32686 32687 32688 if test "x$JVM_VARIANT_ZERO" = xtrue || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 32689 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 32690 32691 pkg_failed=no 32692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 32693 $as_echo_n "checking for LIBFFI... " >&6; } 32694 32695 if test -n "$LIBFFI_CFLAGS"; then 32696 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 32697 elif test -n "$PKG_CONFIG"; then 32698 if test -n "$PKG_CONFIG" && \ 32699 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 32700 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 32701 ac_status=$? 32702 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32703 test $ac_status = 0; }; then 32704 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 32705 else 32706 pkg_failed=yes 32707 fi 32708 else 32709 pkg_failed=untried 32710 fi 32711 if test -n "$LIBFFI_LIBS"; then 32712 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 32713 elif test -n "$PKG_CONFIG"; then 32714 if test -n "$PKG_CONFIG" && \ 32715 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 32716 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 32717 ac_status=$? 32718 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32719 test $ac_status = 0; }; then 32720 pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 32721 else 32722 pkg_failed=yes 32723 fi 32724 else 32725 pkg_failed=untried 32726 fi 32727 32728 32729 32730 if test $pkg_failed = yes; then 32731 32732 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 32733 _pkg_short_errors_supported=yes 32734 else 32735 _pkg_short_errors_supported=no 32736 fi 32737 if test $_pkg_short_errors_supported = yes; then 32738 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 32739 else 32740 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 32741 fi 32742 # Put the nasty error message in config.log where it belongs 32743 echo "$LIBFFI_PKG_ERRORS" >&5 32744 32745 as_fn_error $? "Package requirements (libffi) were not met: 32746 32747 $LIBFFI_PKG_ERRORS 32748 32749 Consider adjusting the PKG_CONFIG_PATH environment variable if you 32750 installed software in a non-standard prefix. 32751 32752 Alternatively, you may set the environment variables LIBFFI_CFLAGS 32753 and LIBFFI_LIBS to avoid the need to call pkg-config. 32754 See the pkg-config man page for more details. 32755 " "$LINENO" 5 32756 elif test $pkg_failed = untried; then 32757 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 32758 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 32759 as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it 32760 is in your PATH or set the PKG_CONFIG environment variable to the full 32761 path to pkg-config. 32762 32763 Alternatively, you may set the environment variables LIBFFI_CFLAGS 32764 and LIBFFI_LIBS to avoid the need to call pkg-config. 32765 See the pkg-config man page for more details. 32766 32767 To get pkg-config, see <http://pkg-config.freedesktop.org/>. 32768 See \`config.log' for more details" "$LINENO" 5; } 32769 else 32770 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 32771 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 32772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32773 $as_echo "yes" >&6; } 32774 : 32775 fi 32776 32777 fi 32778 32779 if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 32780 # Extract the first word of "llvm-config", so it can be a program name with args. 32781 set dummy llvm-config; ac_word=$2 32782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 32783 $as_echo_n "checking for $ac_word... " >&6; } 32784 if ${ac_cv_prog_LLVM_CONFIG+:} false; then : 32785 $as_echo_n "(cached) " >&6 32786 else 32787 if test -n "$LLVM_CONFIG"; then 32788 ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test. 32789 else 32790 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 32791 for as_dir in $PATH 32792 do 32793 IFS=$as_save_IFS 32794 test -z "$as_dir" && as_dir=. 32795 for ac_exec_ext in '' $ac_executable_extensions; do 32796 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 32797 ac_cv_prog_LLVM_CONFIG="llvm-config" 32798 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 32799 break 2 32800 fi 32801 done 32802 done 32803 IFS=$as_save_IFS 32804 32805 fi 32806 fi 32807 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG 32808 if test -n "$LLVM_CONFIG"; then 32809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 32810 $as_echo "$LLVM_CONFIG" >&6; } 32811 else 32812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32813 $as_echo "no" >&6; } 32814 fi 32815 32816 32817 32818 if test "x$LLVM_CONFIG" != xllvm-config; then 32819 as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5 32820 fi 32821 32822 llvm_components="jit mcjit engine nativecodegen native" 32823 unset LLVM_CFLAGS 32824 for flag in $("$LLVM_CONFIG" --cxxflags); do 32825 if echo "${flag}" | grep -q '^-[ID]'; then 32826 if test "${flag}" != "-D_DEBUG" ; then 32827 if test "${LLVM_CFLAGS}" != "" ; then 32828 LLVM_CFLAGS="${LLVM_CFLAGS} " 32829 fi 32830 LLVM_CFLAGS="${LLVM_CFLAGS}${flag}" 32831 fi 32832 fi 32833 done 32834 llvm_version=$("${LLVM_CONFIG}" --version | sed 's/\.//; s/svn.*//') 32835 LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}" 32836 32837 unset LLVM_LDFLAGS 32838 for flag in $("${LLVM_CONFIG}" --ldflags); do 32839 if echo "${flag}" | grep -q '^-L'; then 32840 if test "${LLVM_LDFLAGS}" != ""; then 32841 LLVM_LDFLAGS="${LLVM_LDFLAGS} " 32842 fi 32843 LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}" 32844 fi 32845 done 32846 32847 unset LLVM_LIBS 32848 for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do 32849 if echo "${flag}" | grep -q '^-l'; then 32850 if test "${LLVM_LIBS}" != ""; then 32851 LLVM_LIBS="${LLVM_LIBS} " 32852 fi 32853 LLVM_LIBS="${LLVM_LIBS}${flag}" 32854 fi 32855 done 32856 32857 32858 32859 32860 fi 32861 32862 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 32863 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$LIBCXX" = x; then 32864 LIBCXX="/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 32865 fi 32866 32867 # TODO better (platform agnostic) test 32868 if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$GCC" = xyes; then 32869 LIBCXX="-lstdc++" 32870 fi 32871 32872 32873 32874 32875 32876 # After we have toolchain and the paths to all libraries (needed by msys), we can compile the fixpath helper 32877 32878 # When using cygwin or msys, we need a wrapper binary that renames 32879 # /cygdrive/c/ arguments into c:/ arguments and peeks into 32880 # @files and rewrites these too! This wrapper binary is 32881 # called fixpath. 32882 FIXPATH= 32883 if test "x$OPENJDK_BUILD_OS" = xwindows; then 32884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 32885 $as_echo_n "checking if fixpath can be created... " >&6; } 32886 FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c" 32887 FIXPATH_BIN="$OUTPUT_ROOT/fixpath.exe" 32888 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 32889 FIXPATH_SRC=`$CYGPATH -m $FIXPATH_SRC` 32890 FIXPATH_BIN=`$CYGPATH -m $FIXPATH_BIN` 32891 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 32892 FIXPATH="$OUTPUT_ROOT/fixpath.exe -c" 32893 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 32894 FIXPATH_SRC=`cmd //c echo $FIXPATH_SRC` 32895 FIXPATH_BIN=`cmd //c echo $FIXPATH_BIN` 32896 32897 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 32898 # @ was chosen as separator to minimize risk of other tools messing around with it 32899 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" | tr ' ' '\n' | grep '^/./' | sort | uniq` 32900 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 32901 32902 FIXPATH="$OUTPUT_ROOT/fixpath -m$fixpath_argument_list" 32903 fi 32904 rm -f $OUTPUT_ROOT/fixpath* 32905 cd $OUTPUT_ROOT 32906 $CC $FIXPATH_SRC -Fe$FIXPATH_BIN > $OUTPUT_ROOT/fixpath1.log 2>&1 32907 cd $CURDIR 32908 32909 if test ! -x $OUTPUT_ROOT/fixpath.exe; then 32910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32911 $as_echo "no" >&6; } 32912 cat $OUTPUT_ROOT/fixpath1.log 32913 as_fn_error $? "Could not create $OUTPUT_ROOT/fixpath.exe" "$LINENO" 5 32914 fi 32915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32916 $as_echo "yes" >&6; } 32917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 32918 $as_echo_n "checking if fixpath.exe works... " >&6; } 32919 cd $OUTPUT_ROOT 32920 $FIXPATH $CC $SRC_ROOT/common/src/fixpath.c -Fe$OUTPUT_ROOT/fixpath2.exe > $OUTPUT_ROOT/fixpath2.log 2>&1 32921 cd $CURDIR 32922 if test ! -x $OUTPUT_ROOT/fixpath2.exe; then 32923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32924 $as_echo "no" >&6; } 32925 cat $OUTPUT_ROOT/fixpath2.log 32926 as_fn_error $? "fixpath did not work!" "$LINENO" 5 32927 fi 32928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32929 $as_echo "yes" >&6; } 32930 rm -f $OUTPUT_ROOT/fixpath?.??? $OUTPUT_ROOT/fixpath.obj 32931 fi 32932 32933 32934 32935 32936 ############################################################################### 32937 # 32938 # We need to do some final tweaking, when everything else is done. 32939 # 32940 ############################################################################### 32941 32942 32943 HOTSPOT_MAKE_ARGS="$HOTSPOT_TARGET" 32944 32945 32946 # The name of the Service Agent jar. 32947 SALIB_NAME="${LIBRARY_PREFIX}saproc${SHARED_LIBRARY_SUFFIX}" 32948 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 32949 SALIB_NAME="${LIBRARY_PREFIX}sawindbg${SHARED_LIBRARY_SUFFIX}" 32950 fi 32951 32952 32953 32954 32955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 32956 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 32957 32958 if test -d "${SRC_ROOT}/jdk/src/share/native/sun/security/ec/impl"; then 32959 ENABLE_INTREE_EC=yes 32960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32961 $as_echo "yes" >&6; } 32962 else 32963 ENABLE_INTREE_EC=no 32964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32965 $as_echo "no" >&6; } 32966 fi 32967 32968 32969 32970 32971 ############################################################################### 32972 # 32973 # Configure parts of the build that only affect the build performance, 32974 # not the result. 32975 # 32976 ############################################################################### 32977 32978 32979 # How many cores do we have on this build system? 32980 32981 # Check whether --with-num-cores was given. 32982 if test "${with_num_cores+set}" = set; then : 32983 withval=$with_num_cores; 32984 fi 32985 32986 if test "x$with_num_cores" = x; then 32987 # The number of cores were not specified, try to probe them. 32988 32989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 32990 $as_echo_n "checking for number of cores... " >&6; } 32991 NUM_CORES=1 32992 FOUND_CORES=no 32993 32994 if test -f /proc/cpuinfo; then 32995 # Looks like a Linux (or cygwin) system 32996 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 32997 FOUND_CORES=yes 32998 elif test -x /usr/sbin/psrinfo; then 32999 # Looks like a Solaris system 33000 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 33001 FOUND_CORES=yes 33002 elif test -x /usr/sbin/system_profiler; then 33003 # Looks like a MacOSX system 33004 NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk '{print $5}'` 33005 FOUND_CORES=yes 33006 elif test -n "$NUMBER_OF_PROCESSORS"; then 33007 # On windows, look in the env 33008 NUM_CORES=$NUMBER_OF_PROCESSORS 33009 FOUND_CORES=yes 33010 fi 33011 33012 if test "x$FOUND_CORES" = xyes; then 33013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 33014 $as_echo "$NUM_CORES" >&6; } 33015 else 33016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 33017 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 33018 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 33019 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 33020 fi 33021 33022 33023 else 33024 NUM_CORES=$with_num_cores 33025 fi 33026 33027 33028 33029 # How much memory do we have on this build system? 33030 33031 # Check whether --with-memory-size was given. 33032 if test "${with_memory_size+set}" = set; then : 33033 withval=$with_memory_size; 33034 fi 33035 33036 if test "x$with_memory_size" = x; then 33037 # The memory size was not specified, try to probe it. 33038 33039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 33040 $as_echo_n "checking for memory size... " >&6; } 33041 # Default to 1024 MB 33042 MEMORY_SIZE=1024 33043 FOUND_MEM=no 33044 33045 if test -f /proc/meminfo; then 33046 # Looks like a Linux (or cygwin) system 33047 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 33048 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 33049 FOUND_MEM=yes 33050 elif test -x /usr/sbin/prtconf; then 33051 # Looks like a Solaris system 33052 MEMORY_SIZE=`/usr/sbin/prtconf | grep "Memory size" | awk '{ print $3 }'` 33053 FOUND_MEM=yes 33054 elif test -x /usr/sbin/system_profiler; then 33055 # Looks like a MacOSX system 33056 MEMORY_SIZE=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Memory' | awk '{print $2}'` 33057 MEMORY_SIZE=`expr $MEMORY_SIZE \* 1024` 33058 FOUND_MEM=yes 33059 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 33060 # Windows, but without cygwin 33061 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 33062 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 33063 FOUND_MEM=yes 33064 fi 33065 33066 if test "x$FOUND_MEM" = xyes; then 33067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 33068 $as_echo "$MEMORY_SIZE MB" >&6; } 33069 else 33070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to 1024 MB" >&5 33071 $as_echo "could not detect memory size, defaulting to 1024 MB" >&6; } 33072 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 33073 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 33074 fi 33075 33076 else 33077 MEMORY_SIZE=$with_memory_size 33078 fi 33079 33080 33081 33082 # Provide a decent default number of parallel jobs for make depending on 33083 # number of cores, amount of memory and machine architecture. 33084 33085 # Check whether --with-jobs was given. 33086 if test "${with_jobs+set}" = set; then : 33087 withval=$with_jobs; 33088 fi 33089 33090 if test "x$with_jobs" = x; then 33091 # Number of jobs was not specified, calculate. 33092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 33093 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 33094 # Approximate memory in GB, rounding up a bit. 33095 memory_gb=`expr $MEMORY_SIZE / 1100` 33096 # Pick the lowest of memory in gb and number of cores. 33097 if test "$memory_gb" -lt "$NUM_CORES"; then 33098 JOBS="$memory_gb" 33099 else 33100 JOBS="$NUM_CORES" 33101 # On bigger machines, leave some room for other processes to run 33102 if test "$JOBS" -gt "4"; then 33103 JOBS=`expr $JOBS '*' 90 / 100` 33104 fi 33105 fi 33106 # Cap number of jobs to 16 33107 if test "$JOBS" -gt "16"; then 33108 JOBS=16 33109 fi 33110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 33111 $as_echo "$JOBS" >&6; } 33112 else 33113 JOBS=$with_jobs 33114 fi 33115 33116 33117 33118 # Setup smart javac (after cores and memory have been setup) 33119 33120 33121 # Check whether --with-sjavac-server-java was given. 33122 if test "${with_sjavac_server_java+set}" = set; then : 33123 withval=$with_sjavac_server_java; 33124 fi 33125 33126 33127 if test "x$with_sjavac_server_java" != x; then 33128 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 33129 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 33130 if test "x$FOUND_VERSION" = x; then 33131 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 33132 fi 33133 else 33134 SJAVAC_SERVER_JAVA="" 33135 # Hotspot specific options. 33136 33137 # Test if -verbosegc is a valid argument to $JAVA (often is $JAVA passed as $JAVA) 33138 # If so, then append -verbosegc to SJAVAC_SERVER_JAVA 33139 FOUND_WARN=`$JAVA -verbosegc -version 2>&1 | grep -i warn` 33140 FOUND_VERSION=`$JAVA -verbosegc -version 2>&1 | grep " version \""` 33141 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33142 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -verbosegc" 33143 fi 33144 33145 # JRockit specific options. 33146 33147 # Test if -Xverbose:gc is a valid argument to $JAVA (often is $JAVA passed as $JAVA) 33148 # If so, then append -Xverbose:gc to SJAVAC_SERVER_JAVA 33149 FOUND_WARN=`$JAVA -Xverbose:gc -version 2>&1 | grep -i warn` 33150 FOUND_VERSION=`$JAVA -Xverbose:gc -version 2>&1 | grep " version \""` 33151 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33152 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xverbose:gc" 33153 fi 33154 33155 SJAVAC_SERVER_JAVA="$JAVA $SJAVAC_SERVER_JAVA" 33156 fi 33157 33158 33159 33160 # Check whether --with-sjavac-server-cores was given. 33161 if test "${with_sjavac_server_cores+set}" = set; then : 33162 withval=$with_sjavac_server_cores; 33163 fi 33164 33165 if test "x$with_sjavac_server_cores" != x; then 33166 SJAVAC_SERVER_CORES="$with_sjavac_server_cores" 33167 else 33168 if test "$NUM_CORES" -gt 16; then 33169 # We set this arbitrary limit because we want to limit the heap 33170 # size of the javac server. 33171 # In the future we will make the javac compilers in the server 33172 # share more and more state, thus enabling us to use more and 33173 # more concurrent threads in the server. 33174 SJAVAC_SERVER_CORES="16" 33175 else 33176 SJAVAC_SERVER_CORES="$NUM_CORES" 33177 fi 33178 33179 if test "$MEMORY_SIZE" -gt "17000"; then 33180 MAX_HEAP_MEM=10000 33181 33182 # Test if -d64 is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33183 # If so, then append -d64 to SJAVAC_SERVER_JAVA 33184 FOUND_WARN=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1 | grep -i warn` 33185 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1 | grep " version \""` 33186 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33187 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -d64" 33188 fi 33189 33190 33191 # Test if -Xms10G -Xmx10G is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33192 # If so, then append -Xms10G -Xmx10G to SJAVAC_SERVER_JAVA 33193 FOUND_WARN=`$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version 2>&1 | grep -i warn` 33194 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version 2>&1 | grep " version \""` 33195 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33196 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G" 33197 fi 33198 33199 elif test "$MEMORY_SIZE" -gt "10000"; then 33200 MAX_HEAP_MEM=6000 33201 33202 # Test if -d64 is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33203 # If so, then append -d64 to SJAVAC_SERVER_JAVA 33204 FOUND_WARN=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1 | grep -i warn` 33205 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1 | grep " version \""` 33206 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33207 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -d64" 33208 fi 33209 33210 33211 # Test if -Xms6G -Xmx6G is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33212 # If so, then append -Xms6G -Xmx6G to SJAVAC_SERVER_JAVA 33213 FOUND_WARN=`$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version 2>&1 | grep -i warn` 33214 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version 2>&1 | grep " version \""` 33215 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33216 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G" 33217 fi 33218 33219 elif test "$MEMORY_SIZE" -gt "5000"; then 33220 MAX_HEAP_MEM=3000 33221 33222 # Test if -d64 is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33223 # If so, then append -d64 to SJAVAC_SERVER_JAVA 33224 FOUND_WARN=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1 | grep -i warn` 33225 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1 | grep " version \""` 33226 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33227 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -d64" 33228 fi 33229 33230 33231 # Test if -Xms1G -Xmx3G is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33232 # If so, then append -Xms1G -Xmx3G to SJAVAC_SERVER_JAVA 33233 FOUND_WARN=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version 2>&1 | grep -i warn` 33234 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version 2>&1 | grep " version \""` 33235 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33236 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G" 33237 fi 33238 33239 elif test "$MEMORY_SIZE" -gt "3800"; then 33240 MAX_HEAP_MEM=2500 33241 33242 # Test if -Xms1G -Xmx2500M is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33243 # If so, then append -Xms1G -Xmx2500M to SJAVAC_SERVER_JAVA 33244 FOUND_WARN=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version 2>&1 | grep -i warn` 33245 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version 2>&1 | grep " version \""` 33246 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33247 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M" 33248 fi 33249 33250 elif test "$MEMORY_SIZE" -gt "1900"; then 33251 MAX_HEAP_MEM=1200 33252 33253 # Test if -Xms700M -Xmx1400M is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33254 # If so, then append -Xms700M -Xmx1400M to SJAVAC_SERVER_JAVA 33255 FOUND_WARN=`$SJAVAC_SERVER_JAVA -Xms700M -Xmx1400M -version 2>&1 | grep -i warn` 33256 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -Xms700M -Xmx1400M -version 2>&1 | grep " version \""` 33257 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33258 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms700M -Xmx1400M" 33259 fi 33260 33261 elif test "$MEMORY_SIZE" -gt "1000"; then 33262 MAX_HEAP_MEM=900 33263 33264 # Test if -Xms400M -Xmx1100M is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33265 # If so, then append -Xms400M -Xmx1100M to SJAVAC_SERVER_JAVA 33266 FOUND_WARN=`$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version 2>&1 | grep -i warn` 33267 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version 2>&1 | grep " version \""` 33268 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33269 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M" 33270 fi 33271 33272 else 33273 MAX_HEAP_MEM=512 33274 33275 # Test if -Xms256M -Xmx512M is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33276 # If so, then append -Xms256M -Xmx512M to SJAVAC_SERVER_JAVA 33277 FOUND_WARN=`$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version 2>&1 | grep -i warn` 33278 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version 2>&1 | grep " version \""` 33279 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33280 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M" 33281 fi 33282 33283 fi 33284 33285 33286 # Test if -XX:PermSize=32m is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33287 # If so, then append -XX:PermSize=32m to SJAVAC_SERVER_JAVA 33288 FOUND_WARN=`$SJAVAC_SERVER_JAVA -XX:PermSize=32m -version 2>&1 | grep -i warn` 33289 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -XX:PermSize=32m -version 2>&1 | grep " version \""` 33290 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33291 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -XX:PermSize=32m" 33292 fi 33293 33294 33295 # Test if -XX:MaxPermSize=160m is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33296 # If so, then append -XX:MaxPermSize=160m to SJAVAC_SERVER_JAVA 33297 FOUND_WARN=`$SJAVAC_SERVER_JAVA -XX:MaxPermSize=160m -version 2>&1 | grep -i warn` 33298 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -XX:MaxPermSize=160m -version 2>&1 | grep " version \""` 33299 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33300 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -XX:MaxPermSize=160m" 33301 fi 33302 33303 33304 # Test if -XX:ThreadStackSize=$STACK_SIZE is a valid argument to $SJAVAC_SERVER_JAVA (often is $JAVA passed as $SJAVAC_SERVER_JAVA) 33305 # If so, then append -XX:ThreadStackSize=$STACK_SIZE to SJAVAC_SERVER_JAVA 33306 FOUND_WARN=`$SJAVAC_SERVER_JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1 | grep -i warn` 33307 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1 | grep " version \""` 33308 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33309 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -XX:ThreadStackSize=$STACK_SIZE" 33310 fi 33311 33312 33313 MAX_COMPILERS_IN_HEAP=`expr $MAX_HEAP_MEM / 501` 33314 if test "$SJAVAC_SERVER_CORES" -gt "$MAX_COMPILERS_IN_HEAP"; then 33315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if number of server cores must be reduced" >&5 33316 $as_echo_n "checking if number of server cores must be reduced... " >&6; } 33317 SJAVAC_SERVER_CORES="$MAX_COMPILERS_IN_HEAP" 33318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, to $SJAVAC_SERVER_CORES with max heap size $MAX_HEAP_MEM MB" >&5 33319 $as_echo "yes, to $SJAVAC_SERVER_CORES with max heap size $MAX_HEAP_MEM MB" >&6; } 33320 fi 33321 fi 33322 33323 33324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 33325 $as_echo_n "checking whether to use sjavac... " >&6; } 33326 # Check whether --enable-sjavac was given. 33327 if test "${enable_sjavac+set}" = set; then : 33328 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 33329 else 33330 ENABLE_SJAVAC='no' 33331 fi 33332 33333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 33334 $as_echo "$ENABLE_SJAVAC" >&6; } 33335 33336 33337 if test "x$ENABLE_SJAVAC" = xyes; then 33338 SJAVAC_SERVER_DIR="$OUTPUT_ROOT/javacservers" 33339 else 33340 SJAVAC_SERVER_DIR= 33341 fi 33342 33343 33344 33345 33346 # Can the C/C++ compiler use precompiled headers? 33347 33348 33349 ############################################################################### 33350 # 33351 # Can the C/C++ compiler use precompiled headers? 33352 # 33353 # Check whether --enable-precompiled-headers was given. 33354 if test "${enable_precompiled_headers+set}" = set; then : 33355 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 33356 else 33357 ENABLE_PRECOMPH=yes 33358 fi 33359 33360 33361 USE_PRECOMPILED_HEADER=1 33362 if test "x$ENABLE_PRECOMPH" = xno; then 33363 USE_PRECOMPILED_HEADER=0 33364 fi 33365 33366 if test "x$ENABLE_PRECOMPH" = xyes; then 33367 # Check that the compiler actually supports precomp headers. 33368 if test "x$GCC" = xyes; then 33369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 33370 $as_echo_n "checking that precompiled headers work... " >&6; } 33371 echo "int alfa();" > conftest.h 33372 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 33373 if test ! -f conftest.hpp.gch; then 33374 USE_PRECOMPILED_HEADER=0 33375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33376 $as_echo "no" >&6; } 33377 else 33378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 33379 $as_echo "yes" >&6; } 33380 fi 33381 rm -f conftest.h conftest.hpp.gch 33382 fi 33383 fi 33384 33385 33386 33387 33388 # Setup use of ccache, if available 33389 33390 # Check whether --enable-ccache was given. 33391 if test "${enable_ccache+set}" = set; then : 33392 enableval=$enable_ccache; ENABLE_CCACHE=${enable_ccache} 33393 else 33394 ENABLE_CCACHE=yes 33395 fi 33396 33397 if test "x$ENABLE_CCACHE" = xyes; then 33398 # Extract the first word of "ccache", so it can be a program name with args. 33399 set dummy ccache; ac_word=$2 33400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33401 $as_echo_n "checking for $ac_word... " >&6; } 33402 if ${ac_cv_path_CCACHE+:} false; then : 33403 $as_echo_n "(cached) " >&6 33404 else 33405 case $CCACHE in 33406 [\\/]* | ?:[\\/]*) 33407 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 33408 ;; 33409 *) 33410 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33411 for as_dir in $PATH 33412 do 33413 IFS=$as_save_IFS 33414 test -z "$as_dir" && as_dir=. 33415 for ac_exec_ext in '' $ac_executable_extensions; do 33416 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 33417 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 33418 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33419 break 2 33420 fi 33421 done 33422 done 33423 IFS=$as_save_IFS 33424 33425 ;; 33426 esac 33427 fi 33428 CCACHE=$ac_cv_path_CCACHE 33429 if test -n "$CCACHE"; then 33430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 33431 $as_echo "$CCACHE" >&6; } 33432 else 33433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33434 $as_echo "no" >&6; } 33435 fi 33436 33437 33438 else 33439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ccache" >&5 33440 $as_echo_n "checking for ccache... " >&6; } 33441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: explicitly disabled" >&5 33442 $as_echo "explicitly disabled" >&6; } 33443 CCACHE= 33444 fi 33445 33446 33447 33448 # Check whether --with-ccache-dir was given. 33449 if test "${with_ccache_dir+set}" = set; then : 33450 withval=$with_ccache_dir; 33451 fi 33452 33453 33454 if test "x$with_ccache_dir" != x; then 33455 # When using a non home ccache directory, assume the use is to share ccache files 33456 # with other users. Thus change the umask. 33457 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 33458 fi 33459 CCACHE_FOUND="" 33460 if test "x$CCACHE" != x; then 33461 33462 if test "x$CCACHE" != x; then 33463 CCACHE_FOUND="true" 33464 # Only use ccache if it is 3.1.4 or later, which supports 33465 # precompiled headers. 33466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ccache supports precompiled headers" >&5 33467 $as_echo_n "checking if ccache supports precompiled headers... " >&6; } 33468 HAS_GOOD_CCACHE=`($CCACHE --version | head -n 1 | grep -E 3.1.[456789]) 2> /dev/null` 33469 if test "x$HAS_GOOD_CCACHE" = x; then 33470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccache" >&5 33471 $as_echo "no, disabling ccache" >&6; } 33472 CCACHE= 33473 else 33474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 33475 $as_echo "yes" >&6; } 33476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 33477 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 33478 PUSHED_FLAGS="$CXXFLAGS" 33479 CXXFLAGS="-fpch-preprocess $CXXFLAGS" 33480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33481 /* end confdefs.h. */ 33482 33483 int 33484 main () 33485 { 33486 33487 ; 33488 return 0; 33489 } 33490 _ACEOF 33491 if ac_fn_cxx_try_compile "$LINENO"; then : 33492 CC_KNOWS_CCACHE_TRICK=yes 33493 else 33494 CC_KNOWS_CCACHE_TRICK=no 33495 fi 33496 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 33497 CXXFLAGS="$PUSHED_FLAGS" 33498 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 33499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 33500 $as_echo "yes" >&6; } 33501 else 33502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccaching of precompiled headers" >&5 33503 $as_echo "no, disabling ccaching of precompiled headers" >&6; } 33504 CCACHE= 33505 fi 33506 fi 33507 fi 33508 33509 if test "x$CCACHE" != x; then 33510 CCACHE_SLOPPINESS=time_macros 33511 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS $CCACHE" 33512 CCACHE_FLAGS=-fpch-preprocess 33513 33514 if test "x$SET_CCACHE_DIR" != x; then 33515 mkdir -p $CCACHE_DIR > /dev/null 2>&1 33516 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 33517 fi 33518 fi 33519 33520 fi 33521 33522 33523 ############################################################################### 33524 # 33525 # And now the finish... 33526 # 33527 ############################################################################### 33528 33529 # Check for some common pitfalls 33530 33531 if test x"$OPENJDK_BUILD_OS" = xwindows; then 33532 file_to_test="$SRC_ROOT/LICENSE" 33533 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 33534 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 33535 fi 33536 fi 33537 33538 33539 33540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 33541 $as_echo_n "checking if build directory is on local disk... " >&6; } 33542 33543 # df -l lists only local disks; if the given directory is not found then 33544 # a non-zero exit code is given 33545 if test "x$DF" = x; then 33546 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33547 # msys does not have df; use Windows "net use" instead. 33548 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 33549 if test "x$IS_NETWORK_DISK" = x; then 33550 OUTPUT_DIR_IS_LOCAL="yes" 33551 else 33552 OUTPUT_DIR_IS_LOCAL="no" 33553 fi 33554 else 33555 # No df here, say it's local 33556 OUTPUT_DIR_IS_LOCAL="yes" 33557 fi 33558 else 33559 if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then 33560 OUTPUT_DIR_IS_LOCAL="yes" 33561 else 33562 OUTPUT_DIR_IS_LOCAL="no" 33563 fi 33564 fi 33565 33566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 33567 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 33568 33569 33570 33571 # Check if the user has any old-style ALT_ variables set. 33572 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 33573 33574 # Before generating output files, test if they exist. If they do, this is a reconfigure. 33575 # Since we can't properly handle the dependencies for this, warn the user about the situation 33576 if test -e $OUTPUT_ROOT/spec.gmk; then 33577 IS_RECONFIGURE=yes 33578 else 33579 IS_RECONFIGURE=no 33580 fi 33581 33582 if test -e $SRC_ROOT/build/.hide-configure-performance-hints; then 33583 HIDE_PERFORMANCE_HINTS=yes 33584 else 33585 HIDE_PERFORMANCE_HINTS=no 33586 # Hide it the next time around... 33587 $TOUCH $SRC_ROOT/build/.hide-configure-performance-hints > /dev/null 2>&1 33588 fi 33589 33590 33591 33592 # At the end, call the custom hook. (Dummy macro if no custom sources available) 33593 33594 33595 # We're messing a bit with internal autoconf variables to put the config.status 33596 # in the output directory instead of the current directory. 33597 CONFIG_STATUS="$OUTPUT_ROOT/config.status" 33598 # Create the actual output files. Now the main work of configure is done. 33599 cat >confcache <<\_ACEOF 33600 # This file is a shell script that caches the results of configure 33601 # tests run on this system so they can be shared between configure 33602 # scripts and configure runs, see configure's option --config-cache. 33603 # It is not useful on other systems. If it contains results you don't 33604 # want to keep, you may remove or edit it. 33605 # 33606 # config.status only pays attention to the cache file if you give it 33607 # the --recheck option to rerun configure. 33608 # 33609 # `ac_cv_env_foo' variables (set or unset) will be overridden when 33610 # loading this file, other *unset* `ac_cv_foo' will be assigned the 33611 # following values. 33612 33613 _ACEOF 33614 33615 # The following way of writing the cache mishandles newlines in values, 33616 # but we know of no workaround that is simple, portable, and efficient. 33617 # So, we kill variables containing newlines. 33618 # Ultrix sh set writes to stderr and can't be redirected directly, 33619 # and sets the high bit in the cache file unless we assign to the vars. 33620 ( 33621 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 33622 eval ac_val=\$$ac_var 33623 case $ac_val in #( 33624 *${as_nl}*) 33625 case $ac_var in #( 33626 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 33627 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 33628 esac 33629 case $ac_var in #( 33630 _ | IFS | as_nl) ;; #( 33631 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 33632 *) { eval $ac_var=; unset $ac_var;} ;; 33633 esac ;; 33634 esac 33635 done 33636 33637 (set) 2>&1 | 33638 case $as_nl`(ac_space=' '; set) 2>&1` in #( 33639 *${as_nl}ac_space=\ *) 33640 # `set' does not quote correctly, so add quotes: double-quote 33641 # substitution turns \\\\ into \\, and sed turns \\ into \. 33642 sed -n \ 33643 "s/'/'\\\\''/g; 33644 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 33645 ;; #( 33646 *) 33647 # `set' quotes correctly as required by POSIX, so do not add quotes. 33648 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 33649 ;; 33650 esac | 33651 sort 33652 ) | 33653 sed ' 33654 /^ac_cv_env_/b end 33655 t clear 33656 :clear 33657 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 33658 t end 33659 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 33660 :end' >>confcache 33661 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 33662 if test -w "$cache_file"; then 33663 if test "x$cache_file" != "x/dev/null"; then 33664 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 33665 $as_echo "$as_me: updating cache $cache_file" >&6;} 33666 if test ! -f "$cache_file" || test -h "$cache_file"; then 33667 cat confcache >"$cache_file" 33668 else 33669 case $cache_file in #( 33670 */* | ?:*) 33671 mv -f confcache "$cache_file"$$ && 33672 mv -f "$cache_file"$$ "$cache_file" ;; #( 33673 *) 33674 mv -f confcache "$cache_file" ;; 33675 esac 33676 fi 33677 fi 33678 else 33679 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 33680 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 33681 fi 33682 fi 33683 rm -f confcache 33684 33685 test "x$prefix" = xNONE && prefix=$ac_default_prefix 33686 # Let make expand exec_prefix. 33687 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 33688 33689 DEFS=-DHAVE_CONFIG_H 33690 33691 ac_libobjs= 33692 ac_ltlibobjs= 33693 U= 33694 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 33695 # 1. Remove the extension, and $U if already installed. 33696 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 33697 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 33698 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 33699 # will be set to the directory where LIBOBJS objects are built. 33700 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 33701 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 33702 done 33703 LIBOBJS=$ac_libobjs 33704 33705 LTLIBOBJS=$ac_ltlibobjs 33706 33707 33708 33709 : "${CONFIG_STATUS=./config.status}" 33710 ac_write_fail=0 33711 ac_clean_files_save=$ac_clean_files 33712 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 33713 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 33714 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 33715 as_write_fail=0 33716 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 33717 #! $SHELL 33718 # Generated by $as_me. 33719 # Run this file to recreate the current configuration. 33720 # Compiler output produced by configure, useful for debugging 33721 # configure, is in config.log if it exists. 33722 33723 debug=false 33724 ac_cs_recheck=false 33725 ac_cs_silent=false 33726 33727 SHELL=\${CONFIG_SHELL-$SHELL} 33728 export SHELL 33729 _ASEOF 33730 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 33731 ## -------------------- ## 33732 ## M4sh Initialization. ## 33733 ## -------------------- ## 33734 33735 # Be more Bourne compatible 33736 DUALCASE=1; export DUALCASE # for MKS sh 33737 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 33738 emulate sh 33739 NULLCMD=: 33740 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 33741 # is contrary to our usage. Disable this feature. 33742 alias -g '${1+"$@"}'='"$@"' 33743 setopt NO_GLOB_SUBST 33744 else 33745 case `(set -o) 2>/dev/null` in #( 33746 *posix*) : 33747 set -o posix ;; #( 33748 *) : 33749 ;; 33750 esac 33751 fi 33752 33753 33754 as_nl=' 33755 ' 33756 export as_nl 33757 # Printing a long string crashes Solaris 7 /usr/bin/printf. 33758 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 33759 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 33760 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 33761 # Prefer a ksh shell builtin over an external printf program on Solaris, 33762 # but without wasting forks for bash or zsh. 33763 if test -z "$BASH_VERSION$ZSH_VERSION" \ 33764 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 33765 as_echo='print -r --' 33766 as_echo_n='print -rn --' 33767 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 33768 as_echo='printf %s\n' 33769 as_echo_n='printf %s' 33770 else 33771 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 33772 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 33773 as_echo_n='/usr/ucb/echo -n' 33774 else 33775 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 33776 as_echo_n_body='eval 33777 arg=$1; 33778 case $arg in #( 33779 *"$as_nl"*) 33780 expr "X$arg" : "X\\(.*\\)$as_nl"; 33781 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 33782 esac; 33783 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 33784 ' 33785 export as_echo_n_body 33786 as_echo_n='sh -c $as_echo_n_body as_echo' 33787 fi 33788 export as_echo_body 33789 as_echo='sh -c $as_echo_body as_echo' 33790 fi 33791 33792 # The user is always right. 33793 if test "${PATH_SEPARATOR+set}" != set; then 33794 PATH_SEPARATOR=: 33795 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 33796 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 33797 PATH_SEPARATOR=';' 33798 } 33799 fi 33800 33801 33802 # IFS 33803 # We need space, tab and new line, in precisely that order. Quoting is 33804 # there to prevent editors from complaining about space-tab. 33805 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 33806 # splitting by setting IFS to empty value.) 33807 IFS=" "" $as_nl" 33808 33809 # Find who we are. Look in the path if we contain no directory separator. 33810 as_myself= 33811 case $0 in #(( 33812 *[\\/]* ) as_myself=$0 ;; 33813 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33814 for as_dir in $PATH 33815 do 33816 IFS=$as_save_IFS 33817 test -z "$as_dir" && as_dir=. 33818 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 33819 done 33820 IFS=$as_save_IFS 33821 33822 ;; 33823 esac 33824 # We did not find ourselves, most probably we were run as `sh COMMAND' 33825 # in which case we are not to be found in the path. 33826 if test "x$as_myself" = x; then 33827 as_myself=$0 33828 fi 33829 if test ! -f "$as_myself"; then 33830 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 33831 exit 1 33832 fi 33833 33834 # Unset variables that we do not need and which cause bugs (e.g. in 33835 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 33836 # suppresses any "Segmentation fault" message there. '((' could 33837 # trigger a bug in pdksh 5.2.14. 33838 for as_var in BASH_ENV ENV MAIL MAILPATH 33839 do eval test x\${$as_var+set} = xset \ 33840 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 33841 done 33842 PS1='$ ' 33843 PS2='> ' 33844 PS4='+ ' 33845 33846 # NLS nuisances. 33847 LC_ALL=C 33848 export LC_ALL 33849 LANGUAGE=C 33850 export LANGUAGE 33851 33852 # CDPATH. 33853 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 33854 33855 33856 # as_fn_error STATUS ERROR [LINENO LOG_FD] 33857 # ---------------------------------------- 33858 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 33859 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 33860 # script with STATUS, using 1 if that was 0. 33861 as_fn_error () 33862 { 33863 as_status=$1; test $as_status -eq 0 && as_status=1 33864 if test "$4"; then 33865 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 33866 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 33867 fi 33868 $as_echo "$as_me: error: $2" >&2 33869 as_fn_exit $as_status 33870 } # as_fn_error 33871 33872 33873 # as_fn_set_status STATUS 33874 # ----------------------- 33875 # Set $? to STATUS, without forking. 33876 as_fn_set_status () 33877 { 33878 return $1 33879 } # as_fn_set_status 33880 33881 # as_fn_exit STATUS 33882 # ----------------- 33883 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 33884 as_fn_exit () 33885 { 33886 set +e 33887 as_fn_set_status $1 33888 exit $1 33889 } # as_fn_exit 33890 33891 # as_fn_unset VAR 33892 # --------------- 33893 # Portably unset VAR. 33894 as_fn_unset () 33895 { 33896 { eval $1=; unset $1;} 33897 } 33898 as_unset=as_fn_unset 33899 # as_fn_append VAR VALUE 33900 # ---------------------- 33901 # Append the text in VALUE to the end of the definition contained in VAR. Take 33902 # advantage of any shell optimizations that allow amortized linear growth over 33903 # repeated appends, instead of the typical quadratic growth present in naive 33904 # implementations. 33905 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 33906 eval 'as_fn_append () 33907 { 33908 eval $1+=\$2 33909 }' 33910 else 33911 as_fn_append () 33912 { 33913 eval $1=\$$1\$2 33914 } 33915 fi # as_fn_append 33916 33917 # as_fn_arith ARG... 33918 # ------------------ 33919 # Perform arithmetic evaluation on the ARGs, and store the result in the 33920 # global $as_val. Take advantage of shells that can avoid forks. The arguments 33921 # must be portable across $(()) and expr. 33922 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 33923 eval 'as_fn_arith () 33924 { 33925 as_val=$(( $* )) 33926 }' 33927 else 33928 as_fn_arith () 33929 { 33930 as_val=`expr "$@" || test $? -eq 1` 33931 } 33932 fi # as_fn_arith 33933 33934 33935 if expr a : '\(a\)' >/dev/null 2>&1 && 33936 test "X`expr 00001 : '.*\(...\)'`" = X001; then 33937 as_expr=expr 33938 else 33939 as_expr=false 33940 fi 33941 33942 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 33943 as_basename=basename 33944 else 33945 as_basename=false 33946 fi 33947 33948 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 33949 as_dirname=dirname 33950 else 33951 as_dirname=false 33952 fi 33953 33954 as_me=`$as_basename -- "$0" || 33955 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 33956 X"$0" : 'X\(//\)$' \| \ 33957 X"$0" : 'X\(/\)' \| . 2>/dev/null || 33958 $as_echo X/"$0" | 33959 sed '/^.*\/\([^/][^/]*\)\/*$/{ 33960 s//\1/ 33961 q 33962 } 33963 /^X\/\(\/\/\)$/{ 33964 s//\1/ 33965 q 33966 } 33967 /^X\/\(\/\).*/{ 33968 s//\1/ 33969 q 33970 } 33971 s/.*/./; q'` 33972 33973 # Avoid depending upon Character Ranges. 33974 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 33975 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 33976 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 33977 as_cr_digits='0123456789' 33978 as_cr_alnum=$as_cr_Letters$as_cr_digits 33979 33980 ECHO_C= ECHO_N= ECHO_T= 33981 case `echo -n x` in #((((( 33982 -n*) 33983 case `echo 'xy\c'` in 33984 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 33985 xy) ECHO_C='\c';; 33986 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 33987 ECHO_T=' ';; 33988 esac;; 33989 *) 33990 ECHO_N='-n';; 33991 esac 33992 33993 rm -f conf$$ conf$$.exe conf$$.file 33994 if test -d conf$$.dir; then 33995 rm -f conf$$.dir/conf$$.file 33996 else 33997 rm -f conf$$.dir 33998 mkdir conf$$.dir 2>/dev/null 33999 fi 34000 if (echo >conf$$.file) 2>/dev/null; then 34001 if ln -s conf$$.file conf$$ 2>/dev/null; then 34002 as_ln_s='ln -s' 34003 # ... but there are two gotchas: 34004 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 34005 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 34006 # In both cases, we have to default to `cp -p'. 34007 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 34008 as_ln_s='cp -p' 34009 elif ln conf$$.file conf$$ 2>/dev/null; then 34010 as_ln_s=ln 34011 else 34012 as_ln_s='cp -p' 34013 fi 34014 else 34015 as_ln_s='cp -p' 34016 fi 34017 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 34018 rmdir conf$$.dir 2>/dev/null 34019 34020 34021 # as_fn_mkdir_p 34022 # ------------- 34023 # Create "$as_dir" as a directory, including parents if necessary. 34024 as_fn_mkdir_p () 34025 { 34026 34027 case $as_dir in #( 34028 -*) as_dir=./$as_dir;; 34029 esac 34030 test -d "$as_dir" || eval $as_mkdir_p || { 34031 as_dirs= 34032 while :; do 34033 case $as_dir in #( 34034 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 34035 *) as_qdir=$as_dir;; 34036 esac 34037 as_dirs="'$as_qdir' $as_dirs" 34038 as_dir=`$as_dirname -- "$as_dir" || 34039 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 34040 X"$as_dir" : 'X\(//\)[^/]' \| \ 34041 X"$as_dir" : 'X\(//\)$' \| \ 34042 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 34043 $as_echo X"$as_dir" | 34044 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 34045 s//\1/ 34046 q 34047 } 34048 /^X\(\/\/\)[^/].*/{ 34049 s//\1/ 34050 q 34051 } 34052 /^X\(\/\/\)$/{ 34053 s//\1/ 34054 q 34055 } 34056 /^X\(\/\).*/{ 34057 s//\1/ 34058 q 34059 } 34060 s/.*/./; q'` 34061 test -d "$as_dir" && break 34062 done 34063 test -z "$as_dirs" || eval "mkdir $as_dirs" 34064 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 34065 34066 34067 } # as_fn_mkdir_p 34068 if mkdir -p . 2>/dev/null; then 34069 as_mkdir_p='mkdir -p "$as_dir"' 34070 else 34071 test -d ./-p && rmdir ./-p 34072 as_mkdir_p=false 34073 fi 34074 34075 if test -x / >/dev/null 2>&1; then 34076 as_test_x='test -x' 34077 else 34078 if ls -dL / >/dev/null 2>&1; then 34079 as_ls_L_option=L 34080 else 34081 as_ls_L_option= 34082 fi 34083 as_test_x=' 34084 eval sh -c '\'' 34085 if test -d "$1"; then 34086 test -d "$1/."; 34087 else 34088 case $1 in #( 34089 -*)set "./$1";; 34090 esac; 34091 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( 34092 ???[sx]*):;;*)false;;esac;fi 34093 '\'' sh 34094 ' 34095 fi 34096 as_executable_p=$as_test_x 34097 34098 # Sed expression to map a string onto a valid CPP name. 34099 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 34100 34101 # Sed expression to map a string onto a valid variable name. 34102 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 34103 34104 34105 exec 6>&1 34106 ## ----------------------------------- ## 34107 ## Main body of $CONFIG_STATUS script. ## 34108 ## ----------------------------------- ## 34109 _ASEOF 34110 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 34111 34112 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34113 # Save the log message, to keep $0 and so on meaningful, and to 34114 # report actual input values of CONFIG_FILES etc. instead of their 34115 # values after options handling. 34116 ac_log=" 34117 This file was extended by OpenJDK $as_me jdk8, which was 34118 generated by GNU Autoconf 2.68. Invocation command line was 34119 34120 CONFIG_FILES = $CONFIG_FILES 34121 CONFIG_HEADERS = $CONFIG_HEADERS 34122 CONFIG_LINKS = $CONFIG_LINKS 34123 CONFIG_COMMANDS = $CONFIG_COMMANDS 34124 $ $0 $@ 34125 34126 on `(hostname || uname -n) 2>/dev/null | sed 1q` 34127 " 34128 34129 _ACEOF 34130 34131 case $ac_config_files in *" 34132 "*) set x $ac_config_files; shift; ac_config_files=$*;; 34133 esac 34134 34135 case $ac_config_headers in *" 34136 "*) set x $ac_config_headers; shift; ac_config_headers=$*;; 34137 esac 34138 34139 34140 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34141 # Files that config.status was made for. 34142 config_files="$ac_config_files" 34143 config_headers="$ac_config_headers" 34144 34145 _ACEOF 34146 34147 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34148 ac_cs_usage="\ 34149 \`$as_me' instantiates files and other configuration actions 34150 from templates according to the current configuration. Unless the files 34151 and actions are specified as TAGs, all are instantiated by default. 34152 34153 Usage: $0 [OPTION]... [TAG]... 34154 34155 -h, --help print this help, then exit 34156 -V, --version print version number and configuration settings, then exit 34157 --config print configuration, then exit 34158 -q, --quiet, --silent 34159 do not print progress messages 34160 -d, --debug don't remove temporary files 34161 --recheck update $as_me by reconfiguring in the same conditions 34162 --file=FILE[:TEMPLATE] 34163 instantiate the configuration file FILE 34164 --header=FILE[:TEMPLATE] 34165 instantiate the configuration header FILE 34166 34167 Configuration files: 34168 $config_files 34169 34170 Configuration headers: 34171 $config_headers 34172 34173 Report bugs to <build-dev@openjdk.java.net>. 34174 OpenJDK home page: <http://openjdk.java.net>." 34175 34176 _ACEOF 34177 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34178 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 34179 ac_cs_version="\\ 34180 OpenJDK config.status jdk8 34181 configured by $0, generated by GNU Autoconf 2.68, 34182 with options \\"\$ac_cs_config\\" 34183 34184 Copyright (C) 2010 Free Software Foundation, Inc. 34185 This config.status script is free software; the Free Software Foundation 34186 gives unlimited permission to copy, distribute and modify it." 34187 34188 ac_pwd='$ac_pwd' 34189 srcdir='$srcdir' 34190 AWK='$AWK' 34191 test -n "\$AWK" || AWK=awk 34192 _ACEOF 34193 34194 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34195 # The default lists apply if the user does not specify any file. 34196 ac_need_defaults=: 34197 while test $# != 0 34198 do 34199 case $1 in 34200 --*=?*) 34201 ac_option=`expr "X$1" : 'X\([^=]*\)='` 34202 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 34203 ac_shift=: 34204 ;; 34205 --*=) 34206 ac_option=`expr "X$1" : 'X\([^=]*\)='` 34207 ac_optarg= 34208 ac_shift=: 34209 ;; 34210 *) 34211 ac_option=$1 34212 ac_optarg=$2 34213 ac_shift=shift 34214 ;; 34215 esac 34216 34217 case $ac_option in 34218 # Handling of the options. 34219 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 34220 ac_cs_recheck=: ;; 34221 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 34222 $as_echo "$ac_cs_version"; exit ;; 34223 --config | --confi | --conf | --con | --co | --c ) 34224 $as_echo "$ac_cs_config"; exit ;; 34225 --debug | --debu | --deb | --de | --d | -d ) 34226 debug=: ;; 34227 --file | --fil | --fi | --f ) 34228 $ac_shift 34229 case $ac_optarg in 34230 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 34231 '') as_fn_error $? "missing file argument" ;; 34232 esac 34233 as_fn_append CONFIG_FILES " '$ac_optarg'" 34234 ac_need_defaults=false;; 34235 --header | --heade | --head | --hea ) 34236 $ac_shift 34237 case $ac_optarg in 34238 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 34239 esac 34240 as_fn_append CONFIG_HEADERS " '$ac_optarg'" 34241 ac_need_defaults=false;; 34242 --he | --h) 34243 # Conflict between --help and --header 34244 as_fn_error $? "ambiguous option: \`$1' 34245 Try \`$0 --help' for more information.";; 34246 --help | --hel | -h ) 34247 $as_echo "$ac_cs_usage"; exit ;; 34248 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 34249 | -silent | --silent | --silen | --sile | --sil | --si | --s) 34250 ac_cs_silent=: ;; 34251 34252 # This is an error. 34253 -*) as_fn_error $? "unrecognized option: \`$1' 34254 Try \`$0 --help' for more information." ;; 34255 34256 *) as_fn_append ac_config_targets " $1" 34257 ac_need_defaults=false ;; 34258 34259 esac 34260 shift 34261 done 34262 34263 ac_configure_extra_args= 34264 34265 if $ac_cs_silent; then 34266 exec 6>/dev/null 34267 ac_configure_extra_args="$ac_configure_extra_args --silent" 34268 fi 34269 34270 _ACEOF 34271 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34272 if \$ac_cs_recheck; then 34273 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 34274 shift 34275 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 34276 CONFIG_SHELL='$SHELL' 34277 export CONFIG_SHELL 34278 exec "\$@" 34279 fi 34280 34281 _ACEOF 34282 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34283 exec 5>>config.log 34284 { 34285 echo 34286 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 34287 ## Running $as_me. ## 34288 _ASBOX 34289 $as_echo "$ac_log" 34290 } >&5 34291 34292 _ACEOF 34293 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34294 _ACEOF 34295 34296 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34297 34298 # Handling of arguments. 34299 for ac_config_target in $ac_config_targets 34300 do 34301 case $ac_config_target in 34302 "$OUTPUT_ROOT/config.h") CONFIG_HEADERS="$CONFIG_HEADERS $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in" ;; 34303 "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 34304 "$OUTPUT_ROOT/hotspot-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" ;; 34305 "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 34306 "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 34307 "$OUTPUT_ROOT/spec.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in" ;; 34308 "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 34309 34310 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 34311 esac 34312 done 34313 34314 34315 # If the user did not use the arguments to specify the items to instantiate, 34316 # then the envvar interface is used. Set only those that are not. 34317 # We use the long form for the default assignment because of an extremely 34318 # bizarre bug on SunOS 4.1.3. 34319 if $ac_need_defaults; then 34320 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 34321 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers 34322 fi 34323 34324 # Have a temporary directory for convenience. Make it in the build tree 34325 # simply because there is no reason against having it here, and in addition, 34326 # creating and moving files from /tmp can sometimes cause problems. 34327 # Hook for its removal unless debugging. 34328 # Note that there is a small window in which the directory will not be cleaned: 34329 # after its creation but before its name has been assigned to `$tmp'. 34330 $debug || 34331 { 34332 tmp= ac_tmp= 34333 trap 'exit_status=$? 34334 : "${ac_tmp:=$tmp}" 34335 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 34336 ' 0 34337 trap 'as_fn_exit 1' 1 2 13 15 34338 } 34339 # Create a (secure) tmp directory for tmp files. 34340 34341 { 34342 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 34343 test -d "$tmp" 34344 } || 34345 { 34346 tmp=./conf$$-$RANDOM 34347 (umask 077 && mkdir "$tmp") 34348 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 34349 ac_tmp=$tmp 34350 34351 # Set up the scripts for CONFIG_FILES section. 34352 # No need to generate them if there are no CONFIG_FILES. 34353 # This happens for instance with `./config.status config.h'. 34354 if test -n "$CONFIG_FILES"; then 34355 34356 34357 ac_cr=`echo X | tr X '\015'` 34358 # On cygwin, bash can eat \r inside `` if the user requested igncr. 34359 # But we know of no other shell where ac_cr would be empty at this 34360 # point, so we can use a bashism as a fallback. 34361 if test "x$ac_cr" = x; then 34362 eval ac_cr=\$\'\\r\' 34363 fi 34364 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 34365 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 34366 ac_cs_awk_cr='\\r' 34367 else 34368 ac_cs_awk_cr=$ac_cr 34369 fi 34370 34371 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 34372 _ACEOF 34373 34374 34375 { 34376 echo "cat >conf$$subs.awk <<_ACEOF" && 34377 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 34378 echo "_ACEOF" 34379 } >conf$$subs.sh || 34380 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 34381 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 34382 ac_delim='%!_!# ' 34383 for ac_last_try in false false false false false :; do 34384 . ./conf$$subs.sh || 34385 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 34386 34387 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 34388 if test $ac_delim_n = $ac_delim_num; then 34389 break 34390 elif $ac_last_try; then 34391 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 34392 else 34393 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 34394 fi 34395 done 34396 rm -f conf$$subs.sh 34397 34398 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34399 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 34400 _ACEOF 34401 sed -n ' 34402 h 34403 s/^/S["/; s/!.*/"]=/ 34404 p 34405 g 34406 s/^[^!]*!// 34407 :repl 34408 t repl 34409 s/'"$ac_delim"'$// 34410 t delim 34411 :nl 34412 h 34413 s/\(.\{148\}\)..*/\1/ 34414 t more1 34415 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 34416 p 34417 n 34418 b repl 34419 :more1 34420 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 34421 p 34422 g 34423 s/.\{148\}// 34424 t nl 34425 :delim 34426 h 34427 s/\(.\{148\}\)..*/\1/ 34428 t more2 34429 s/["\\]/\\&/g; s/^/"/; s/$/"/ 34430 p 34431 b 34432 :more2 34433 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 34434 p 34435 g 34436 s/.\{148\}// 34437 t delim 34438 ' <conf$$subs.awk | sed ' 34439 /^[^""]/{ 34440 N 34441 s/\n// 34442 } 34443 ' >>$CONFIG_STATUS || ac_write_fail=1 34444 rm -f conf$$subs.awk 34445 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34446 _ACAWK 34447 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 34448 for (key in S) S_is_set[key] = 1 34449 FS = "" 34450 34451 } 34452 { 34453 line = $ 0 34454 nfields = split(line, field, "@") 34455 substed = 0 34456 len = length(field[1]) 34457 for (i = 2; i < nfields; i++) { 34458 key = field[i] 34459 keylen = length(key) 34460 if (S_is_set[key]) { 34461 value = S[key] 34462 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 34463 len += length(value) + length(field[++i]) 34464 substed = 1 34465 } else 34466 len += 1 + keylen 34467 } 34468 34469 print line 34470 } 34471 34472 _ACAWK 34473 _ACEOF 34474 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34475 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 34476 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 34477 else 34478 cat 34479 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 34480 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 34481 _ACEOF 34482 34483 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 34484 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 34485 # trailing colons and then remove the whole line if VPATH becomes empty 34486 # (actually we leave an empty line to preserve line numbers). 34487 if test "x$srcdir" = x.; then 34488 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 34489 h 34490 s/// 34491 s/^/:/ 34492 s/[ ]*$/:/ 34493 s/:\$(srcdir):/:/g 34494 s/:\${srcdir}:/:/g 34495 s/:@srcdir@:/:/g 34496 s/^:*// 34497 s/:*$// 34498 x 34499 s/\(=[ ]*\).*/\1/ 34500 G 34501 s/\n// 34502 s/^[^=]*=[ ]*$// 34503 }' 34504 fi 34505 34506 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34507 fi # test -n "$CONFIG_FILES" 34508 34509 # Set up the scripts for CONFIG_HEADERS section. 34510 # No need to generate them if there are no CONFIG_HEADERS. 34511 # This happens for instance with `./config.status Makefile'. 34512 if test -n "$CONFIG_HEADERS"; then 34513 cat >"$ac_tmp/defines.awk" <<\_ACAWK || 34514 BEGIN { 34515 _ACEOF 34516 34517 # Transform confdefs.h into an awk script `defines.awk', embedded as 34518 # here-document in config.status, that substitutes the proper values into 34519 # config.h.in to produce config.h. 34520 34521 # Create a delimiter string that does not exist in confdefs.h, to ease 34522 # handling of long lines. 34523 ac_delim='%!_!# ' 34524 for ac_last_try in false false :; do 34525 ac_tt=`sed -n "/$ac_delim/p" confdefs.h` 34526 if test -z "$ac_tt"; then 34527 break 34528 elif $ac_last_try; then 34529 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 34530 else 34531 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 34532 fi 34533 done 34534 34535 # For the awk script, D is an array of macro values keyed by name, 34536 # likewise P contains macro parameters if any. Preserve backslash 34537 # newline sequences. 34538 34539 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* 34540 sed -n ' 34541 s/.\{148\}/&'"$ac_delim"'/g 34542 t rset 34543 :rset 34544 s/^[ ]*#[ ]*define[ ][ ]*/ / 34545 t def 34546 d 34547 :def 34548 s/\\$// 34549 t bsnl 34550 s/["\\]/\\&/g 34551 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ 34552 D["\1"]=" \3"/p 34553 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p 34554 d 34555 :bsnl 34556 s/["\\]/\\&/g 34557 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ 34558 D["\1"]=" \3\\\\\\n"\\/p 34559 t cont 34560 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p 34561 t cont 34562 d 34563 :cont 34564 n 34565 s/.\{148\}/&'"$ac_delim"'/g 34566 t clear 34567 :clear 34568 s/\\$// 34569 t bsnlc 34570 s/["\\]/\\&/g; s/^/"/; s/$/"/p 34571 d 34572 :bsnlc 34573 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p 34574 b cont 34575 ' <confdefs.h | sed ' 34576 s/'"$ac_delim"'/"\\\ 34577 "/g' >>$CONFIG_STATUS || ac_write_fail=1 34578 34579 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34580 for (key in D) D_is_set[key] = 1 34581 FS = "" 34582 } 34583 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { 34584 line = \$ 0 34585 split(line, arg, " ") 34586 if (arg[1] == "#") { 34587 defundef = arg[2] 34588 mac1 = arg[3] 34589 } else { 34590 defundef = substr(arg[1], 2) 34591 mac1 = arg[2] 34592 } 34593 split(mac1, mac2, "(") #) 34594 macro = mac2[1] 34595 prefix = substr(line, 1, index(line, defundef) - 1) 34596 if (D_is_set[macro]) { 34597 # Preserve the white space surrounding the "#". 34598 print prefix "define", macro P[macro] D[macro] 34599 next 34600 } else { 34601 # Replace #undef with comments. This is necessary, for example, 34602 # in the case of _POSIX_SOURCE, which is predefined and required 34603 # on some systems where configure will not decide to define it. 34604 if (defundef == "undef") { 34605 print "/*", prefix defundef, macro, "*/" 34606 next 34607 } 34608 } 34609 } 34610 { print } 34611 _ACAWK 34612 _ACEOF 34613 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34614 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 34615 fi # test -n "$CONFIG_HEADERS" 34616 34617 34618 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " 34619 shift 34620 for ac_tag 34621 do 34622 case $ac_tag in 34623 :[FHLC]) ac_mode=$ac_tag; continue;; 34624 esac 34625 case $ac_mode$ac_tag in 34626 :[FHL]*:*);; 34627 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 34628 :[FH]-) ac_tag=-:-;; 34629 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 34630 esac 34631 ac_save_IFS=$IFS 34632 IFS=: 34633 set x $ac_tag 34634 IFS=$ac_save_IFS 34635 shift 34636 ac_file=$1 34637 shift 34638 34639 case $ac_mode in 34640 :L) ac_source=$1;; 34641 :[FH]) 34642 ac_file_inputs= 34643 for ac_f 34644 do 34645 case $ac_f in 34646 -) ac_f="$ac_tmp/stdin";; 34647 *) # Look for the file first in the build tree, then in the source tree 34648 # (if the path is not absolute). The absolute path cannot be DOS-style, 34649 # because $ac_f cannot contain `:'. 34650 test -f "$ac_f" || 34651 case $ac_f in 34652 [\\/$]*) false;; 34653 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 34654 esac || 34655 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 34656 esac 34657 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 34658 as_fn_append ac_file_inputs " '$ac_f'" 34659 done 34660 34661 # Let's still pretend it is `configure' which instantiates (i.e., don't 34662 # use $as_me), people would be surprised to read: 34663 # /* config.h. Generated by config.status. */ 34664 configure_input='Generated from '` 34665 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 34666 `' by configure.' 34667 if test x"$ac_file" != x-; then 34668 configure_input="$ac_file. $configure_input" 34669 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 34670 $as_echo "$as_me: creating $ac_file" >&6;} 34671 fi 34672 # Neutralize special characters interpreted by sed in replacement strings. 34673 case $configure_input in #( 34674 *\&* | *\|* | *\\* ) 34675 ac_sed_conf_input=`$as_echo "$configure_input" | 34676 sed 's/[\\\\&|]/\\\\&/g'`;; #( 34677 *) ac_sed_conf_input=$configure_input;; 34678 esac 34679 34680 case $ac_tag in 34681 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 34682 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 34683 esac 34684 ;; 34685 esac 34686 34687 ac_dir=`$as_dirname -- "$ac_file" || 34688 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 34689 X"$ac_file" : 'X\(//\)[^/]' \| \ 34690 X"$ac_file" : 'X\(//\)$' \| \ 34691 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 34692 $as_echo X"$ac_file" | 34693 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 34694 s//\1/ 34695 q 34696 } 34697 /^X\(\/\/\)[^/].*/{ 34698 s//\1/ 34699 q 34700 } 34701 /^X\(\/\/\)$/{ 34702 s//\1/ 34703 q 34704 } 34705 /^X\(\/\).*/{ 34706 s//\1/ 34707 q 34708 } 34709 s/.*/./; q'` 34710 as_dir="$ac_dir"; as_fn_mkdir_p 34711 ac_builddir=. 34712 34713 case "$ac_dir" in 34714 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 34715 *) 34716 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 34717 # A ".." for each directory in $ac_dir_suffix. 34718 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 34719 case $ac_top_builddir_sub in 34720 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 34721 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 34722 esac ;; 34723 esac 34724 ac_abs_top_builddir=$ac_pwd 34725 ac_abs_builddir=$ac_pwd$ac_dir_suffix 34726 # for backward compatibility: 34727 ac_top_builddir=$ac_top_build_prefix 34728 34729 case $srcdir in 34730 .) # We are building in place. 34731 ac_srcdir=. 34732 ac_top_srcdir=$ac_top_builddir_sub 34733 ac_abs_top_srcdir=$ac_pwd ;; 34734 [\\/]* | ?:[\\/]* ) # Absolute name. 34735 ac_srcdir=$srcdir$ac_dir_suffix; 34736 ac_top_srcdir=$srcdir 34737 ac_abs_top_srcdir=$srcdir ;; 34738 *) # Relative name. 34739 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 34740 ac_top_srcdir=$ac_top_build_prefix$srcdir 34741 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 34742 esac 34743 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 34744 34745 34746 case $ac_mode in 34747 :F) 34748 # 34749 # CONFIG_FILE 34750 # 34751 34752 _ACEOF 34753 34754 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34755 # If the template does not know about datarootdir, expand it. 34756 # FIXME: This hack should be removed a few years after 2.60. 34757 ac_datarootdir_hack=; ac_datarootdir_seen= 34758 ac_sed_dataroot=' 34759 /datarootdir/ { 34760 p 34761 q 34762 } 34763 /@datadir@/p 34764 /@docdir@/p 34765 /@infodir@/p 34766 /@localedir@/p 34767 /@mandir@/p' 34768 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 34769 *datarootdir*) ac_datarootdir_seen=yes;; 34770 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 34771 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 34772 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 34773 _ACEOF 34774 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34775 ac_datarootdir_hack=' 34776 s&@datadir@&$datadir&g 34777 s&@docdir@&$docdir&g 34778 s&@infodir@&$infodir&g 34779 s&@localedir@&$localedir&g 34780 s&@mandir@&$mandir&g 34781 s&\\\${datarootdir}&$datarootdir&g' ;; 34782 esac 34783 _ACEOF 34784 34785 # Neutralize VPATH when `$srcdir' = `.'. 34786 # Shell code in configure.ac might set extrasub. 34787 # FIXME: do we really want to maintain this feature? 34788 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34789 ac_sed_extra="$ac_vpsub 34790 $extrasub 34791 _ACEOF 34792 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34793 :t 34794 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 34795 s|@configure_input@|$ac_sed_conf_input|;t t 34796 s&@top_builddir@&$ac_top_builddir_sub&;t t 34797 s&@top_build_prefix@&$ac_top_build_prefix&;t t 34798 s&@srcdir@&$ac_srcdir&;t t 34799 s&@abs_srcdir@&$ac_abs_srcdir&;t t 34800 s&@top_srcdir@&$ac_top_srcdir&;t t 34801 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 34802 s&@builddir@&$ac_builddir&;t t 34803 s&@abs_builddir@&$ac_abs_builddir&;t t 34804 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 34805 $ac_datarootdir_hack 34806 " 34807 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 34808 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 34809 34810 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 34811 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 34812 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 34813 "$ac_tmp/out"`; test -z "$ac_out"; } && 34814 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 34815 which seems to be undefined. Please make sure it is defined" >&5 34816 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 34817 which seems to be undefined. Please make sure it is defined" >&2;} 34818 34819 rm -f "$ac_tmp/stdin" 34820 case $ac_file in 34821 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 34822 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 34823 esac \ 34824 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 34825 ;; 34826 :H) 34827 # 34828 # CONFIG_HEADER 34829 # 34830 if test x"$ac_file" != x-; then 34831 { 34832 $as_echo "/* $configure_input */" \ 34833 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" 34834 } >"$ac_tmp/config.h" \ 34835 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 34836 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then 34837 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 34838 $as_echo "$as_me: $ac_file is unchanged" >&6;} 34839 else 34840 rm -f "$ac_file" 34841 mv "$ac_tmp/config.h" "$ac_file" \ 34842 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 34843 fi 34844 else 34845 $as_echo "/* $configure_input */" \ 34846 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ 34847 || as_fn_error $? "could not create -" "$LINENO" 5 34848 fi 34849 ;; 34850 34851 34852 esac 34853 34854 done # for ac_tag 34855 34856 34857 as_fn_exit 0 34858 _ACEOF 34859 ac_clean_files=$ac_clean_files_save 34860 34861 test $ac_write_fail = 0 || 34862 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 34863 34864 34865 # configure is writing to config.log, and then calls config.status. 34866 # config.status does its own redirection, appending to config.log. 34867 # Unfortunately, on DOS this fails, as config.log is still kept open 34868 # by configure, so config.status won't be able to write to it; its 34869 # output is simply discarded. So we exec the FD to /dev/null, 34870 # effectively closing config.log, so it can be properly (re)opened and 34871 # appended to by config.status. When coming back to configure, we 34872 # need to make the FD available again. 34873 if test "$no_create" != yes; then 34874 ac_cs_success=: 34875 ac_config_status_args= 34876 test "$silent" = yes && 34877 ac_config_status_args="$ac_config_status_args --quiet" 34878 exec 5>/dev/null 34879 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 34880 exec 5>>config.log 34881 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 34882 # would make configure fail if this is the last instruction. 34883 $ac_cs_success || as_fn_exit 1 34884 fi 34885 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 34886 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 34887 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 34888 fi 34889 34890 34891 # Make the compare script executable 34892 $CHMOD +x $OUTPUT_ROOT/compare.sh 34893 34894 # Finally output some useful information to the user 34895 34896 # Finally output some useful information to the user 34897 34898 if test "x$CCACHE_FOUND" != x; then 34899 if test "x$HAS_GOOD_CCACHE" = x; then 34900 CCACHE_STATUS="installed, but disabled (version older than 3.1.4)" 34901 CCACHE_HELP_MSG="You have ccache installed, but it is a version prior to 3.1.4. Try upgrading." 34902 else 34903 CCACHE_STATUS="installed and in use" 34904 fi 34905 else 34906 if test "x$GCC" = xyes; then 34907 CCACHE_STATUS="not installed (consider installing)" 34908 CCACHE_HELP_MSG="You do not have ccache installed. Try installing it." 34909 else 34910 CCACHE_STATUS="not available for your system" 34911 fi 34912 fi 34913 34914 printf "\n" 34915 printf "====================================================\n" 34916 printf "A new configuration has been successfully created in\n" 34917 printf "$OUTPUT_ROOT\n" 34918 if test "x$CONFIGURE_COMMAND_LINE" != x; then 34919 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 34920 else 34921 printf "using default settings.\n" 34922 fi 34923 34924 printf "\n" 34925 printf "Configuration summary:\n" 34926 printf "* Debug level: $DEBUG_LEVEL\n" 34927 printf "* JDK variant: $JDK_VARIANT\n" 34928 printf "* JVM variants: $with_jvm_variants\n" 34929 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 34930 34931 printf "\n" 34932 printf "Tools summary:\n" 34933 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 34934 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 34935 fi 34936 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 34937 printf "* C Compiler: $CC_VENDOR version $CC_VERSION (at $CC)\n" 34938 printf "* C++ Compiler: $CXX_VENDOR version $CXX_VERSION (at $CXX)\n" 34939 34940 printf "\n" 34941 printf "Build performance summary:\n" 34942 printf "* Cores to use: $JOBS\n" 34943 printf "* Memory limit: $MEMORY_SIZE MB\n" 34944 printf "* ccache status: $CCACHE_STATUS\n" 34945 printf "\n" 34946 34947 if test "x$CCACHE_HELP_MSG" != x && test "x$HIDE_PERFORMANCE_HINTS" = "xno"; then 34948 printf "Build performance tip: ccache gives a tremendous speedup for C++ recompilations.\n" 34949 printf "$CCACHE_HELP_MSG\n" 34950 34951 # Print a helpful message on how to acquire the necessary build dependency. 34952 # ccache is the help tag: freetyp2, cups, pulse, alsa etc 34953 MISSING_DEPENDENCY=ccache 34954 PKGHANDLER_COMMAND= 34955 34956 case $PKGHANDLER in 34957 apt-get) 34958 apt_help $MISSING_DEPENDENCY ;; 34959 yum) 34960 yum_help $MISSING_DEPENDENCY ;; 34961 port) 34962 port_help $MISSING_DEPENDENCY ;; 34963 pkgutil) 34964 pkgutil_help $MISSING_DEPENDENCY ;; 34965 pkgadd) 34966 pkgadd_help $MISSING_DEPENDENCY ;; 34967 * ) 34968 break ;; 34969 esac 34970 34971 if test "x$PKGHANDLER_COMMAND" != x; then 34972 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 34973 fi 34974 34975 printf "$HELP_MSG\n" 34976 printf "\n" 34977 fi 34978 34979 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xyes"; then 34980 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 34981 printf "will result in longer build times.\n" 34982 printf "\n" 34983 fi 34984 34985 if test "x$FOUND_ALT_VARIABLES" != "x"; then 34986 printf "WARNING: You have old-style ALT_ environment variables set.\n" 34987 printf "These are not respected, and will be ignored. It is recommended\n" 34988 printf "that you clean your environment. The following variables are set:\n" 34989 printf "$FOUND_ALT_VARIABLES\n" 34990 printf "\n" 34991 fi 34992 34993 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 34994 printf "WARNING: Your build output directory is not on a local disk.\n" 34995 printf "This will severely degrade build performance!\n" 34996 printf "It is recommended that you create an output directory on a local disk,\n" 34997 printf "and run the configure script again from that directory.\n" 34998 printf "\n" 34999 fi 35000 35001 if test "x$IS_RECONFIGURE" = "xyes"; then 35002 printf "WARNING: The result of this configuration has overridden an older\n" 35003 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 35004 printf "proper build. Failure to do so might result in strange build problems.\n" 35005 printf "\n" 35006 fi 35007