1 #!/bin/bash 2 # 3 # ########################################################## 4 # ### THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. ### 5 # ########################################################## 6 # 7 #! /bin/sh 8 # Guess values for system-dependent variables and create Makefiles. 9 # Generated by GNU Autoconf 2.69 for OpenJDK jdk9. 10 # 11 # Report bugs to <build-dev@openjdk.java.net>. 12 # 13 # 14 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. 15 # 16 # 17 # This configure script is free software; the Free Software Foundation 18 # gives unlimited permission to copy, distribute and modify it. 19 ## -------------------- ## 20 ## M4sh Initialization. ## 21 ## -------------------- ## 22 23 # Be more Bourne compatible 24 DUALCASE=1; export DUALCASE # for MKS sh 25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 26 emulate sh 27 NULLCMD=: 28 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 29 # is contrary to our usage. Disable this feature. 30 alias -g '${1+"$@"}'='"$@"' 31 setopt NO_GLOB_SUBST 32 else 33 case `(set -o) 2>/dev/null` in #( 34 *posix*) : 35 set -o posix ;; #( 36 *) : 37 ;; 38 esac 39 fi 40 41 42 as_nl=' 43 ' 44 export as_nl 45 # Printing a long string crashes Solaris 7 /usr/bin/printf. 46 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 47 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 48 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 49 # Prefer a ksh shell builtin over an external printf program on Solaris, 50 # but without wasting forks for bash or zsh. 51 if test -z "$BASH_VERSION$ZSH_VERSION" \ 52 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 53 as_echo='print -r --' 54 as_echo_n='print -rn --' 55 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 56 as_echo='printf %s\n' 57 as_echo_n='printf %s' 58 else 59 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 60 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 61 as_echo_n='/usr/ucb/echo -n' 62 else 63 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 64 as_echo_n_body='eval 65 arg=$1; 66 case $arg in #( 67 *"$as_nl"*) 68 expr "X$arg" : "X\\(.*\\)$as_nl"; 69 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 70 esac; 71 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 72 ' 73 export as_echo_n_body 74 as_echo_n='sh -c $as_echo_n_body as_echo' 75 fi 76 export as_echo_body 77 as_echo='sh -c $as_echo_body as_echo' 78 fi 79 80 # The user is always right. 81 if test "${PATH_SEPARATOR+set}" != set; then 82 PATH_SEPARATOR=: 83 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 84 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 85 PATH_SEPARATOR=';' 86 } 87 fi 88 89 90 # IFS 91 # We need space, tab and new line, in precisely that order. Quoting is 92 # there to prevent editors from complaining about space-tab. 93 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 94 # splitting by setting IFS to empty value.) 95 IFS=" "" $as_nl" 96 97 # Find who we are. Look in the path if we contain no directory separator. 98 as_myself= 99 case $0 in #(( 100 *[\\/]* ) as_myself=$0 ;; 101 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 102 for as_dir in $PATH 103 do 104 IFS=$as_save_IFS 105 test -z "$as_dir" && as_dir=. 106 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 107 done 108 IFS=$as_save_IFS 109 110 ;; 111 esac 112 # We did not find ourselves, most probably we were run as `sh COMMAND' 113 # in which case we are not to be found in the path. 114 if test "x$as_myself" = x; then 115 as_myself=$0 116 fi 117 if test ! -f "$as_myself"; then 118 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 119 exit 1 120 fi 121 122 # Unset variables that we do not need and which cause bugs (e.g. in 123 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 124 # suppresses any "Segmentation fault" message there. '((' could 125 # trigger a bug in pdksh 5.2.14. 126 for as_var in BASH_ENV ENV MAIL MAILPATH 127 do eval test x\${$as_var+set} = xset \ 128 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 129 done 130 PS1='$ ' 131 PS2='> ' 132 PS4='+ ' 133 134 # NLS nuisances. 135 LC_ALL=C 136 export LC_ALL 137 LANGUAGE=C 138 export LANGUAGE 139 140 # CDPATH. 141 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 142 143 # Use a proper internal environment variable to ensure we don't fall 144 # into an infinite loop, continuously re-executing ourselves. 145 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then 146 _as_can_reexec=no; export _as_can_reexec; 147 # We cannot yet assume a decent shell, so we have to provide a 148 # neutralization value for shells without unset; and this also 149 # works around shells that cannot unset nonexistent variables. 150 # Preserve -v and -x to the replacement shell. 151 BASH_ENV=/dev/null 152 ENV=/dev/null 153 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 154 case $- in # (((( 155 *v*x* | *x*v* ) as_opts=-vx ;; 156 *v* ) as_opts=-v ;; 157 *x* ) as_opts=-x ;; 158 * ) as_opts= ;; 159 esac 160 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 161 # Admittedly, this is quite paranoid, since all the known shells bail 162 # out after a failed `exec'. 163 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 164 as_fn_exit 255 165 fi 166 # We don't want this to propagate to other subprocesses. 167 { _as_can_reexec=; unset _as_can_reexec;} 168 if test "x$CONFIG_SHELL" = x; then 169 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : 170 emulate sh 171 NULLCMD=: 172 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which 173 # is contrary to our usage. Disable this feature. 174 alias -g '\${1+\"\$@\"}'='\"\$@\"' 175 setopt NO_GLOB_SUBST 176 else 177 case \`(set -o) 2>/dev/null\` in #( 178 *posix*) : 179 set -o posix ;; #( 180 *) : 181 ;; 182 esac 183 fi 184 " 185 as_required="as_fn_return () { (exit \$1); } 186 as_fn_success () { as_fn_return 0; } 187 as_fn_failure () { as_fn_return 1; } 188 as_fn_ret_success () { return 0; } 189 as_fn_ret_failure () { return 1; } 190 191 exitcode=0 192 as_fn_success || { exitcode=1; echo as_fn_success failed.; } 193 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } 194 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } 195 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } 196 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : 197 198 else 199 exitcode=1; echo positional parameters were not saved. 200 fi 201 test x\$exitcode = x0 || exit 1 202 test -x / || exit 1" 203 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO 204 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO 205 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && 206 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 207 test \$(( 1 + 1 )) = 2 || exit 1" 208 if (eval "$as_required") 2>/dev/null; then : 209 as_have_required=yes 210 else 211 as_have_required=no 212 fi 213 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : 214 215 else 216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 217 as_found=false 218 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH 219 do 220 IFS=$as_save_IFS 221 test -z "$as_dir" && as_dir=. 222 as_found=: 223 case $as_dir in #( 224 /*) 225 for as_base in sh bash ksh sh5; do 226 # Try only shells that exist, to save several forks. 227 as_shell=$as_dir/$as_base 228 if { test -f "$as_shell" || test -f "$as_shell.exe"; } && 229 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : 230 CONFIG_SHELL=$as_shell as_have_required=yes 231 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : 232 break 2 233 fi 234 fi 235 done;; 236 esac 237 as_found=false 238 done 239 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && 240 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : 241 CONFIG_SHELL=$SHELL as_have_required=yes 242 fi; } 243 IFS=$as_save_IFS 244 245 246 if test "x$CONFIG_SHELL" != x; then : 247 export CONFIG_SHELL 248 # We cannot yet assume a decent shell, so we have to provide a 249 # neutralization value for shells without unset; and this also 250 # works around shells that cannot unset nonexistent variables. 251 # Preserve -v and -x to the replacement shell. 252 BASH_ENV=/dev/null 253 ENV=/dev/null 254 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 255 case $- in # (((( 256 *v*x* | *x*v* ) as_opts=-vx ;; 257 *v* ) as_opts=-v ;; 258 *x* ) as_opts=-x ;; 259 * ) as_opts= ;; 260 esac 261 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 262 # Admittedly, this is quite paranoid, since all the known shells bail 263 # out after a failed `exec'. 264 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 265 exit 255 266 fi 267 268 if test x$as_have_required = xno; then : 269 $as_echo "$0: This script requires a shell more modern than all" 270 $as_echo "$0: the shells that I found on your system." 271 if test x${ZSH_VERSION+set} = xset ; then 272 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" 273 $as_echo "$0: be upgraded to zsh 4.3.4 or later." 274 else 275 $as_echo "$0: Please tell bug-autoconf@gnu.org and 276 $0: build-dev@openjdk.java.net about your system, including 277 $0: any error possibly output before this message. Then 278 $0: install a modern shell, or manually run the script 279 $0: under such a shell if you do have one." 280 fi 281 exit 1 282 fi 283 fi 284 fi 285 SHELL=${CONFIG_SHELL-/bin/sh} 286 export SHELL 287 # Unset more variables known to interfere with behavior of common tools. 288 CLICOLOR_FORCE= GREP_OPTIONS= 289 unset CLICOLOR_FORCE GREP_OPTIONS 290 291 ## --------------------- ## 292 ## M4sh Shell Functions. ## 293 ## --------------------- ## 294 # as_fn_unset VAR 295 # --------------- 296 # Portably unset VAR. 297 as_fn_unset () 298 { 299 { eval $1=; unset $1;} 300 } 301 as_unset=as_fn_unset 302 303 # as_fn_set_status STATUS 304 # ----------------------- 305 # Set $? to STATUS, without forking. 306 as_fn_set_status () 307 { 308 return $1 309 } # as_fn_set_status 310 311 # as_fn_exit STATUS 312 # ----------------- 313 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 314 as_fn_exit () 315 { 316 set +e 317 as_fn_set_status $1 318 exit $1 319 } # as_fn_exit 320 321 # as_fn_mkdir_p 322 # ------------- 323 # Create "$as_dir" as a directory, including parents if necessary. 324 as_fn_mkdir_p () 325 { 326 327 case $as_dir in #( 328 -*) as_dir=./$as_dir;; 329 esac 330 test -d "$as_dir" || eval $as_mkdir_p || { 331 as_dirs= 332 while :; do 333 case $as_dir in #( 334 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 335 *) as_qdir=$as_dir;; 336 esac 337 as_dirs="'$as_qdir' $as_dirs" 338 as_dir=`$as_dirname -- "$as_dir" || 339 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 340 X"$as_dir" : 'X\(//\)[^/]' \| \ 341 X"$as_dir" : 'X\(//\)$' \| \ 342 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 343 $as_echo X"$as_dir" | 344 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 345 s//\1/ 346 q 347 } 348 /^X\(\/\/\)[^/].*/{ 349 s//\1/ 350 q 351 } 352 /^X\(\/\/\)$/{ 353 s//\1/ 354 q 355 } 356 /^X\(\/\).*/{ 357 s//\1/ 358 q 359 } 360 s/.*/./; q'` 361 test -d "$as_dir" && break 362 done 363 test -z "$as_dirs" || eval "mkdir $as_dirs" 364 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 365 366 367 } # as_fn_mkdir_p 368 369 # as_fn_executable_p FILE 370 # ----------------------- 371 # Test if FILE is an executable regular file. 372 as_fn_executable_p () 373 { 374 test -f "$1" && test -x "$1" 375 } # as_fn_executable_p 376 # as_fn_append VAR VALUE 377 # ---------------------- 378 # Append the text in VALUE to the end of the definition contained in VAR. Take 379 # advantage of any shell optimizations that allow amortized linear growth over 380 # repeated appends, instead of the typical quadratic growth present in naive 381 # implementations. 382 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 383 eval 'as_fn_append () 384 { 385 eval $1+=\$2 386 }' 387 else 388 as_fn_append () 389 { 390 eval $1=\$$1\$2 391 } 392 fi # as_fn_append 393 394 # as_fn_arith ARG... 395 # ------------------ 396 # Perform arithmetic evaluation on the ARGs, and store the result in the 397 # global $as_val. Take advantage of shells that can avoid forks. The arguments 398 # must be portable across $(()) and expr. 399 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 400 eval 'as_fn_arith () 401 { 402 as_val=$(( $* )) 403 }' 404 else 405 as_fn_arith () 406 { 407 as_val=`expr "$@" || test $? -eq 1` 408 } 409 fi # as_fn_arith 410 411 412 # as_fn_error STATUS ERROR [LINENO LOG_FD] 413 # ---------------------------------------- 414 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 415 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 416 # script with STATUS, using 1 if that was 0. 417 as_fn_error () 418 { 419 as_status=$1; test $as_status -eq 0 && as_status=1 420 if test "$4"; then 421 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 422 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 423 fi 424 $as_echo "$as_me: error: $2" >&2 425 as_fn_exit $as_status 426 } # as_fn_error 427 428 if expr a : '\(a\)' >/dev/null 2>&1 && 429 test "X`expr 00001 : '.*\(...\)'`" = X001; then 430 as_expr=expr 431 else 432 as_expr=false 433 fi 434 435 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 436 as_basename=basename 437 else 438 as_basename=false 439 fi 440 441 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 442 as_dirname=dirname 443 else 444 as_dirname=false 445 fi 446 447 as_me=`$as_basename -- "$0" || 448 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 449 X"$0" : 'X\(//\)$' \| \ 450 X"$0" : 'X\(/\)' \| . 2>/dev/null || 451 $as_echo X/"$0" | 452 sed '/^.*\/\([^/][^/]*\)\/*$/{ 453 s//\1/ 454 q 455 } 456 /^X\/\(\/\/\)$/{ 457 s//\1/ 458 q 459 } 460 /^X\/\(\/\).*/{ 461 s//\1/ 462 q 463 } 464 s/.*/./; q'` 465 466 # Avoid depending upon Character Ranges. 467 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 468 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 469 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 470 as_cr_digits='0123456789' 471 as_cr_alnum=$as_cr_Letters$as_cr_digits 472 473 474 as_lineno_1=$LINENO as_lineno_1a=$LINENO 475 as_lineno_2=$LINENO as_lineno_2a=$LINENO 476 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && 477 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { 478 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) 479 sed -n ' 480 p 481 /[$]LINENO/= 482 ' <$as_myself | 483 sed ' 484 s/[$]LINENO.*/&-/ 485 t lineno 486 b 487 :lineno 488 N 489 :loop 490 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ 491 t loop 492 s/-\n.*// 493 ' >$as_me.lineno && 494 chmod +x "$as_me.lineno" || 495 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } 496 497 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have 498 # already done that, so ensure we don't try to do so again and fall 499 # in an infinite loop. This has already happened in practice. 500 _as_can_reexec=no; export _as_can_reexec 501 # Don't try to exec as it changes $[0], causing all sort of problems 502 # (the dirname of $[0] is not the place where we might find the 503 # original and so on. Autoconf is especially sensitive to this). 504 . "./$as_me.lineno" 505 # Exit status is that of the last command. 506 exit 507 } 508 509 ECHO_C= ECHO_N= ECHO_T= 510 case `echo -n x` in #((((( 511 -n*) 512 case `echo 'xy\c'` in 513 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 514 xy) ECHO_C='\c';; 515 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 516 ECHO_T=' ';; 517 esac;; 518 *) 519 ECHO_N='-n';; 520 esac 521 522 rm -f conf$$ conf$$.exe conf$$.file 523 if test -d conf$$.dir; then 524 rm -f conf$$.dir/conf$$.file 525 else 526 rm -f conf$$.dir 527 mkdir conf$$.dir 2>/dev/null 528 fi 529 if (echo >conf$$.file) 2>/dev/null; then 530 if ln -s conf$$.file conf$$ 2>/dev/null; then 531 as_ln_s='ln -s' 532 # ... but there are two gotchas: 533 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 534 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 535 # In both cases, we have to default to `cp -pR'. 536 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 537 as_ln_s='cp -pR' 538 elif ln conf$$.file conf$$ 2>/dev/null; then 539 as_ln_s=ln 540 else 541 as_ln_s='cp -pR' 542 fi 543 else 544 as_ln_s='cp -pR' 545 fi 546 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 547 rmdir conf$$.dir 2>/dev/null 548 549 if mkdir -p . 2>/dev/null; then 550 as_mkdir_p='mkdir -p "$as_dir"' 551 else 552 test -d ./-p && rmdir ./-p 553 as_mkdir_p=false 554 fi 555 556 as_test_x='test -x' 557 as_executable_p=as_fn_executable_p 558 559 # Sed expression to map a string onto a valid CPP name. 560 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 561 562 # Sed expression to map a string onto a valid variable name. 563 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 564 565 566 test -n "$DJDIR" || exec 7<&0 </dev/null 567 exec 6>&1 568 569 # Name of the host. 570 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, 571 # so uname gets run too. 572 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` 573 574 # 575 # Initializations. 576 # 577 ac_default_prefix=/usr/local 578 ac_clean_files= 579 ac_config_libobj_dir=. 580 LIBOBJS= 581 cross_compiling=no 582 subdirs= 583 MFLAGS= 584 MAKEFLAGS= 585 586 # Identity of this package. 587 PACKAGE_NAME='OpenJDK' 588 PACKAGE_TARNAME='openjdk' 589 PACKAGE_VERSION='jdk9' 590 PACKAGE_STRING='OpenJDK jdk9' 591 PACKAGE_BUGREPORT='build-dev@openjdk.java.net' 592 PACKAGE_URL='http://openjdk.java.net' 593 594 # Factoring default headers for most tests. 595 ac_includes_default="\ 596 #include <stdio.h> 597 #ifdef HAVE_SYS_TYPES_H 598 # include <sys/types.h> 599 #endif 600 #ifdef HAVE_SYS_STAT_H 601 # include <sys/stat.h> 602 #endif 603 #ifdef STDC_HEADERS 604 # include <stdlib.h> 605 # include <stddef.h> 606 #else 607 # ifdef HAVE_STDLIB_H 608 # include <stdlib.h> 609 # endif 610 #endif 611 #ifdef HAVE_STRING_H 612 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H 613 # include <memory.h> 614 # endif 615 # include <string.h> 616 #endif 617 #ifdef HAVE_STRINGS_H 618 # include <strings.h> 619 #endif 620 #ifdef HAVE_INTTYPES_H 621 # include <inttypes.h> 622 #endif 623 #ifdef HAVE_STDINT_H 624 # include <stdint.h> 625 #endif 626 #ifdef HAVE_UNISTD_H 627 # include <unistd.h> 628 #endif" 629 630 ac_subst_vars='LTLIBOBJS 631 LIBOBJS 632 CFLAGS_CCACHE 633 CCACHE 634 USE_PRECOMPILED_HEADER 635 BUILD_ICECC 636 ICECC 637 ICECC_WRAPPER 638 ICECC_CREATE_ENV 639 ICECC_CMD 640 ENABLE_JAVAC_SERVER 641 ENABLE_SJAVAC 642 SJAVAC_SERVER_JAVA_FLAGS 643 SJAVAC_SERVER_JAVA 644 JAVA_TOOL_FLAGS_SMALL 645 JAVA_FLAGS_SMALL 646 JAVA_FLAGS_JAVAC 647 BOOTCYCLE_JVM_ARGS_BIG 648 JAVA_FLAGS_BIG 649 JAVA_FLAGS 650 TEST_JOBS 651 JOBS 652 MEMORY_SIZE 653 NUM_CORES 654 ENABLE_GENERATE_CLASSLIST 655 BUILD_FAILURE_HANDLER 656 ENABLE_INTREE_EC 657 VALID_JVM_FEATURES 658 JVM_FEATURES_custom 659 JVM_FEATURES_zeroshark 660 JVM_FEATURES_zero 661 JVM_FEATURES_minimal 662 JVM_FEATURES_core 663 JVM_FEATURES_client 664 JVM_FEATURES_server 665 INCLUDE_GRAAL 666 STLPORT_LIB 667 LIBZIP_CAN_USE_MMAP 668 LIBDL 669 LIBM 670 USE_EXTERNAL_LCMS 671 LCMS_LIBS 672 LCMS_CFLAGS 673 USE_EXTERNAL_LIBZ 674 USE_EXTERNAL_LIBPNG 675 PNG_LIBS 676 PNG_CFLAGS 677 USE_EXTERNAL_LIBGIF 678 USE_EXTERNAL_LIBJPEG 679 LLVM_LIBS 680 LLVM_LDFLAGS 681 LLVM_CFLAGS 682 LLVM_CONFIG 683 LIBFFI_LIB_FILE 684 ENABLE_LIBFFI_BUNDLING 685 LIBFFI_LIBS 686 LIBFFI_CFLAGS 687 ALSA_LIBS 688 ALSA_CFLAGS 689 FREETYPE_LICENSE 690 FREETYPE_BUNDLE_LIB_PATH 691 FREETYPE_LIBS 692 FREETYPE_CFLAGS 693 CUPS_CFLAGS 694 X_EXTRA_LIBS 695 X_LIBS 696 X_PRE_LIBS 697 X_CFLAGS 698 XMKMF 699 MSVCP_DLL 700 MSVCR_DLL 701 LIBCXX 702 FIXPATH_DETACH_FLAG 703 FIXPATH 704 BUILD_GTEST 705 ENABLE_CDS 706 ENABLE_AOT 707 GCOV_ENABLED 708 ZIP_EXTERNAL_DEBUG_SYMBOLS 709 COPY_DEBUG_SYMBOLS 710 COMPILE_WITH_DEBUG_SYMBOLS 711 CFLAGS_WARNINGS_ARE_ERRORS 712 BUILD_CC_DISABLE_WARNING_PREFIX 713 DISABLE_WARNING_PREFIX 714 WARNINGS_AS_ERRORS 715 COMPILER_SUPPORTS_TARGET_BITS_FLAG 716 LDFLAGS_TESTEXE 717 LDFLAGS_TESTLIB 718 CXXFLAGS_TESTEXE 719 CXXFLAGS_TESTLIB 720 CFLAGS_TESTEXE 721 CFLAGS_TESTLIB 722 OPENJDK_BUILD_JVM_LIBS 723 OPENJDK_BUILD_JVM_ASFLAGS 724 OPENJDK_BUILD_JVM_LDFLAGS 725 OPENJDK_BUILD_JVM_CFLAGS 726 OPENJDK_BUILD_LDFLAGS_NO_EXEC_STACK 727 OPENJDK_BUILD_LDFLAGS_HASH_STYLE 728 OPENJDK_BUILD_LDFLAGS_CXX_JDK 729 OPENJDK_BUILD_JDKEXE_LIBS 730 OPENJDK_BUILD_JDKLIB_LIBS 731 OPENJDK_BUILD_LDFLAGS_JDKEXE 732 OPENJDK_BUILD_LDFLAGS_JDKLIB 733 OPENJDK_BUILD_CXXFLAGS_JDKEXE 734 OPENJDK_BUILD_CXXFLAGS_JDKLIB 735 OPENJDK_BUILD_CFLAGS_JDKEXE 736 OPENJDK_BUILD_CFLAGS_JDKLIB 737 OPENJDK_BUILD_CXXSTD_CXXFLAG 738 JVM_LIBS 739 JVM_ASFLAGS 740 JVM_LDFLAGS 741 JVM_CFLAGS 742 LDFLAGS_NO_EXEC_STACK 743 LDFLAGS_HASH_STYLE 744 LDFLAGS_CXX_JDK 745 JDKEXE_LIBS 746 JDKLIB_LIBS 747 LDFLAGS_JDKEXE 748 LDFLAGS_JDKLIB 749 CXXFLAGS_JDKEXE 750 CXXFLAGS_JDKLIB 751 CFLAGS_JDKEXE 752 CFLAGS_JDKLIB 753 MACOSX_VERSION_MAX 754 MACOSX_VERSION_MIN 755 CXXSTD_CXXFLAG 756 JDK_ARCH_ABI_PROP_NAME 757 CXX_O_FLAG_SIZE 758 CXX_O_FLAG_NONE 759 CXX_O_FLAG_DEBUG 760 CXX_O_FLAG_NORM 761 CXX_O_FLAG_HI 762 CXX_O_FLAG_HIGHEST 763 CXX_O_FLAG_HIGHEST_JVM 764 C_O_FLAG_SIZE 765 C_O_FLAG_NONE 766 C_O_FLAG_DEBUG 767 C_O_FLAG_NORM 768 C_O_FLAG_HI 769 C_O_FLAG_HIGHEST 770 C_O_FLAG_HIGHEST_JVM 771 JVM_CFLAGS_SYMBOLS 772 CXXFLAGS_DEBUG_SYMBOLS 773 CFLAGS_DEBUG_SYMBOLS 774 CXX_FLAG_DEPS 775 C_FLAG_DEPS 776 SHARED_LIBRARY_FLAGS 777 SET_SHARED_LIBRARY_MAPFILE 778 SET_SHARED_LIBRARY_NAME 779 SET_SHARED_LIBRARY_ORIGIN 780 SET_EXECUTABLE_ORIGIN 781 CXX_FLAG_REORDER 782 C_FLAG_REORDER 783 JVM_RCFLAGS 784 RC_FLAGS 785 AR_OUT_OPTION 786 LD_OUT_OPTION 787 EXE_OUT_OPTION 788 CC_OUT_OPTION 789 STRIPFLAGS 790 ARFLAGS 791 COMPILER_BINDCMD_FILE_FLAG 792 COMPILER_COMMAND_FILE_FLAG 793 COMPILER_TARGET_BITS_FLAG 794 JIB_JAR 795 JT_HOME 796 JTREGEXE 797 HOTSPOT_TOOLCHAIN_TYPE 798 USING_BROKEN_SUSE_LD 799 PACKAGE_PATH 800 BUILD_AS 801 BUILD_LDCXX 802 BUILD_LD 803 BUILD_STRIP 804 BUILD_OBJCOPY 805 BUILD_AR 806 BUILD_NM 807 BUILD_CXX 808 BUILD_CC 809 BUILD_SYSROOT_LDFLAGS 810 BUILD_SYSROOT_CFLAGS 811 ac_ct_OBJDUMP 812 OBJDUMP 813 ac_ct_OBJCOPY 814 OBJCOPY 815 ac_ct_NM 816 ac_ct_STRIP 817 GNM 818 NM 819 STRIP 820 MSBUILD 821 DUMPBIN 822 RC 823 MT 824 LIPO 825 ac_ct_AR 826 AR 827 AS 828 LDCXX 829 LD 830 CXXCPP 831 CPP 832 CXX_VERSION_NUMBER 833 CC_VERSION_NUMBER 834 ac_ct_CXX 835 CXXFLAGS 836 CXX 837 TOOLCHAIN_PATH_CXX 838 POTENTIAL_CXX 839 OBJEXT 840 EXEEXT 841 ac_ct_CC 842 CPPFLAGS 843 LDFLAGS 844 CFLAGS 845 CC 846 TOOLCHAIN_PATH_CC 847 POTENTIAL_CC 848 TOOLCHAIN_VERSION 849 VS_LIB 850 VS_INCLUDE 851 VS_PATH 852 CYGWIN_LINK 853 SYSROOT_LDFLAGS 854 SYSROOT_CFLAGS 855 EXTRA_LDFLAGS 856 EXTRA_CXXFLAGS 857 EXTRA_CFLAGS 858 EXE_SUFFIX 859 OBJ_SUFFIX 860 STATIC_LIBRARY 861 SHARED_LIBRARY 862 STATIC_LIBRARY_SUFFIX 863 SHARED_LIBRARY_SUFFIX 864 LIBRARY_PREFIX 865 TOOLCHAIN_TYPE 866 STATIC_BUILD 867 IMPORT_MODULES_MAKE 868 IMPORT_MODULES_SRC 869 IMPORT_MODULES_MAN 870 IMPORT_MODULES_LEGAL 871 IMPORT_MODULES_CONF 872 IMPORT_MODULES_LIBS 873 IMPORT_MODULES_CMDS 874 IMPORT_MODULES_CLASSES 875 EXTERNAL_BUILDJDK 876 BUILD_JDK 877 CREATE_BUILDJDK 878 JLINK 879 JMOD 880 JAVAC_FLAGS 881 BOOT_JDK_MODULAR 882 BOOT_JDK_SOURCETARGET 883 JARSIGNER 884 JAR 885 JAVAH 886 JAVAC 887 JAVA 888 BOOT_JDK 889 JAVA_CHECK 890 JAVAC_CHECK 891 VERSION_IS_GA 892 VERSION_SHORT 893 VERSION_STRING 894 VERSION_NUMBER_FOUR_POSITIONS 895 VERSION_NUMBER 896 VERSION_OPT 897 VERSION_BUILD 898 VERSION_PRE 899 VERSION_PATCH 900 VERSION_SECURITY 901 VERSION_MINOR 902 VERSION_MAJOR 903 MACOSX_BUNDLE_ID_BASE 904 MACOSX_BUNDLE_NAME_BASE 905 HOTSPOT_VM_DISTRO 906 COMPANY_NAME 907 JDK_RC_PLATFORM_NAME 908 PRODUCT_SUFFIX 909 PRODUCT_NAME 910 LAUNCHER_NAME 911 JLINK_KEEP_PACKAGED_MODULES 912 COPYRIGHT_YEAR 913 COMPRESS_JARS 914 INCLUDE_SA 915 UNLIMITED_CRYPTO 916 CACERTS_FILE 917 ENABLE_FULL_DOCS 918 ENABLE_HEADLESS_ONLY 919 DEFAULT_MAKE_TARGET 920 OS_VERSION_MICRO 921 OS_VERSION_MINOR 922 OS_VERSION_MAJOR 923 PKG_CONFIG 924 BASH_ARGS 925 SETFILE 926 CODESIGN 927 XATTR 928 DSYMUTIL 929 IS_GNU_TIME 930 PATCH 931 DTRACE 932 FLOCK 933 TIME 934 STAT 935 HG 936 DOT 937 READELF 938 OTOOL 939 LDD 940 ZIPEXE 941 UNZIP 942 TAR_SUPPORTS_TRANSFORM 943 TAR_INCLUDE_PARAM 944 TAR_CREATE_EXTRA_PARAM 945 TAR_TYPE 946 FIND_DELETE 947 OUTPUT_SYNC 948 OUTPUT_SYNC_SUPPORTED 949 CHECK_TOOLSDIR_MAKE 950 CHECK_TOOLSDIR_GMAKE 951 CHECK_MAKE 952 CHECK_GMAKE 953 MAKE 954 PKGHANDLER 955 CONFIGURESUPPORT_OUTPUTDIR 956 OUTPUTDIR 957 CONF_NAME 958 SPEC 959 SDKROOT 960 XCODEBUILD 961 JVM_VARIANT_MAIN 962 VALID_JVM_VARIANTS 963 JVM_VARIANTS 964 DEBUG_LEVEL 965 HOTSPOT_DEBUG_LEVEL 966 JDK_VARIANT 967 USERNAME 968 CANONICAL_TOPDIR 969 ORIGINAL_TOPDIR 970 TOPDIR 971 PATH_SEP 972 HOTSPOT_BUILD_CPU_DEFINE 973 HOTSPOT_BUILD_CPU_ARCH 974 HOTSPOT_BUILD_CPU 975 HOTSPOT_BUILD_OS_TYPE 976 HOTSPOT_BUILD_OS 977 OPENJDK_BUILD_BUNDLE_PLATFORM 978 OPENJDK_BUILD_OS_EXPORT_DIR 979 OPENJDK_BUILD_CPU_OSARCH 980 OPENJDK_BUILD_CPU_ISADIR 981 OPENJDK_BUILD_CPU_LEGACY_LIB 982 OPENJDK_BUILD_CPU_LEGACY 983 HOTSPOT_TARGET_CPU_DEFINE 984 HOTSPOT_TARGET_CPU_ARCH 985 HOTSPOT_TARGET_CPU 986 HOTSPOT_TARGET_OS_TYPE 987 HOTSPOT_TARGET_OS 988 DEFINE_CROSS_COMPILE_ARCH 989 OPENJDK_TARGET_BUNDLE_PLATFORM 990 OPENJDK_TARGET_OS_EXPORT_DIR 991 OPENJDK_TARGET_CPU_OSARCH 992 OPENJDK_TARGET_CPU_ISADIR 993 OPENJDK_TARGET_CPU_LEGACY_LIB 994 OPENJDK_TARGET_CPU_LEGACY 995 RELEASE_FILE_OS_ARCH 996 RELEASE_FILE_OS_NAME 997 OPENJDK_MODULE_TARGET_PLATFORM 998 COMPILE_TYPE 999 OPENJDK_TARGET_CPU_ENDIAN 1000 OPENJDK_TARGET_CPU_BITS 1001 OPENJDK_TARGET_CPU_ARCH 1002 OPENJDK_TARGET_CPU 1003 OPENJDK_TARGET_OS_ENV 1004 OPENJDK_TARGET_OS_TYPE 1005 OPENJDK_TARGET_OS 1006 OPENJDK_BUILD_CPU_ENDIAN 1007 OPENJDK_BUILD_CPU_BITS 1008 OPENJDK_BUILD_CPU_ARCH 1009 OPENJDK_BUILD_CPU 1010 OPENJDK_BUILD_OS_ENV 1011 OPENJDK_BUILD_OS_TYPE 1012 OPENJDK_BUILD_OS 1013 OPENJDK_BUILD_AUTOCONF_NAME 1014 OPENJDK_TARGET_AUTOCONF_NAME 1015 target_os 1016 target_vendor 1017 target_cpu 1018 target 1019 host_os 1020 host_vendor 1021 host_cpu 1022 host 1023 build_os 1024 build_vendor 1025 build_cpu 1026 build 1027 PANDOC 1028 NICE 1029 CPIO 1030 DF 1031 READLINK 1032 CYGPATH 1033 SED 1034 FGREP 1035 EGREP 1036 GREP 1037 AWK 1038 XARGS 1039 WHICH 1040 WC 1041 UNIQ 1042 UNAME 1043 TR 1044 TOUCH 1045 TEE 1046 TAR 1047 TAIL 1048 SORT 1049 SH 1050 RMDIR 1051 RM 1052 PRINTF 1053 NAWK 1054 MV 1055 MKTEMP 1056 MKDIR 1057 LS 1058 LN 1059 GZIP 1060 GUNZIP 1061 HEAD 1062 FIND 1063 FILE 1064 EXPR 1065 ECHO 1066 DIRNAME 1067 DIFF 1068 DATE 1069 CUT 1070 CP 1071 COMM 1072 CMP 1073 CHMOD 1074 CAT 1075 BASH 1076 BASENAME 1077 DATE_WHEN_CONFIGURED 1078 ORIGINAL_PATH 1079 CONFIGURE_COMMAND_LINE 1080 target_alias 1081 host_alias 1082 build_alias 1083 LIBS 1084 ECHO_T 1085 ECHO_N 1086 ECHO_C 1087 DEFS 1088 mandir 1089 localedir 1090 libdir 1091 psdir 1092 pdfdir 1093 dvidir 1094 htmldir 1095 infodir 1096 docdir 1097 oldincludedir 1098 includedir 1099 localstatedir 1100 sharedstatedir 1101 sysconfdir 1102 datadir 1103 datarootdir 1104 libexecdir 1105 sbindir 1106 bindir 1107 program_transform_name 1108 prefix 1109 exec_prefix 1110 PACKAGE_URL 1111 PACKAGE_BUGREPORT 1112 PACKAGE_STRING 1113 PACKAGE_VERSION 1114 PACKAGE_TARNAME 1115 PACKAGE_NAME 1116 PATH_SEPARATOR 1117 SHELL' 1118 ac_subst_files='' 1119 ac_user_opts=' 1120 enable_option_checking 1121 with_target_bits 1122 enable_openjdk_only 1123 with_custom_make_dir 1124 with_jdk_variant 1125 enable_debug 1126 with_debug_level 1127 with_jvm_variants 1128 with_cpu_port 1129 with_devkit 1130 with_sys_root 1131 with_sysroot 1132 with_tools_dir 1133 with_toolchain_path 1134 with_extra_path 1135 with_sdk_name 1136 with_conf_name 1137 with_output_base_dir 1138 with_output_sync 1139 with_default_make_target 1140 enable_headless_only 1141 enable_full_docs 1142 with_cacerts_file 1143 enable_unlimited_crypto 1144 with_copyright_year 1145 enable_keep_packaged_modules 1146 with_milestone 1147 with_update_version 1148 with_user_release_suffix 1149 with_build_number 1150 with_version_string 1151 with_version_pre 1152 with_version_opt 1153 with_version_build 1154 with_version_major 1155 with_version_minor 1156 with_version_security 1157 with_version_patch 1158 with_boot_jdk 1159 with_build_jdk 1160 with_import_modules 1161 enable_static_build 1162 with_toolchain_type 1163 with_extra_cflags 1164 with_extra_cxxflags 1165 with_extra_ldflags 1166 with_toolchain_version 1167 with_build_devkit 1168 with_jtreg 1169 with_jib 1170 with_abi_profile 1171 with_macosx_version_max 1172 enable_warnings_as_errors 1173 with_native_debug_symbols 1174 enable_debug_symbols 1175 enable_zip_debug_info 1176 enable_native_coverage 1177 enable_dtrace 1178 enable_aot 1179 enable_cds 1180 enable_hotspot_gtest 1181 with_stdc__lib 1182 with_msvcr_dll 1183 with_msvcp_dll 1184 with_x 1185 with_cups 1186 with_cups_include 1187 with_freetype 1188 with_freetype_include 1189 with_freetype_lib 1190 with_freetype_src 1191 enable_freetype_bundling 1192 with_freetype_license 1193 with_alsa 1194 with_alsa_include 1195 with_alsa_lib 1196 with_libffi 1197 with_libffi_include 1198 with_libffi_lib 1199 enable_libffi_bundling 1200 with_libjpeg 1201 with_giflib 1202 with_libpng 1203 with_zlib 1204 with_lcms 1205 with_dxsdk 1206 with_dxsdk_lib 1207 with_dxsdk_include 1208 with_jvm_features 1209 with_jvm_interpreter 1210 enable_jtreg_failure_handler 1211 enable_generate_classlist 1212 with_num_cores 1213 with_memory_size 1214 with_jobs 1215 with_test_jobs 1216 with_boot_jdk_jvmargs 1217 with_sjavac_server_java 1218 enable_sjavac 1219 enable_javac_server 1220 enable_icecc 1221 enable_precompiled_headers 1222 enable_ccache 1223 with_ccache_dir 1224 ' 1225 ac_precious_vars='build_alias 1226 host_alias 1227 target_alias 1228 BASENAME 1229 BASH 1230 CAT 1231 CHMOD 1232 CMP 1233 COMM 1234 CP 1235 CUT 1236 DATE 1237 DIFF 1238 DIRNAME 1239 ECHO 1240 EXPR 1241 FILE 1242 FIND 1243 HEAD 1244 GUNZIP 1245 GZIP 1246 LN 1247 LS 1248 MKDIR 1249 MKTEMP 1250 MV 1251 NAWK 1252 PRINTF 1253 RM 1254 RMDIR 1255 SH 1256 SORT 1257 TAIL 1258 TAR 1259 TEE 1260 TOUCH 1261 TR 1262 UNAME 1263 UNIQ 1264 WC 1265 WHICH 1266 XARGS 1267 AWK 1268 GREP 1269 EGREP 1270 FGREP 1271 SED 1272 CYGPATH 1273 READLINK 1274 DF 1275 CPIO 1276 NICE 1277 PANDOC 1278 MAKE 1279 UNZIP 1280 ZIPEXE 1281 LDD 1282 OTOOL 1283 READELF 1284 DOT 1285 HG 1286 STAT 1287 TIME 1288 FLOCK 1289 DTRACE 1290 PATCH 1291 DSYMUTIL 1292 XATTR 1293 CODESIGN 1294 SETFILE 1295 PKG_CONFIG 1296 JAVA 1297 JAVAC 1298 JAVAH 1299 JAR 1300 JARSIGNER 1301 CC 1302 CFLAGS 1303 LDFLAGS 1304 LIBS 1305 CPPFLAGS 1306 CXX 1307 CXXFLAGS 1308 CCC 1309 CPP 1310 CXXCPP 1311 AS 1312 AR 1313 LIPO 1314 STRIP 1315 NM 1316 GNM 1317 OBJCOPY 1318 OBJDUMP 1319 BUILD_CC 1320 BUILD_CXX 1321 BUILD_NM 1322 BUILD_AR 1323 BUILD_OBJCOPY 1324 BUILD_STRIP 1325 JTREGEXE 1326 XMKMF 1327 FREETYPE_CFLAGS 1328 FREETYPE_LIBS 1329 ALSA_CFLAGS 1330 ALSA_LIBS 1331 LIBFFI_CFLAGS 1332 LIBFFI_LIBS 1333 PNG_CFLAGS 1334 PNG_LIBS 1335 LCMS_CFLAGS 1336 LCMS_LIBS 1337 ICECC_CMD 1338 ICECC_CREATE_ENV 1339 ICECC_WRAPPER 1340 CCACHE' 1341 1342 1343 # Initialize some variables set by options. 1344 ac_init_help= 1345 ac_init_version=false 1346 ac_unrecognized_opts= 1347 ac_unrecognized_sep= 1348 # The variables have the same names as the options, with 1349 # dashes changed to underlines. 1350 cache_file=/dev/null 1351 exec_prefix=NONE 1352 no_create= 1353 no_recursion= 1354 prefix=NONE 1355 program_prefix=NONE 1356 program_suffix=NONE 1357 program_transform_name=s,x,x, 1358 silent= 1359 site= 1360 srcdir= 1361 verbose= 1362 x_includes=NONE 1363 x_libraries=NONE 1364 1365 # Installation directory options. 1366 # These are left unexpanded so users can "make install exec_prefix=/foo" 1367 # and all the variables that are supposed to be based on exec_prefix 1368 # by default will actually change. 1369 # Use braces instead of parens because sh, perl, etc. also accept them. 1370 # (The list follows the same order as the GNU Coding Standards.) 1371 bindir='${exec_prefix}/bin' 1372 sbindir='${exec_prefix}/sbin' 1373 libexecdir='${exec_prefix}/libexec' 1374 datarootdir='${prefix}/share' 1375 datadir='${datarootdir}' 1376 sysconfdir='${prefix}/etc' 1377 sharedstatedir='${prefix}/com' 1378 localstatedir='${prefix}/var' 1379 includedir='${prefix}/include' 1380 oldincludedir='/usr/include' 1381 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 1382 infodir='${datarootdir}/info' 1383 htmldir='${docdir}' 1384 dvidir='${docdir}' 1385 pdfdir='${docdir}' 1386 psdir='${docdir}' 1387 libdir='${exec_prefix}/lib' 1388 localedir='${datarootdir}/locale' 1389 mandir='${datarootdir}/man' 1390 1391 ac_prev= 1392 ac_dashdash= 1393 for ac_option 1394 do 1395 # If the previous option needs an argument, assign it. 1396 if test -n "$ac_prev"; then 1397 eval $ac_prev=\$ac_option 1398 ac_prev= 1399 continue 1400 fi 1401 1402 case $ac_option in 1403 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 1404 *=) ac_optarg= ;; 1405 *) ac_optarg=yes ;; 1406 esac 1407 1408 # Accept the important Cygnus configure options, so we can diagnose typos. 1409 1410 case $ac_dashdash$ac_option in 1411 --) 1412 ac_dashdash=yes ;; 1413 1414 -bindir | --bindir | --bindi | --bind | --bin | --bi) 1415 ac_prev=bindir ;; 1416 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 1417 bindir=$ac_optarg ;; 1418 1419 -build | --build | --buil | --bui | --bu) 1420 ac_prev=build_alias ;; 1421 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 1422 build_alias=$ac_optarg ;; 1423 1424 -cache-file | --cache-file | --cache-fil | --cache-fi \ 1425 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 1426 ac_prev=cache_file ;; 1427 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 1428 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 1429 cache_file=$ac_optarg ;; 1430 1431 --config-cache | -C) 1432 cache_file=config.cache ;; 1433 1434 -datadir | --datadir | --datadi | --datad) 1435 ac_prev=datadir ;; 1436 -datadir=* | --datadir=* | --datadi=* | --datad=*) 1437 datadir=$ac_optarg ;; 1438 1439 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 1440 | --dataroo | --dataro | --datar) 1441 ac_prev=datarootdir ;; 1442 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 1443 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 1444 datarootdir=$ac_optarg ;; 1445 1446 -disable-* | --disable-*) 1447 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 1448 # Reject names that are not valid shell variable names. 1449 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1450 as_fn_error $? "invalid feature name: $ac_useropt" 1451 ac_useropt_orig=$ac_useropt 1452 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1453 case $ac_user_opts in 1454 *" 1455 "enable_$ac_useropt" 1456 "*) ;; 1457 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 1458 ac_unrecognized_sep=', ';; 1459 esac 1460 eval enable_$ac_useropt=no ;; 1461 1462 -docdir | --docdir | --docdi | --doc | --do) 1463 ac_prev=docdir ;; 1464 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 1465 docdir=$ac_optarg ;; 1466 1467 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 1468 ac_prev=dvidir ;; 1469 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 1470 dvidir=$ac_optarg ;; 1471 1472 -enable-* | --enable-*) 1473 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 1474 # Reject names that are not valid shell variable names. 1475 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1476 as_fn_error $? "invalid feature name: $ac_useropt" 1477 ac_useropt_orig=$ac_useropt 1478 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1479 case $ac_user_opts in 1480 *" 1481 "enable_$ac_useropt" 1482 "*) ;; 1483 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 1484 ac_unrecognized_sep=', ';; 1485 esac 1486 eval enable_$ac_useropt=\$ac_optarg ;; 1487 1488 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 1489 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 1490 | --exec | --exe | --ex) 1491 ac_prev=exec_prefix ;; 1492 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 1493 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 1494 | --exec=* | --exe=* | --ex=*) 1495 exec_prefix=$ac_optarg ;; 1496 1497 -gas | --gas | --ga | --g) 1498 # Obsolete; use --with-gas. 1499 with_gas=yes ;; 1500 1501 -help | --help | --hel | --he | -h) 1502 ac_init_help=long ;; 1503 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1504 ac_init_help=recursive ;; 1505 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1506 ac_init_help=short ;; 1507 1508 -host | --host | --hos | --ho) 1509 ac_prev=host_alias ;; 1510 -host=* | --host=* | --hos=* | --ho=*) 1511 host_alias=$ac_optarg ;; 1512 1513 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1514 ac_prev=htmldir ;; 1515 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1516 | --ht=*) 1517 htmldir=$ac_optarg ;; 1518 1519 -includedir | --includedir | --includedi | --included | --include \ 1520 | --includ | --inclu | --incl | --inc) 1521 ac_prev=includedir ;; 1522 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1523 | --includ=* | --inclu=* | --incl=* | --inc=*) 1524 includedir=$ac_optarg ;; 1525 1526 -infodir | --infodir | --infodi | --infod | --info | --inf) 1527 ac_prev=infodir ;; 1528 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1529 infodir=$ac_optarg ;; 1530 1531 -libdir | --libdir | --libdi | --libd) 1532 ac_prev=libdir ;; 1533 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1534 libdir=$ac_optarg ;; 1535 1536 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1537 | --libexe | --libex | --libe) 1538 ac_prev=libexecdir ;; 1539 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1540 | --libexe=* | --libex=* | --libe=*) 1541 libexecdir=$ac_optarg ;; 1542 1543 -localedir | --localedir | --localedi | --localed | --locale) 1544 ac_prev=localedir ;; 1545 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1546 localedir=$ac_optarg ;; 1547 1548 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1549 | --localstate | --localstat | --localsta | --localst | --locals) 1550 ac_prev=localstatedir ;; 1551 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1552 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1553 localstatedir=$ac_optarg ;; 1554 1555 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1556 ac_prev=mandir ;; 1557 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1558 mandir=$ac_optarg ;; 1559 1560 -nfp | --nfp | --nf) 1561 # Obsolete; use --without-fp. 1562 with_fp=no ;; 1563 1564 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1565 | --no-cr | --no-c | -n) 1566 no_create=yes ;; 1567 1568 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1569 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1570 no_recursion=yes ;; 1571 1572 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1573 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1574 | --oldin | --oldi | --old | --ol | --o) 1575 ac_prev=oldincludedir ;; 1576 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1577 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1578 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1579 oldincludedir=$ac_optarg ;; 1580 1581 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1582 ac_prev=prefix ;; 1583 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1584 prefix=$ac_optarg ;; 1585 1586 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1587 | --program-pre | --program-pr | --program-p) 1588 ac_prev=program_prefix ;; 1589 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1590 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1591 program_prefix=$ac_optarg ;; 1592 1593 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1594 | --program-suf | --program-su | --program-s) 1595 ac_prev=program_suffix ;; 1596 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1597 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1598 program_suffix=$ac_optarg ;; 1599 1600 -program-transform-name | --program-transform-name \ 1601 | --program-transform-nam | --program-transform-na \ 1602 | --program-transform-n | --program-transform- \ 1603 | --program-transform | --program-transfor \ 1604 | --program-transfo | --program-transf \ 1605 | --program-trans | --program-tran \ 1606 | --progr-tra | --program-tr | --program-t) 1607 ac_prev=program_transform_name ;; 1608 -program-transform-name=* | --program-transform-name=* \ 1609 | --program-transform-nam=* | --program-transform-na=* \ 1610 | --program-transform-n=* | --program-transform-=* \ 1611 | --program-transform=* | --program-transfor=* \ 1612 | --program-transfo=* | --program-transf=* \ 1613 | --program-trans=* | --program-tran=* \ 1614 | --progr-tra=* | --program-tr=* | --program-t=*) 1615 program_transform_name=$ac_optarg ;; 1616 1617 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1618 ac_prev=pdfdir ;; 1619 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1620 pdfdir=$ac_optarg ;; 1621 1622 -psdir | --psdir | --psdi | --psd | --ps) 1623 ac_prev=psdir ;; 1624 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1625 psdir=$ac_optarg ;; 1626 1627 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1628 | -silent | --silent | --silen | --sile | --sil) 1629 silent=yes ;; 1630 1631 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1632 ac_prev=sbindir ;; 1633 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1634 | --sbi=* | --sb=*) 1635 sbindir=$ac_optarg ;; 1636 1637 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1638 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1639 | --sharedst | --shareds | --shared | --share | --shar \ 1640 | --sha | --sh) 1641 ac_prev=sharedstatedir ;; 1642 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1643 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1644 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1645 | --sha=* | --sh=*) 1646 sharedstatedir=$ac_optarg ;; 1647 1648 -site | --site | --sit) 1649 ac_prev=site ;; 1650 -site=* | --site=* | --sit=*) 1651 site=$ac_optarg ;; 1652 1653 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1654 ac_prev=srcdir ;; 1655 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1656 srcdir=$ac_optarg ;; 1657 1658 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1659 | --syscon | --sysco | --sysc | --sys | --sy) 1660 ac_prev=sysconfdir ;; 1661 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1662 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1663 sysconfdir=$ac_optarg ;; 1664 1665 -target | --target | --targe | --targ | --tar | --ta | --t) 1666 ac_prev=target_alias ;; 1667 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1668 target_alias=$ac_optarg ;; 1669 1670 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1671 verbose=yes ;; 1672 1673 -version | --version | --versio | --versi | --vers | -V) 1674 ac_init_version=: ;; 1675 1676 -with-* | --with-*) 1677 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1678 # Reject names that are not valid shell variable names. 1679 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1680 as_fn_error $? "invalid package name: $ac_useropt" 1681 ac_useropt_orig=$ac_useropt 1682 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1683 case $ac_user_opts in 1684 *" 1685 "with_$ac_useropt" 1686 "*) ;; 1687 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1688 ac_unrecognized_sep=', ';; 1689 esac 1690 eval with_$ac_useropt=\$ac_optarg ;; 1691 1692 -without-* | --without-*) 1693 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1694 # Reject names that are not valid shell variable names. 1695 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1696 as_fn_error $? "invalid package name: $ac_useropt" 1697 ac_useropt_orig=$ac_useropt 1698 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1699 case $ac_user_opts in 1700 *" 1701 "with_$ac_useropt" 1702 "*) ;; 1703 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1704 ac_unrecognized_sep=', ';; 1705 esac 1706 eval with_$ac_useropt=no ;; 1707 1708 --x) 1709 # Obsolete; use --with-x. 1710 with_x=yes ;; 1711 1712 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1713 | --x-incl | --x-inc | --x-in | --x-i) 1714 ac_prev=x_includes ;; 1715 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1716 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1717 x_includes=$ac_optarg ;; 1718 1719 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1720 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1721 ac_prev=x_libraries ;; 1722 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1723 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1724 x_libraries=$ac_optarg ;; 1725 1726 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1727 Try \`$0 --help' for more information" 1728 ;; 1729 1730 *=*) 1731 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1732 # Reject names that are not valid shell variable names. 1733 case $ac_envvar in #( 1734 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1735 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1736 esac 1737 eval $ac_envvar=\$ac_optarg 1738 export $ac_envvar ;; 1739 1740 *) 1741 # FIXME: should be removed in autoconf 3.0. 1742 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 1743 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1744 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1745 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1746 ;; 1747 1748 esac 1749 done 1750 1751 if test -n "$ac_prev"; then 1752 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1753 as_fn_error $? "missing argument to $ac_option" 1754 fi 1755 1756 if test -n "$ac_unrecognized_opts"; then 1757 case $enable_option_checking in 1758 no) ;; 1759 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1760 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1761 esac 1762 fi 1763 1764 # Check all directory arguments for consistency. 1765 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1766 datadir sysconfdir sharedstatedir localstatedir includedir \ 1767 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1768 libdir localedir mandir 1769 do 1770 eval ac_val=\$$ac_var 1771 # Remove trailing slashes. 1772 case $ac_val in 1773 */ ) 1774 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1775 eval $ac_var=\$ac_val;; 1776 esac 1777 # Be sure to have absolute directory names. 1778 case $ac_val in 1779 [\\/$]* | ?:[\\/]* ) continue;; 1780 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1781 esac 1782 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1783 done 1784 1785 # There might be people who depend on the old broken behavior: `$host' 1786 # used to hold the argument of --host etc. 1787 # FIXME: To remove some day. 1788 build=$build_alias 1789 host=$host_alias 1790 target=$target_alias 1791 1792 # FIXME: To remove some day. 1793 if test "x$host_alias" != x; then 1794 if test "x$build_alias" = x; then 1795 cross_compiling=maybe 1796 elif test "x$build_alias" != "x$host_alias"; then 1797 cross_compiling=yes 1798 fi 1799 fi 1800 1801 ac_tool_prefix= 1802 test -n "$host_alias" && ac_tool_prefix=$host_alias- 1803 1804 test "$silent" = yes && exec 6>/dev/null 1805 1806 1807 ac_pwd=`pwd` && test -n "$ac_pwd" && 1808 ac_ls_di=`ls -di .` && 1809 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1810 as_fn_error $? "working directory cannot be determined" 1811 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1812 as_fn_error $? "pwd does not report name of working directory" 1813 1814 1815 # Find the source files, if location was not specified. 1816 if test -z "$srcdir"; then 1817 ac_srcdir_defaulted=yes 1818 # Try the directory containing this script, then the parent directory. 1819 ac_confdir=`$as_dirname -- "$as_myself" || 1820 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1821 X"$as_myself" : 'X\(//\)[^/]' \| \ 1822 X"$as_myself" : 'X\(//\)$' \| \ 1823 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1824 $as_echo X"$as_myself" | 1825 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1826 s//\1/ 1827 q 1828 } 1829 /^X\(\/\/\)[^/].*/{ 1830 s//\1/ 1831 q 1832 } 1833 /^X\(\/\/\)$/{ 1834 s//\1/ 1835 q 1836 } 1837 /^X\(\/\).*/{ 1838 s//\1/ 1839 q 1840 } 1841 s/.*/./; q'` 1842 srcdir=$ac_confdir 1843 if test ! -r "$srcdir/$ac_unique_file"; then 1844 srcdir=.. 1845 fi 1846 else 1847 ac_srcdir_defaulted=no 1848 fi 1849 if test ! -r "$srcdir/$ac_unique_file"; then 1850 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1851 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1852 fi 1853 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1854 ac_abs_confdir=`( 1855 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1856 pwd)` 1857 # When building in place, set srcdir=. 1858 if test "$ac_abs_confdir" = "$ac_pwd"; then 1859 srcdir=. 1860 fi 1861 # Remove unnecessary trailing slashes from srcdir. 1862 # Double slashes in file names in object file debugging info 1863 # mess up M-x gdb in Emacs. 1864 case $srcdir in 1865 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1866 esac 1867 for ac_var in $ac_precious_vars; do 1868 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1869 eval ac_env_${ac_var}_value=\$${ac_var} 1870 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1871 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1872 done 1873 1874 # 1875 # Report the --help message. 1876 # 1877 if test "$ac_init_help" = "long"; then 1878 # Omit some internal or obsolete options to make the list less imposing. 1879 # This message is too long to be a string in the A/UX 3.1 sh. 1880 cat <<_ACEOF 1881 \`configure' configures OpenJDK jdk9 to adapt to many kinds of systems. 1882 1883 Usage: $0 [OPTION]... [VAR=VALUE]... 1884 1885 To assign environment variables (e.g., CC, CFLAGS...), specify them as 1886 VAR=VALUE. See below for descriptions of some of the useful variables. 1887 1888 Defaults for the options are specified in brackets. 1889 1890 Configuration: 1891 -h, --help display this help and exit 1892 --help=short display options specific to this package 1893 --help=recursive display the short help of all the included packages 1894 -V, --version display version information and exit 1895 -q, --quiet, --silent do not print \`checking ...' messages 1896 --cache-file=FILE cache test results in FILE [disabled] 1897 -C, --config-cache alias for \`--cache-file=config.cache' 1898 -n, --no-create do not create output files 1899 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1900 1901 Installation directories: 1902 --prefix=PREFIX install architecture-independent files in PREFIX 1903 [$ac_default_prefix] 1904 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1905 [PREFIX] 1906 1907 By default, \`make install' will install all the files in 1908 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1909 an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1910 for instance \`--prefix=\$HOME'. 1911 1912 For better control, use the options below. 1913 1914 Fine tuning of the installation directories: 1915 --bindir=DIR user executables [EPREFIX/bin] 1916 --sbindir=DIR system admin executables [EPREFIX/sbin] 1917 --libexecdir=DIR program executables [EPREFIX/libexec] 1918 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1919 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1920 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1921 --libdir=DIR object code libraries [EPREFIX/lib] 1922 --includedir=DIR C header files [PREFIX/include] 1923 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1924 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1925 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1926 --infodir=DIR info documentation [DATAROOTDIR/info] 1927 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1928 --mandir=DIR man documentation [DATAROOTDIR/man] 1929 --docdir=DIR documentation root [DATAROOTDIR/doc/openjdk] 1930 --htmldir=DIR html documentation [DOCDIR] 1931 --dvidir=DIR dvi documentation [DOCDIR] 1932 --pdfdir=DIR pdf documentation [DOCDIR] 1933 --psdir=DIR ps documentation [DOCDIR] 1934 _ACEOF 1935 1936 cat <<\_ACEOF 1937 1938 X features: 1939 --x-includes=DIR X include files are in DIR 1940 --x-libraries=DIR X library files are in DIR 1941 1942 System types: 1943 --build=BUILD configure for building on BUILD [guessed] 1944 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1945 --target=TARGET configure for building compilers for TARGET [HOST] 1946 _ACEOF 1947 fi 1948 1949 if test -n "$ac_init_help"; then 1950 case $ac_init_help in 1951 short | recursive ) echo "Configuration of OpenJDK jdk9:";; 1952 esac 1953 cat <<\_ACEOF 1954 1955 Optional Features: 1956 --disable-option-checking ignore unrecognized --enable/--with options 1957 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1958 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1959 --enable-openjdk-only suppress building custom source even if present 1960 [disabled] 1961 --enable-debug set the debug level to fastdebug (shorthand for 1962 --with-debug-level=fastdebug) [disabled] 1963 --enable-headless-only only build headless (no GUI) support [disabled] 1964 --enable-full-docs build complete documentation [enabled if all tools 1965 found] 1966 --disable-unlimited-crypto 1967 Disable unlimited crypto policy [enabled] 1968 --disable-keep-packaged-modules 1969 Do not keep packaged modules in jdk image [enable] 1970 --enable-static-build enable static library build [disabled] 1971 --disable-warnings-as-errors 1972 do not consider native warnings to be an error 1973 [enabled] 1974 --enable-debug-symbols Deprecated. Option is kept for backwards 1975 compatibility and is ignored 1976 --enable-zip-debug-info Deprecated. Option is kept for backwards 1977 compatibility and is ignored 1978 --enable-native-coverage 1979 enable native compilation with code coverage 1980 data[disabled] 1981 --enable-dtrace[=yes/no/auto] 1982 enable dtrace. Default is auto, where dtrace is 1983 enabled if all dependencies are present. 1984 --enable-aot[=yes/no/auto] 1985 enable ahead of time compilation feature. Default is 1986 auto, where aot is enabled if all dependencies are 1987 present. 1988 --enable-cds[=yes/no] enable class data sharing feature in non-minimal VM. 1989 Default is yes. 1990 --disable-hotspot-gtest Disables building of the Hotspot unit tests 1991 --disable-freetype-bundling 1992 disable bundling of the freetype library with the 1993 build result [enabled on Windows or when using 1994 --with-freetype, disabled otherwise] 1995 --enable-libffi-bundling 1996 enable bundling of libffi.so to make the built JDK 1997 runnable on more systems 1998 --enable-jtreg-failure-handler 1999 forces build of the jtreg failure handler to be 2000 enabled, missing dependencies become fatal errors. 2001 Default is auto, where the failure handler is built 2002 if all dependencies are present and otherwise just 2003 disabled. 2004 --disable-generate-classlist 2005 forces enabling or disabling of the generation of a 2006 CDS classlist at build time. Default is to generate 2007 it when either the server or client JVMs are built 2008 and enable-cds is true. 2009 --enable-sjavac use sjavac to do fast incremental compiles 2010 [disabled] 2011 --disable-javac-server disable javac server [enabled] 2012 --enable-icecc enable distribted compilation of native code using 2013 icecc/icecream [disabled] 2014 --disable-precompiled-headers 2015 disable using precompiled headers when compiling C++ 2016 [enabled] 2017 --enable-ccache enable using ccache to speed up recompilations 2018 [disabled] 2019 2020 Optional Packages: 2021 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 2022 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 2023 --with-target-bits build 32-bit or 64-bit binaries (for platforms that 2024 support it), e.g. --with-target-bits=32 [guessed] 2025 --with-custom-make-dir Deprecated. Option is kept for backwards 2026 compatibility and is ignored 2027 --with-jdk-variant JDK variant to build (normal) [normal] 2028 --with-debug-level set the debug level (release, fastdebug, slowdebug, 2029 optimized) [release] 2030 --with-jvm-variants JVM variants (separated by commas) to build 2031 (server,client,minimal,core,zero,zeroshark,custom) 2032 [server] 2033 --with-cpu-port specify sources to use for Hotspot 64-bit ARM port 2034 (arm64,aarch64) [aarch64] 2035 --with-devkit use this devkit for compilers, tools and resources 2036 --with-sys-root alias for --with-sysroot for backwards compatability 2037 --with-sysroot use this directory as sysroot 2038 --with-tools-dir alias for --with-toolchain-path for backwards 2039 compatibility 2040 --with-toolchain-path prepend these directories when searching for 2041 toolchain binaries (compilers etc) 2042 --with-extra-path prepend these directories to the default path 2043 --with-sdk-name use the platform SDK of the given name. [macosx] 2044 --with-conf-name use this as the name of the configuration [generated 2045 from important configuration options] 2046 --with-output-base-dir override the default output base directory [./build] 2047 --with-output-sync set make output sync type if supported by make. 2048 [recurse] 2049 --with-default-make-target 2050 set the default make target [exploded-image] 2051 --with-cacerts-file specify alternative cacerts file 2052 --with-copyright-year Set copyright year value for build [current year] 2053 --with-milestone Deprecated. Option is kept for backwards 2054 compatibility and is ignored 2055 --with-update-version Deprecated. Option is kept for backwards 2056 compatibility and is ignored 2057 --with-user-release-suffix 2058 Deprecated. Option is kept for backwards 2059 compatibility and is ignored 2060 --with-build-number Deprecated. Option is kept for backwards 2061 compatibility and is ignored 2062 --with-version-string Set version string [calculated] 2063 --with-version-pre Set the base part of the version 'PRE' field 2064 (pre-release identifier) ['internal'] 2065 --with-version-opt Set version 'OPT' field (build metadata) 2066 [<timestamp>.<user>.<dirname>] 2067 --with-version-build Set version 'BUILD' field (build number) [not 2068 specified] 2069 --with-version-major Set version 'MAJOR' field (first number) [current 2070 source value] 2071 --with-version-minor Set version 'MINOR' field (second number) [current 2072 source value] 2073 --with-version-security Set version 'SECURITY' field (third number) [current 2074 source value] 2075 --with-version-patch Set version 'PATCH' field (fourth number) [not 2076 specified] 2077 --with-boot-jdk path to Boot JDK (used to bootstrap build) [probed] 2078 --with-build-jdk path to JDK of same version as is being built[the 2079 newly built JDK] 2080 --with-import-modules import a set of prebuilt modules either as a zip 2081 file or an exploded directory 2082 --with-toolchain-type the toolchain type (or family) to use, use '--help' 2083 to show possible values [platform dependent] 2084 --with-extra-cflags extra flags to be used when compiling jdk c-files 2085 --with-extra-cxxflags extra flags to be used when compiling jdk c++-files 2086 --with-extra-ldflags extra flags to be used when linking jdk 2087 --with-toolchain-version 2088 the version of the toolchain to look for, use 2089 '--help' to show possible values [platform 2090 dependent] 2091 --with-build-devkit Devkit to use for the build platform toolchain 2092 --with-jtreg Regression Test Harness [probed] 2093 --with-jib Jib dependency management tool [not used] 2094 --with-abi-profile specify ABI profile for ARM builds 2095 (arm-vfp-sflt,arm-vfp-hflt,arm-sflt, 2096 armv5-vfp-sflt,armv6-vfp-hflt,arm64,aarch64) 2097 [toolchain dependent] 2098 --with-macosx-version-max 2099 error on use of newer functionality. [macosx] 2100 --with-native-debug-symbols 2101 set the native debug symbol configuration (none, 2102 internal, external, zipped) [varying] 2103 --with-stdc++lib=<static>,<dynamic>,<default> 2104 force linking of the C++ runtime on Linux to either 2105 static or dynamic, default is static with dynamic as 2106 fallback 2107 --with-msvcr-dll path to microsoft C runtime dll (msvcr*.dll) 2108 (Windows only) [probed] 2109 --with-msvcp-dll path to microsoft C++ runtime dll (msvcp*.dll) 2110 (Windows only) [probed] 2111 --with-x use the X Window System 2112 --with-cups specify prefix directory for the cups package 2113 (expecting the headers under PATH/include) 2114 --with-cups-include specify directory for the cups include files 2115 --with-freetype specify prefix directory for the freetype package 2116 (expecting the libraries under PATH/lib and the 2117 headers under PATH/include) 2118 --with-freetype-include specify directory for the freetype include files 2119 --with-freetype-lib specify directory for the freetype library 2120 --with-freetype-src specify directory with freetype sources to 2121 automatically build the library (experimental, 2122 Windows-only) 2123 --with-freetype-license if bundling freetype, also bundle this license file 2124 --with-alsa specify prefix directory for the alsa package 2125 (expecting the libraries under PATH/lib and the 2126 headers under PATH/include) 2127 --with-alsa-include specify directory for the alsa include files 2128 --with-alsa-lib specify directory for the alsa library 2129 --with-libffi specify prefix directory for the libffi package 2130 (expecting the libraries under PATH/lib and the 2131 headers under PATH/include) 2132 --with-libffi-include specify directory for the libffi include files 2133 --with-libffi-lib specify directory for the libffi library 2134 --with-libjpeg use libjpeg from build system or OpenJDK source 2135 (system, bundled) [bundled] 2136 --with-giflib use giflib from build system or OpenJDK source 2137 (system, bundled) [bundled] 2138 --with-libpng use libpng from build system or OpenJDK source 2139 (system, bundled) [bundled] 2140 --with-zlib use zlib from build system or OpenJDK source 2141 (system, bundled) [bundled] 2142 --with-lcms use lcms2 from build system or OpenJDK source 2143 (system, bundled) [bundled] 2144 --with-dxsdk Deprecated. Option is kept for backwards 2145 compatibility and is ignored 2146 --with-dxsdk-lib Deprecated. Option is kept for backwards 2147 compatibility and is ignored 2148 --with-dxsdk-include Deprecated. Option is kept for backwards 2149 compatibility and is ignored 2150 --with-jvm-features additional JVM features to enable (separated by 2151 comma), use '--help' to show possible values [none] 2152 --with-jvm-interpreter Deprecated. Option is kept for backwards 2153 compatibility and is ignored 2154 --with-num-cores number of cores in the build system, e.g. 2155 --with-num-cores=8 [probed] 2156 --with-memory-size memory (in MB) available in the build system, e.g. 2157 --with-memory-size=1024 [probed] 2158 --with-jobs number of parallel jobs to let make run [calculated 2159 based on cores and memory] 2160 --with-test-jobs number of parallel tests jobs to run [based on build 2161 jobs] 2162 --with-boot-jdk-jvmargs specify JVM arguments to be passed to all java 2163 invocations of boot JDK, overriding the default 2164 values, e.g --with-boot-jdk-jvmargs="-Xmx8G 2165 -enableassertions" 2166 --with-sjavac-server-java 2167 use this java binary for running the sjavac 2168 background server [Boot JDK java] 2169 --with-ccache-dir where to store ccache files [~/.ccache] 2170 2171 Some influential environment variables: 2172 BASENAME Override default value for BASENAME 2173 BASH Override default value for BASH 2174 CAT Override default value for CAT 2175 CHMOD Override default value for CHMOD 2176 CMP Override default value for CMP 2177 COMM Override default value for COMM 2178 CP Override default value for CP 2179 CUT Override default value for CUT 2180 DATE Override default value for DATE 2181 DIFF Override default value for DIFF 2182 DIRNAME Override default value for DIRNAME 2183 ECHO Override default value for ECHO 2184 EXPR Override default value for EXPR 2185 FILE Override default value for FILE 2186 FIND Override default value for FIND 2187 HEAD Override default value for HEAD 2188 GUNZIP Override default value for GUNZIP 2189 GZIP Override default value for GZIP 2190 LN Override default value for LN 2191 LS Override default value for LS 2192 MKDIR Override default value for MKDIR 2193 MKTEMP Override default value for MKTEMP 2194 MV Override default value for MV 2195 NAWK Override default value for NAWK 2196 PRINTF Override default value for PRINTF 2197 RM Override default value for RM 2198 RMDIR Override default value for RMDIR 2199 SH Override default value for SH 2200 SORT Override default value for SORT 2201 TAIL Override default value for TAIL 2202 TAR Override default value for TAR 2203 TEE Override default value for TEE 2204 TOUCH Override default value for TOUCH 2205 TR Override default value for TR 2206 UNAME Override default value for UNAME 2207 UNIQ Override default value for UNIQ 2208 WC Override default value for WC 2209 WHICH Override default value for WHICH 2210 XARGS Override default value for XARGS 2211 AWK Override default value for AWK 2212 GREP Override default value for GREP 2213 EGREP Override default value for EGREP 2214 FGREP Override default value for FGREP 2215 SED Override default value for SED 2216 CYGPATH Override default value for CYGPATH 2217 READLINK Override default value for READLINK 2218 DF Override default value for DF 2219 CPIO Override default value for CPIO 2220 NICE Override default value for NICE 2221 PANDOC Override default value for PANDOC 2222 MAKE Override default value for MAKE 2223 UNZIP Override default value for UNZIP 2224 ZIPEXE Override default value for ZIPEXE 2225 LDD Override default value for LDD 2226 OTOOL Override default value for OTOOL 2227 READELF Override default value for READELF 2228 DOT Override default value for DOT 2229 HG Override default value for HG 2230 STAT Override default value for STAT 2231 TIME Override default value for TIME 2232 FLOCK Override default value for FLOCK 2233 DTRACE Override default value for DTRACE 2234 PATCH Override default value for PATCH 2235 DSYMUTIL Override default value for DSYMUTIL 2236 XATTR Override default value for XATTR 2237 CODESIGN Override default value for CODESIGN 2238 SETFILE Override default value for SETFILE 2239 PKG_CONFIG path to pkg-config utility 2240 JAVA Override default value for JAVA 2241 JAVAC Override default value for JAVAC 2242 JAVAH Override default value for JAVAH 2243 JAR Override default value for JAR 2244 JARSIGNER Override default value for JARSIGNER 2245 CC C compiler command 2246 CFLAGS C compiler flags 2247 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 2248 nonstandard directory <lib dir> 2249 LIBS libraries to pass to the linker, e.g. -l<library> 2250 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 2251 you have headers in a nonstandard directory <include dir> 2252 CXX C++ compiler command 2253 CXXFLAGS C++ compiler flags 2254 CPP C preprocessor 2255 CXXCPP C++ preprocessor 2256 AS Override default value for AS 2257 AR Override default value for AR 2258 LIPO Override default value for LIPO 2259 STRIP Override default value for STRIP 2260 NM Override default value for NM 2261 GNM Override default value for GNM 2262 OBJCOPY Override default value for OBJCOPY 2263 OBJDUMP Override default value for OBJDUMP 2264 BUILD_CC Override default value for BUILD_CC 2265 BUILD_CXX Override default value for BUILD_CXX 2266 BUILD_NM Override default value for BUILD_NM 2267 BUILD_AR Override default value for BUILD_AR 2268 BUILD_OBJCOPY 2269 Override default value for BUILD_OBJCOPY 2270 BUILD_STRIP Override default value for BUILD_STRIP 2271 JTREGEXE Override default value for JTREGEXE 2272 XMKMF Path to xmkmf, Makefile generator for X Window System 2273 FREETYPE_CFLAGS 2274 C compiler flags for FREETYPE, overriding pkg-config 2275 FREETYPE_LIBS 2276 linker flags for FREETYPE, overriding pkg-config 2277 ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config 2278 ALSA_LIBS linker flags for ALSA, overriding pkg-config 2279 LIBFFI_CFLAGS 2280 C compiler flags for LIBFFI, overriding pkg-config 2281 LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config 2282 PNG_CFLAGS C compiler flags for PNG, overriding pkg-config 2283 PNG_LIBS linker flags for PNG, overriding pkg-config 2284 LCMS_CFLAGS C compiler flags for LCMS, overriding pkg-config 2285 LCMS_LIBS linker flags for LCMS, overriding pkg-config 2286 ICECC_CMD Override default value for ICECC_CMD 2287 ICECC_CREATE_ENV 2288 Override default value for ICECC_CREATE_ENV 2289 ICECC_WRAPPER 2290 Override default value for ICECC_WRAPPER 2291 CCACHE Override default value for CCACHE 2292 2293 Use these variables to override the choices made by `configure' or to help 2294 it to find libraries and programs with nonstandard names/locations. 2295 2296 Report bugs to <build-dev@openjdk.java.net>. 2297 OpenJDK home page: <http://openjdk.java.net>. 2298 _ACEOF 2299 ac_status=$? 2300 fi 2301 2302 if test "$ac_init_help" = "recursive"; then 2303 # If there are subdirs, report their specific --help. 2304 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 2305 test -d "$ac_dir" || 2306 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 2307 continue 2308 ac_builddir=. 2309 2310 case "$ac_dir" in 2311 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 2312 *) 2313 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 2314 # A ".." for each directory in $ac_dir_suffix. 2315 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 2316 case $ac_top_builddir_sub in 2317 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 2318 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 2319 esac ;; 2320 esac 2321 ac_abs_top_builddir=$ac_pwd 2322 ac_abs_builddir=$ac_pwd$ac_dir_suffix 2323 # for backward compatibility: 2324 ac_top_builddir=$ac_top_build_prefix 2325 2326 case $srcdir in 2327 .) # We are building in place. 2328 ac_srcdir=. 2329 ac_top_srcdir=$ac_top_builddir_sub 2330 ac_abs_top_srcdir=$ac_pwd ;; 2331 [\\/]* | ?:[\\/]* ) # Absolute name. 2332 ac_srcdir=$srcdir$ac_dir_suffix; 2333 ac_top_srcdir=$srcdir 2334 ac_abs_top_srcdir=$srcdir ;; 2335 *) # Relative name. 2336 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 2337 ac_top_srcdir=$ac_top_build_prefix$srcdir 2338 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 2339 esac 2340 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 2341 2342 cd "$ac_dir" || { ac_status=$?; continue; } 2343 # Check for guested configure. 2344 if test -f "$ac_srcdir/configure.gnu"; then 2345 echo && 2346 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 2347 elif test -f "$ac_srcdir/configure"; then 2348 echo && 2349 $SHELL "$ac_srcdir/configure" --help=recursive 2350 else 2351 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 2352 fi || ac_status=$? 2353 cd "$ac_pwd" || { ac_status=$?; break; } 2354 done 2355 fi 2356 2357 test -n "$ac_init_help" && exit $ac_status 2358 if $ac_init_version; then 2359 cat <<\_ACEOF 2360 OpenJDK configure jdk9 2361 generated by GNU Autoconf 2.69 2362 2363 Copyright (C) 2012 Free Software Foundation, Inc. 2364 This configure script is free software; the Free Software Foundation 2365 gives unlimited permission to copy, distribute and modify it. 2366 _ACEOF 2367 exit 2368 fi 2369 2370 ## ------------------------ ## 2371 ## Autoconf initialization. ## 2372 ## ------------------------ ## 2373 2374 # ac_fn_c_try_compile LINENO 2375 # -------------------------- 2376 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2377 ac_fn_c_try_compile () 2378 { 2379 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2380 rm -f conftest.$ac_objext 2381 if { { ac_try="$ac_compile" 2382 case "(($ac_try" in 2383 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2384 *) ac_try_echo=$ac_try;; 2385 esac 2386 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2387 $as_echo "$ac_try_echo"; } >&5 2388 (eval "$ac_compile") 2>conftest.err 2389 ac_status=$? 2390 if test -s conftest.err; then 2391 grep -v '^ *+' conftest.err >conftest.er1 2392 cat conftest.er1 >&5 2393 mv -f conftest.er1 conftest.err 2394 fi 2395 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2396 test $ac_status = 0; } && { 2397 test -z "$ac_c_werror_flag" || 2398 test ! -s conftest.err 2399 } && test -s conftest.$ac_objext; then : 2400 ac_retval=0 2401 else 2402 $as_echo "$as_me: failed program was:" >&5 2403 sed 's/^/| /' conftest.$ac_ext >&5 2404 2405 ac_retval=1 2406 fi 2407 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2408 as_fn_set_status $ac_retval 2409 2410 } # ac_fn_c_try_compile 2411 2412 # ac_fn_cxx_try_compile LINENO 2413 # ---------------------------- 2414 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2415 ac_fn_cxx_try_compile () 2416 { 2417 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2418 rm -f conftest.$ac_objext 2419 if { { ac_try="$ac_compile" 2420 case "(($ac_try" in 2421 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2422 *) ac_try_echo=$ac_try;; 2423 esac 2424 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2425 $as_echo "$ac_try_echo"; } >&5 2426 (eval "$ac_compile") 2>conftest.err 2427 ac_status=$? 2428 if test -s conftest.err; then 2429 grep -v '^ *+' conftest.err >conftest.er1 2430 cat conftest.er1 >&5 2431 mv -f conftest.er1 conftest.err 2432 fi 2433 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2434 test $ac_status = 0; } && { 2435 test -z "$ac_cxx_werror_flag" || 2436 test ! -s conftest.err 2437 } && test -s conftest.$ac_objext; then : 2438 ac_retval=0 2439 else 2440 $as_echo "$as_me: failed program was:" >&5 2441 sed 's/^/| /' conftest.$ac_ext >&5 2442 2443 ac_retval=1 2444 fi 2445 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2446 as_fn_set_status $ac_retval 2447 2448 } # ac_fn_cxx_try_compile 2449 2450 # ac_fn_c_try_cpp LINENO 2451 # ---------------------- 2452 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2453 ac_fn_c_try_cpp () 2454 { 2455 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2456 if { { ac_try="$ac_cpp conftest.$ac_ext" 2457 case "(($ac_try" in 2458 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2459 *) ac_try_echo=$ac_try;; 2460 esac 2461 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2462 $as_echo "$ac_try_echo"; } >&5 2463 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2464 ac_status=$? 2465 if test -s conftest.err; then 2466 grep -v '^ *+' conftest.err >conftest.er1 2467 cat conftest.er1 >&5 2468 mv -f conftest.er1 conftest.err 2469 fi 2470 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2471 test $ac_status = 0; } > conftest.i && { 2472 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 2473 test ! -s conftest.err 2474 }; then : 2475 ac_retval=0 2476 else 2477 $as_echo "$as_me: failed program was:" >&5 2478 sed 's/^/| /' conftest.$ac_ext >&5 2479 2480 ac_retval=1 2481 fi 2482 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2483 as_fn_set_status $ac_retval 2484 2485 } # ac_fn_c_try_cpp 2486 2487 # ac_fn_cxx_try_cpp LINENO 2488 # ------------------------ 2489 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2490 ac_fn_cxx_try_cpp () 2491 { 2492 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2493 if { { ac_try="$ac_cpp conftest.$ac_ext" 2494 case "(($ac_try" in 2495 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2496 *) ac_try_echo=$ac_try;; 2497 esac 2498 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2499 $as_echo "$ac_try_echo"; } >&5 2500 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2501 ac_status=$? 2502 if test -s conftest.err; then 2503 grep -v '^ *+' conftest.err >conftest.er1 2504 cat conftest.er1 >&5 2505 mv -f conftest.er1 conftest.err 2506 fi 2507 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2508 test $ac_status = 0; } > conftest.i && { 2509 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || 2510 test ! -s conftest.err 2511 }; then : 2512 ac_retval=0 2513 else 2514 $as_echo "$as_me: failed program was:" >&5 2515 sed 's/^/| /' conftest.$ac_ext >&5 2516 2517 ac_retval=1 2518 fi 2519 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2520 as_fn_set_status $ac_retval 2521 2522 } # ac_fn_cxx_try_cpp 2523 2524 # ac_fn_c_try_link LINENO 2525 # ----------------------- 2526 # Try to link conftest.$ac_ext, and return whether this succeeded. 2527 ac_fn_c_try_link () 2528 { 2529 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2530 rm -f conftest.$ac_objext conftest$ac_exeext 2531 if { { ac_try="$ac_link" 2532 case "(($ac_try" in 2533 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2534 *) ac_try_echo=$ac_try;; 2535 esac 2536 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2537 $as_echo "$ac_try_echo"; } >&5 2538 (eval "$ac_link") 2>conftest.err 2539 ac_status=$? 2540 if test -s conftest.err; then 2541 grep -v '^ *+' conftest.err >conftest.er1 2542 cat conftest.er1 >&5 2543 mv -f conftest.er1 conftest.err 2544 fi 2545 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2546 test $ac_status = 0; } && { 2547 test -z "$ac_c_werror_flag" || 2548 test ! -s conftest.err 2549 } && test -s conftest$ac_exeext && { 2550 test "$cross_compiling" = yes || 2551 test -x conftest$ac_exeext 2552 }; then : 2553 ac_retval=0 2554 else 2555 $as_echo "$as_me: failed program was:" >&5 2556 sed 's/^/| /' conftest.$ac_ext >&5 2557 2558 ac_retval=1 2559 fi 2560 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2561 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2562 # interfere with the next link command; also delete a directory that is 2563 # left behind by Apple's compiler. We do this before executing the actions. 2564 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2565 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2566 as_fn_set_status $ac_retval 2567 2568 } # ac_fn_c_try_link 2569 2570 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES 2571 # --------------------------------------------------------- 2572 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 2573 # the include files in INCLUDES and setting the cache variable VAR 2574 # accordingly. 2575 ac_fn_cxx_check_header_mongrel () 2576 { 2577 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2578 if eval \${$3+:} false; then : 2579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2580 $as_echo_n "checking for $2... " >&6; } 2581 if eval \${$3+:} false; then : 2582 $as_echo_n "(cached) " >&6 2583 fi 2584 eval ac_res=\$$3 2585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2586 $as_echo "$ac_res" >&6; } 2587 else 2588 # Is the header compilable? 2589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 2590 $as_echo_n "checking $2 usability... " >&6; } 2591 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2592 /* end confdefs.h. */ 2593 $4 2594 #include <$2> 2595 _ACEOF 2596 if ac_fn_cxx_try_compile "$LINENO"; then : 2597 ac_header_compiler=yes 2598 else 2599 ac_header_compiler=no 2600 fi 2601 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 2603 $as_echo "$ac_header_compiler" >&6; } 2604 2605 # Is the header present? 2606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 2607 $as_echo_n "checking $2 presence... " >&6; } 2608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2609 /* end confdefs.h. */ 2610 #include <$2> 2611 _ACEOF 2612 if ac_fn_cxx_try_cpp "$LINENO"; then : 2613 ac_header_preproc=yes 2614 else 2615 ac_header_preproc=no 2616 fi 2617 rm -f conftest.err conftest.i conftest.$ac_ext 2618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 2619 $as_echo "$ac_header_preproc" >&6; } 2620 2621 # So? What about this header? 2622 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( 2623 yes:no: ) 2624 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 2625 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} 2626 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2627 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2628 ;; 2629 no:yes:* ) 2630 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 2631 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 2632 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 2633 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 2634 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 2635 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 2636 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 2637 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 2638 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2639 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2640 ( $as_echo "## ----------------------------------------- ## 2641 ## Report this to build-dev@openjdk.java.net ## 2642 ## ----------------------------------------- ##" 2643 ) | sed "s/^/$as_me: WARNING: /" >&2 2644 ;; 2645 esac 2646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2647 $as_echo_n "checking for $2... " >&6; } 2648 if eval \${$3+:} false; then : 2649 $as_echo_n "(cached) " >&6 2650 else 2651 eval "$3=\$ac_header_compiler" 2652 fi 2653 eval ac_res=\$$3 2654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2655 $as_echo "$ac_res" >&6; } 2656 fi 2657 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2658 2659 } # ac_fn_cxx_check_header_mongrel 2660 2661 # ac_fn_cxx_try_run LINENO 2662 # ------------------------ 2663 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 2664 # that executables *can* be run. 2665 ac_fn_cxx_try_run () 2666 { 2667 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2668 if { { ac_try="$ac_link" 2669 case "(($ac_try" in 2670 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2671 *) ac_try_echo=$ac_try;; 2672 esac 2673 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2674 $as_echo "$ac_try_echo"; } >&5 2675 (eval "$ac_link") 2>&5 2676 ac_status=$? 2677 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2678 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 2679 { { case "(($ac_try" in 2680 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2681 *) ac_try_echo=$ac_try;; 2682 esac 2683 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2684 $as_echo "$ac_try_echo"; } >&5 2685 (eval "$ac_try") 2>&5 2686 ac_status=$? 2687 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2688 test $ac_status = 0; }; }; then : 2689 ac_retval=0 2690 else 2691 $as_echo "$as_me: program exited with status $ac_status" >&5 2692 $as_echo "$as_me: failed program was:" >&5 2693 sed 's/^/| /' conftest.$ac_ext >&5 2694 2695 ac_retval=$ac_status 2696 fi 2697 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2698 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2699 as_fn_set_status $ac_retval 2700 2701 } # ac_fn_cxx_try_run 2702 2703 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES 2704 # --------------------------------------------------------- 2705 # Tests whether HEADER exists and can be compiled using the include files in 2706 # INCLUDES, setting the cache variable VAR accordingly. 2707 ac_fn_cxx_check_header_compile () 2708 { 2709 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2711 $as_echo_n "checking for $2... " >&6; } 2712 if eval \${$3+:} false; then : 2713 $as_echo_n "(cached) " >&6 2714 else 2715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2716 /* end confdefs.h. */ 2717 $4 2718 #include <$2> 2719 _ACEOF 2720 if ac_fn_cxx_try_compile "$LINENO"; then : 2721 eval "$3=yes" 2722 else 2723 eval "$3=no" 2724 fi 2725 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2726 fi 2727 eval ac_res=\$$3 2728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2729 $as_echo "$ac_res" >&6; } 2730 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2731 2732 } # ac_fn_cxx_check_header_compile 2733 2734 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES 2735 # ---------------------------------------------- 2736 # Tries to find the compile-time value of EXPR in a program that includes 2737 # INCLUDES, setting VAR accordingly. Returns whether the value could be 2738 # computed 2739 ac_fn_cxx_compute_int () 2740 { 2741 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2742 if test "$cross_compiling" = yes; then 2743 # Depending upon the size, compute the lo and hi bounds. 2744 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2745 /* end confdefs.h. */ 2746 $4 2747 int 2748 main () 2749 { 2750 static int test_array [1 - 2 * !(($2) >= 0)]; 2751 test_array [0] = 0; 2752 return test_array [0]; 2753 2754 ; 2755 return 0; 2756 } 2757 _ACEOF 2758 if ac_fn_cxx_try_compile "$LINENO"; then : 2759 ac_lo=0 ac_mid=0 2760 while :; do 2761 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2762 /* end confdefs.h. */ 2763 $4 2764 int 2765 main () 2766 { 2767 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2768 test_array [0] = 0; 2769 return test_array [0]; 2770 2771 ; 2772 return 0; 2773 } 2774 _ACEOF 2775 if ac_fn_cxx_try_compile "$LINENO"; then : 2776 ac_hi=$ac_mid; break 2777 else 2778 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2779 if test $ac_lo -le $ac_mid; then 2780 ac_lo= ac_hi= 2781 break 2782 fi 2783 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2784 fi 2785 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2786 done 2787 else 2788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2789 /* end confdefs.h. */ 2790 $4 2791 int 2792 main () 2793 { 2794 static int test_array [1 - 2 * !(($2) < 0)]; 2795 test_array [0] = 0; 2796 return test_array [0]; 2797 2798 ; 2799 return 0; 2800 } 2801 _ACEOF 2802 if ac_fn_cxx_try_compile "$LINENO"; then : 2803 ac_hi=-1 ac_mid=-1 2804 while :; do 2805 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2806 /* end confdefs.h. */ 2807 $4 2808 int 2809 main () 2810 { 2811 static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2812 test_array [0] = 0; 2813 return test_array [0]; 2814 2815 ; 2816 return 0; 2817 } 2818 _ACEOF 2819 if ac_fn_cxx_try_compile "$LINENO"; then : 2820 ac_lo=$ac_mid; break 2821 else 2822 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2823 if test $ac_mid -le $ac_hi; then 2824 ac_lo= ac_hi= 2825 break 2826 fi 2827 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2828 fi 2829 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2830 done 2831 else 2832 ac_lo= ac_hi= 2833 fi 2834 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2835 fi 2836 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2837 # Binary search between lo and hi bounds. 2838 while test "x$ac_lo" != "x$ac_hi"; do 2839 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2840 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2841 /* end confdefs.h. */ 2842 $4 2843 int 2844 main () 2845 { 2846 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2847 test_array [0] = 0; 2848 return test_array [0]; 2849 2850 ; 2851 return 0; 2852 } 2853 _ACEOF 2854 if ac_fn_cxx_try_compile "$LINENO"; then : 2855 ac_hi=$ac_mid 2856 else 2857 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2858 fi 2859 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2860 done 2861 case $ac_lo in #(( 2862 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2863 '') ac_retval=1 ;; 2864 esac 2865 else 2866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2867 /* end confdefs.h. */ 2868 $4 2869 static long int longval () { return $2; } 2870 static unsigned long int ulongval () { return $2; } 2871 #include <stdio.h> 2872 #include <stdlib.h> 2873 int 2874 main () 2875 { 2876 2877 FILE *f = fopen ("conftest.val", "w"); 2878 if (! f) 2879 return 1; 2880 if (($2) < 0) 2881 { 2882 long int i = longval (); 2883 if (i != ($2)) 2884 return 1; 2885 fprintf (f, "%ld", i); 2886 } 2887 else 2888 { 2889 unsigned long int i = ulongval (); 2890 if (i != ($2)) 2891 return 1; 2892 fprintf (f, "%lu", i); 2893 } 2894 /* Do not output a trailing newline, as this causes \r\n confusion 2895 on some platforms. */ 2896 return ferror (f) || fclose (f) != 0; 2897 2898 ; 2899 return 0; 2900 } 2901 _ACEOF 2902 if ac_fn_cxx_try_run "$LINENO"; then : 2903 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2904 else 2905 ac_retval=1 2906 fi 2907 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2908 conftest.$ac_objext conftest.beam conftest.$ac_ext 2909 rm -f conftest.val 2910 2911 fi 2912 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2913 as_fn_set_status $ac_retval 2914 2915 } # ac_fn_cxx_compute_int 2916 2917 # ac_fn_cxx_try_link LINENO 2918 # ------------------------- 2919 # Try to link conftest.$ac_ext, and return whether this succeeded. 2920 ac_fn_cxx_try_link () 2921 { 2922 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2923 rm -f conftest.$ac_objext conftest$ac_exeext 2924 if { { ac_try="$ac_link" 2925 case "(($ac_try" in 2926 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2927 *) ac_try_echo=$ac_try;; 2928 esac 2929 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2930 $as_echo "$ac_try_echo"; } >&5 2931 (eval "$ac_link") 2>conftest.err 2932 ac_status=$? 2933 if test -s conftest.err; then 2934 grep -v '^ *+' conftest.err >conftest.er1 2935 cat conftest.er1 >&5 2936 mv -f conftest.er1 conftest.err 2937 fi 2938 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2939 test $ac_status = 0; } && { 2940 test -z "$ac_cxx_werror_flag" || 2941 test ! -s conftest.err 2942 } && test -s conftest$ac_exeext && { 2943 test "$cross_compiling" = yes || 2944 test -x conftest$ac_exeext 2945 }; then : 2946 ac_retval=0 2947 else 2948 $as_echo "$as_me: failed program was:" >&5 2949 sed 's/^/| /' conftest.$ac_ext >&5 2950 2951 ac_retval=1 2952 fi 2953 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2954 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2955 # interfere with the next link command; also delete a directory that is 2956 # left behind by Apple's compiler. We do this before executing the actions. 2957 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2958 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2959 as_fn_set_status $ac_retval 2960 2961 } # ac_fn_cxx_try_link 2962 2963 # ac_fn_cxx_check_func LINENO FUNC VAR 2964 # ------------------------------------ 2965 # Tests whether FUNC exists, setting the cache variable VAR accordingly 2966 ac_fn_cxx_check_func () 2967 { 2968 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2970 $as_echo_n "checking for $2... " >&6; } 2971 if eval \${$3+:} false; then : 2972 $as_echo_n "(cached) " >&6 2973 else 2974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2975 /* end confdefs.h. */ 2976 /* Define $2 to an innocuous variant, in case <limits.h> declares $2. 2977 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 2978 #define $2 innocuous_$2 2979 2980 /* System header to define __stub macros and hopefully few prototypes, 2981 which can conflict with char $2 (); below. 2982 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 2983 <limits.h> exists even on freestanding compilers. */ 2984 2985 #ifdef __STDC__ 2986 # include <limits.h> 2987 #else 2988 # include <assert.h> 2989 #endif 2990 2991 #undef $2 2992 2993 /* Override any GCC internal prototype to avoid an error. 2994 Use char because int might match the return type of a GCC 2995 builtin and then its argument prototype would still apply. */ 2996 #ifdef __cplusplus 2997 extern "C" 2998 #endif 2999 char $2 (); 3000 /* The GNU C library defines this for functions which it implements 3001 to always fail with ENOSYS. Some functions are actually named 3002 something starting with __ and the normal name is an alias. */ 3003 #if defined __stub_$2 || defined __stub___$2 3004 choke me 3005 #endif 3006 3007 int 3008 main () 3009 { 3010 return $2 (); 3011 ; 3012 return 0; 3013 } 3014 _ACEOF 3015 if ac_fn_cxx_try_link "$LINENO"; then : 3016 eval "$3=yes" 3017 else 3018 eval "$3=no" 3019 fi 3020 rm -f core conftest.err conftest.$ac_objext \ 3021 conftest$ac_exeext conftest.$ac_ext 3022 fi 3023 eval ac_res=\$$3 3024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3025 $as_echo "$ac_res" >&6; } 3026 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3027 3028 } # ac_fn_cxx_check_func 3029 3030 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 3031 # ------------------------------------------------------- 3032 # Tests whether HEADER exists and can be compiled using the include files in 3033 # INCLUDES, setting the cache variable VAR accordingly. 3034 ac_fn_c_check_header_compile () 3035 { 3036 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 3037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 3038 $as_echo_n "checking for $2... " >&6; } 3039 if eval \${$3+:} false; then : 3040 $as_echo_n "(cached) " >&6 3041 else 3042 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3043 /* end confdefs.h. */ 3044 $4 3045 #include <$2> 3046 _ACEOF 3047 if ac_fn_c_try_compile "$LINENO"; then : 3048 eval "$3=yes" 3049 else 3050 eval "$3=no" 3051 fi 3052 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3053 fi 3054 eval ac_res=\$$3 3055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3056 $as_echo "$ac_res" >&6; } 3057 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3058 3059 } # ac_fn_c_check_header_compile 3060 cat >config.log <<_ACEOF 3061 This file contains any messages produced by compilers while 3062 running configure, to aid debugging if configure makes a mistake. 3063 3064 It was created by OpenJDK $as_me jdk9, which was 3065 generated by GNU Autoconf 2.69. Invocation command line was 3066 3067 $ $0 $@ 3068 3069 _ACEOF 3070 exec 5>>config.log 3071 { 3072 cat <<_ASUNAME 3073 ## --------- ## 3074 ## Platform. ## 3075 ## --------- ## 3076 3077 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 3078 uname -m = `(uname -m) 2>/dev/null || echo unknown` 3079 uname -r = `(uname -r) 2>/dev/null || echo unknown` 3080 uname -s = `(uname -s) 2>/dev/null || echo unknown` 3081 uname -v = `(uname -v) 2>/dev/null || echo unknown` 3082 3083 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 3084 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 3085 3086 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 3087 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 3088 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 3089 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 3090 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 3091 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 3092 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 3093 3094 _ASUNAME 3095 3096 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3097 for as_dir in $PATH 3098 do 3099 IFS=$as_save_IFS 3100 test -z "$as_dir" && as_dir=. 3101 $as_echo "PATH: $as_dir" 3102 done 3103 IFS=$as_save_IFS 3104 3105 } >&5 3106 3107 cat >&5 <<_ACEOF 3108 3109 3110 ## ----------- ## 3111 ## Core tests. ## 3112 ## ----------- ## 3113 3114 _ACEOF 3115 3116 3117 # Keep a trace of the command line. 3118 # Strip out --no-create and --no-recursion so they do not pile up. 3119 # Strip out --silent because we don't want to record it for future runs. 3120 # Also quote any args containing shell meta-characters. 3121 # Make two passes to allow for proper duplicate-argument suppression. 3122 ac_configure_args= 3123 ac_configure_args0= 3124 ac_configure_args1= 3125 ac_must_keep_next=false 3126 for ac_pass in 1 2 3127 do 3128 for ac_arg 3129 do 3130 case $ac_arg in 3131 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 3132 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 3133 | -silent | --silent | --silen | --sile | --sil) 3134 continue ;; 3135 *\'*) 3136 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 3137 esac 3138 case $ac_pass in 3139 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 3140 2) 3141 as_fn_append ac_configure_args1 " '$ac_arg'" 3142 if test $ac_must_keep_next = true; then 3143 ac_must_keep_next=false # Got value, back to normal. 3144 else 3145 case $ac_arg in 3146 *=* | --config-cache | -C | -disable-* | --disable-* \ 3147 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 3148 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 3149 | -with-* | --with-* | -without-* | --without-* | --x) 3150 case "$ac_configure_args0 " in 3151 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 3152 esac 3153 ;; 3154 -* ) ac_must_keep_next=true ;; 3155 esac 3156 fi 3157 as_fn_append ac_configure_args " '$ac_arg'" 3158 ;; 3159 esac 3160 done 3161 done 3162 { ac_configure_args0=; unset ac_configure_args0;} 3163 { ac_configure_args1=; unset ac_configure_args1;} 3164 3165 # When interrupted or exit'd, cleanup temporary files, and complete 3166 # config.log. We remove comments because anyway the quotes in there 3167 # would cause problems or look ugly. 3168 # WARNING: Use '\'' to represent an apostrophe within the trap. 3169 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 3170 trap 'exit_status=$? 3171 # Save into config.log some information that might help in debugging. 3172 { 3173 echo 3174 3175 $as_echo "## ---------------- ## 3176 ## Cache variables. ## 3177 ## ---------------- ##" 3178 echo 3179 # The following way of writing the cache mishandles newlines in values, 3180 ( 3181 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 3182 eval ac_val=\$$ac_var 3183 case $ac_val in #( 3184 *${as_nl}*) 3185 case $ac_var in #( 3186 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 3187 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 3188 esac 3189 case $ac_var in #( 3190 _ | IFS | as_nl) ;; #( 3191 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 3192 *) { eval $ac_var=; unset $ac_var;} ;; 3193 esac ;; 3194 esac 3195 done 3196 (set) 2>&1 | 3197 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 3198 *${as_nl}ac_space=\ *) 3199 sed -n \ 3200 "s/'\''/'\''\\\\'\'''\''/g; 3201 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 3202 ;; #( 3203 *) 3204 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 3205 ;; 3206 esac | 3207 sort 3208 ) 3209 echo 3210 3211 $as_echo "## ----------------- ## 3212 ## Output variables. ## 3213 ## ----------------- ##" 3214 echo 3215 for ac_var in $ac_subst_vars 3216 do 3217 eval ac_val=\$$ac_var 3218 case $ac_val in 3219 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3220 esac 3221 $as_echo "$ac_var='\''$ac_val'\''" 3222 done | sort 3223 echo 3224 3225 if test -n "$ac_subst_files"; then 3226 $as_echo "## ------------------- ## 3227 ## File substitutions. ## 3228 ## ------------------- ##" 3229 echo 3230 for ac_var in $ac_subst_files 3231 do 3232 eval ac_val=\$$ac_var 3233 case $ac_val in 3234 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3235 esac 3236 $as_echo "$ac_var='\''$ac_val'\''" 3237 done | sort 3238 echo 3239 fi 3240 3241 if test -s confdefs.h; then 3242 $as_echo "## ----------- ## 3243 ## confdefs.h. ## 3244 ## ----------- ##" 3245 echo 3246 cat confdefs.h 3247 echo 3248 fi 3249 test "$ac_signal" != 0 && 3250 $as_echo "$as_me: caught signal $ac_signal" 3251 $as_echo "$as_me: exit $exit_status" 3252 } >&5 3253 rm -f core *.core core.conftest.* && 3254 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 3255 exit $exit_status 3256 ' 0 3257 for ac_signal in 1 2 13 15; do 3258 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 3259 done 3260 ac_signal=0 3261 3262 # confdefs.h avoids OS command line length limits that DEFS can exceed. 3263 rm -f -r conftest* confdefs.h 3264 3265 $as_echo "/* confdefs.h */" > confdefs.h 3266 3267 # Predefined preprocessor variables. 3268 3269 cat >>confdefs.h <<_ACEOF 3270 #define PACKAGE_NAME "$PACKAGE_NAME" 3271 _ACEOF 3272 3273 cat >>confdefs.h <<_ACEOF 3274 #define PACKAGE_TARNAME "$PACKAGE_TARNAME" 3275 _ACEOF 3276 3277 cat >>confdefs.h <<_ACEOF 3278 #define PACKAGE_VERSION "$PACKAGE_VERSION" 3279 _ACEOF 3280 3281 cat >>confdefs.h <<_ACEOF 3282 #define PACKAGE_STRING "$PACKAGE_STRING" 3283 _ACEOF 3284 3285 cat >>confdefs.h <<_ACEOF 3286 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" 3287 _ACEOF 3288 3289 cat >>confdefs.h <<_ACEOF 3290 #define PACKAGE_URL "$PACKAGE_URL" 3291 _ACEOF 3292 3293 3294 # Let the site file select an alternate cache file if it wants to. 3295 # Prefer an explicitly selected file to automatically selected ones. 3296 ac_site_file1=NONE 3297 ac_site_file2=NONE 3298 if test -n "$CONFIG_SITE"; then 3299 # We do not want a PATH search for config.site. 3300 case $CONFIG_SITE in #(( 3301 -*) ac_site_file1=./$CONFIG_SITE;; 3302 */*) ac_site_file1=$CONFIG_SITE;; 3303 *) ac_site_file1=./$CONFIG_SITE;; 3304 esac 3305 elif test "x$prefix" != xNONE; then 3306 ac_site_file1=$prefix/share/config.site 3307 ac_site_file2=$prefix/etc/config.site 3308 else 3309 ac_site_file1=$ac_default_prefix/share/config.site 3310 ac_site_file2=$ac_default_prefix/etc/config.site 3311 fi 3312 for ac_site_file in "$ac_site_file1" "$ac_site_file2" 3313 do 3314 test "x$ac_site_file" = xNONE && continue 3315 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then 3316 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 3317 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 3318 sed 's/^/| /' "$ac_site_file" >&5 3319 . "$ac_site_file" \ 3320 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3321 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3322 as_fn_error $? "failed to load site script $ac_site_file 3323 See \`config.log' for more details" "$LINENO" 5; } 3324 fi 3325 done 3326 3327 if test -r "$cache_file"; then 3328 # Some versions of bash will fail to source /dev/null (special files 3329 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 3330 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 3331 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 3332 $as_echo "$as_me: loading cache $cache_file" >&6;} 3333 case $cache_file in 3334 [\\/]* | ?:[\\/]* ) . "$cache_file";; 3335 *) . "./$cache_file";; 3336 esac 3337 fi 3338 else 3339 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 3340 $as_echo "$as_me: creating cache $cache_file" >&6;} 3341 >$cache_file 3342 fi 3343 3344 # Check that the precious variables saved in the cache have kept the same 3345 # value. 3346 ac_cache_corrupted=false 3347 for ac_var in $ac_precious_vars; do 3348 eval ac_old_set=\$ac_cv_env_${ac_var}_set 3349 eval ac_new_set=\$ac_env_${ac_var}_set 3350 eval ac_old_val=\$ac_cv_env_${ac_var}_value 3351 eval ac_new_val=\$ac_env_${ac_var}_value 3352 case $ac_old_set,$ac_new_set in 3353 set,) 3354 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 3355 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 3356 ac_cache_corrupted=: ;; 3357 ,set) 3358 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 3359 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 3360 ac_cache_corrupted=: ;; 3361 ,);; 3362 *) 3363 if test "x$ac_old_val" != "x$ac_new_val"; then 3364 # differences in whitespace do not lead to failure. 3365 ac_old_val_w=`echo x $ac_old_val` 3366 ac_new_val_w=`echo x $ac_new_val` 3367 if test "$ac_old_val_w" != "$ac_new_val_w"; then 3368 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 3369 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 3370 ac_cache_corrupted=: 3371 else 3372 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 3373 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 3374 eval $ac_var=\$ac_old_val 3375 fi 3376 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 3377 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} 3378 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 3379 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} 3380 fi;; 3381 esac 3382 # Pass precious variables to config.status. 3383 if test "$ac_new_set" = set; then 3384 case $ac_new_val in 3385 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 3386 *) ac_arg=$ac_var=$ac_new_val ;; 3387 esac 3388 case " $ac_configure_args " in 3389 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 3390 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 3391 esac 3392 fi 3393 done 3394 if $ac_cache_corrupted; then 3395 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3396 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3397 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 3398 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 3399 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 3400 fi 3401 ## -------------------- ## 3402 ## Main body of script. ## 3403 ## -------------------- ## 3404 3405 ac_ext=c 3406 ac_cpp='$CPP $CPPFLAGS' 3407 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3408 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3409 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3410 3411 3412 3413 ac_aux_dir= 3414 for ac_dir in $TOPDIR/make/autoconf/build-aux "$srcdir"/$TOPDIR/make/autoconf/build-aux; do 3415 if test -f "$ac_dir/install-sh"; then 3416 ac_aux_dir=$ac_dir 3417 ac_install_sh="$ac_aux_dir/install-sh -c" 3418 break 3419 elif test -f "$ac_dir/install.sh"; then 3420 ac_aux_dir=$ac_dir 3421 ac_install_sh="$ac_aux_dir/install.sh -c" 3422 break 3423 elif test -f "$ac_dir/shtool"; then 3424 ac_aux_dir=$ac_dir 3425 ac_install_sh="$ac_aux_dir/shtool install -c" 3426 break 3427 fi 3428 done 3429 if test -z "$ac_aux_dir"; then 3430 as_fn_error $? "cannot find install-sh, install.sh, or shtool in $TOPDIR/make/autoconf/build-aux \"$srcdir\"/$TOPDIR/make/autoconf/build-aux" "$LINENO" 5 3431 fi 3432 3433 # These three variables are undocumented and unsupported, 3434 # and are intended to be withdrawn in a future Autoconf release. 3435 # They can cause serious problems if a builder's source tree is in a directory 3436 # whose full name contains unusual characters. 3437 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. 3438 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. 3439 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. 3440 3441 3442 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 3443 3444 # 3445 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. 3446 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3447 # 3448 # This code is free software; you can redistribute it and/or modify it 3449 # under the terms of the GNU General Public License version 2 only, as 3450 # published by the Free Software Foundation. Oracle designates this 3451 # particular file as subject to the "Classpath" exception as provided 3452 # by Oracle in the LICENSE file that accompanied this code. 3453 # 3454 # This code is distributed in the hope that it will be useful, but WITHOUT 3455 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3456 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3457 # version 2 for more details (a copy is included in the LICENSE file that 3458 # accompanied this code). 3459 # 3460 # You should have received a copy of the GNU General Public License version 3461 # 2 along with this work; if not, write to the Free Software Foundation, 3462 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3463 # 3464 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3465 # or visit www.oracle.com if you need additional information or have any 3466 # questions. 3467 # 3468 3469 # 3470 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 3471 # 3472 # This program is free software; you can redistribute it and/or modify 3473 # it under the terms of the GNU General Public License as published by 3474 # the Free Software Foundation; either version 2 of the License, or 3475 # (at your option) any later version. 3476 # 3477 # This program is distributed in the hope that it will be useful, but 3478 # WITHOUT ANY WARRANTY; without even the implied warranty of 3479 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 3480 # General Public License for more details. 3481 # 3482 # You should have received a copy of the GNU General Public License 3483 # along with this program; if not, write to the Free Software 3484 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 3485 # 3486 # As a special exception to the GNU General Public License, if you 3487 # distribute this file as part of a program that contains a 3488 # configuration script generated by Autoconf, you may include it under 3489 # the same distribution terms that you use for the rest of that program. 3490 3491 # PKG_PROG_PKG_CONFIG([MIN-VERSION]) 3492 # ---------------------------------- 3493 # PKG_PROG_PKG_CONFIG 3494 3495 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 3496 # 3497 # Check to see whether a particular set of modules exists. Similar 3498 # to PKG_CHECK_MODULES(), but does not set variables or print errors. 3499 # 3500 # 3501 # Similar to PKG_CHECK_MODULES, make sure that the first instance of 3502 # this or PKG_CHECK_MODULES is called, or make sure to call 3503 # PKG_CHECK_EXISTS manually 3504 # -------------------------------------------------------------- 3505 3506 3507 3508 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 3509 # --------------------------------------------- 3510 # _PKG_CONFIG 3511 3512 # _PKG_SHORT_ERRORS_SUPPORTED 3513 # ----------------------------- 3514 # _PKG_SHORT_ERRORS_SUPPORTED 3515 3516 3517 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 3518 # [ACTION-IF-NOT-FOUND]) 3519 # 3520 # 3521 # Note that if there is a possibility the first call to 3522 # PKG_CHECK_MODULES might not happen, you should be sure to include an 3523 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 3524 # 3525 # 3526 # -------------------------------------------------------------- 3527 # PKG_CHECK_MODULES 3528 3529 3530 # Include these first... 3531 # 3532 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3533 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3534 # 3535 # This code is free software; you can redistribute it and/or modify it 3536 # under the terms of the GNU General Public License version 2 only, as 3537 # published by the Free Software Foundation. Oracle designates this 3538 # particular file as subject to the "Classpath" exception as provided 3539 # by Oracle in the LICENSE file that accompanied this code. 3540 # 3541 # This code is distributed in the hope that it will be useful, but WITHOUT 3542 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3543 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3544 # version 2 for more details (a copy is included in the LICENSE file that 3545 # accompanied this code). 3546 # 3547 # You should have received a copy of the GNU General Public License version 3548 # 2 along with this work; if not, write to the Free Software Foundation, 3549 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3550 # 3551 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3552 # or visit www.oracle.com if you need additional information or have any 3553 # questions. 3554 # 3555 3556 # Create a function/macro that takes a series of named arguments. The call is 3557 # similar to AC_DEFUN, but the setup of the function looks like this: 3558 # BASIC_DEFUN_NAMED([MYFUNC], [FOO *BAR], [$@], [ 3559 # ... do something 3560 # AC_MSG_NOTICE([Value of BAR is ARG_BAR]) 3561 # ]) 3562 # A star (*) in front of a named argument means that it is required and it's 3563 # presence will be verified. To pass e.g. the first value as a normal indexed 3564 # argument, use [m4_shift($@)] as the third argument instead of [$@]. These 3565 # arguments are referenced in the function by their name prefixed by ARG_, e.g. 3566 # "ARG_FOO". 3567 # 3568 # The generated function can be called like this: 3569 # MYFUNC(FOO: [foo-val], 3570 # BAR: [ 3571 # $ECHO hello world 3572 # ]) 3573 # Note that the argument value must start on the same line as the argument name. 3574 # 3575 # Argument 1: Name of the function to define 3576 # Argument 2: List of legal named arguments, with a * prefix for required arguments 3577 # Argument 3: Argument array to treat as named, typically $@ 3578 # Argument 4: The main function body 3579 3580 3581 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3) 3582 # If so, then append $1 to $2 \ 3583 # Also set JVM_ARG_OK to true/false depending on outcome. 3584 3585 3586 # Appends a string to a path variable, only adding the : when needed. 3587 3588 3589 # Prepends a string to a path variable, only adding the : when needed. 3590 3591 3592 # This will make sure the given variable points to a full and proper 3593 # path. This means: 3594 # 1) There will be no spaces in the path. On unix platforms, 3595 # spaces in the path will result in an error. On Windows, 3596 # the path will be rewritten using short-style to be space-free. 3597 # 2) The path will be absolute, and it will be in unix-style (on 3598 # cygwin). 3599 # $1: The name of the variable to fix 3600 3601 3602 # This will make sure the given variable points to a executable 3603 # with a full and proper path. This means: 3604 # 1) There will be no spaces in the path. On unix platforms, 3605 # spaces in the path will result in an error. On Windows, 3606 # the path will be rewritten using short-style to be space-free. 3607 # 2) The path will be absolute, and it will be in unix-style (on 3608 # cygwin). 3609 # Any arguments given to the executable is preserved. 3610 # If the input variable does not have a directory specification, then 3611 # it need to be in the PATH. 3612 # $1: The name of the variable to fix 3613 3614 3615 3616 3617 # Register a --with argument but mark it as deprecated 3618 # $1: The name of the with argument to deprecate, not including --with- 3619 3620 3621 # Register a --enable argument but mark it as deprecated 3622 # $1: The name of the with argument to deprecate, not including --enable- 3623 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -) 3624 # $3: Messages to user. 3625 3626 3627 3628 3629 # Test that variable $1 denoting a program is not empty. If empty, exit with an error. 3630 # $1: variable to check 3631 3632 3633 # Check that there are no unprocessed overridden variables left. 3634 # If so, they are an incorrect argument and we will exit with an error. 3635 3636 3637 # Setup a tool for the given variable. If correctly specified by the user, 3638 # use that value, otherwise search for the tool using the supplied code snippet. 3639 # $1: variable to set 3640 # $2: code snippet to call to look for the tool 3641 # $3: code snippet to call if variable was used to find tool 3642 3643 3644 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool 3645 # $1: variable to set 3646 # $2: executable name (or list of names) to look for 3647 # $3: [path] 3648 3649 3650 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool 3651 # $1: variable to set 3652 # $2: executable name (or list of names) to look for 3653 3654 3655 # Like BASIC_PATH_PROGS but fails if no tool was found. 3656 # $1: variable to set 3657 # $2: executable name (or list of names) to look for 3658 # $3: [path] 3659 3660 3661 # Like BASIC_SETUP_TOOL but fails if no tool was found. 3662 # $1: variable to set 3663 # $2: autoconf macro to call to look for the special tool 3664 3665 3666 # Setup the most fundamental tools that relies on not much else to set up, 3667 # but is used by much of the early bootstrap code. 3668 3669 3670 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3671 3672 3673 # Evaluates platform specific overrides for devkit variables. 3674 # $1: Name of variable 3675 3676 3677 3678 3679 3680 3681 #%%% Simple tools %%% 3682 3683 # Check if we have found a usable version of make 3684 # $1: the path to a potential make binary (or empty) 3685 # $2: the description on how we found this 3686 3687 3688 3689 3690 # Goes looking for a usable version of GNU make. 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 # Check if build directory is on local disk. If not possible to determine, 3702 # we prefer to claim it's local. 3703 # Argument 1: directory to test 3704 # Argument 2: what to do if it is on local disk 3705 # Argument 3: what to do otherwise (remote disk or failure) 3706 3707 3708 # Check that source files have basic read permissions set. This might 3709 # not be the case in cygwin in certain conditions. 3710 3711 3712 3713 3714 # Check for support for specific options in bash 3715 3716 3717 ################################################################################ 3718 # 3719 # Default make target 3720 # 3721 3722 3723 # Code to run after AC_OUTPUT 3724 3725 3726 # 3727 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3728 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3729 # 3730 # This code is free software; you can redistribute it and/or modify it 3731 # under the terms of the GNU General Public License version 2 only, as 3732 # published by the Free Software Foundation. Oracle designates this 3733 # particular file as subject to the "Classpath" exception as provided 3734 # by Oracle in the LICENSE file that accompanied this code. 3735 # 3736 # This code is distributed in the hope that it will be useful, but WITHOUT 3737 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3738 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3739 # version 2 for more details (a copy is included in the LICENSE file that 3740 # accompanied this code). 3741 # 3742 # You should have received a copy of the GNU General Public License version 3743 # 2 along with this work; if not, write to the Free Software Foundation, 3744 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3745 # 3746 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3747 # or visit www.oracle.com if you need additional information or have any 3748 # questions. 3749 # 3750 3751 3752 3753 3754 3755 # Helper function which possibly converts a path using DOS-style short mode. 3756 # If so, the updated path is stored in $new_path. 3757 # $1: The path to check 3758 3759 3760 # Helper function which possibly converts a path using DOS-style short mode. 3761 # If so, the updated path is stored in $new_path. 3762 # $1: The path to check 3763 3764 3765 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted 3766 # and could probably be heavily simplified. However, all changes in this 3767 # area tend to need lot of testing in different scenarios, and in lack of 3768 # proper unit testing, cleaning this up has not been deemed worth the effort 3769 # at the moment. 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3780 3781 3782 3783 3784 # ... then the rest 3785 # 3786 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3787 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3788 # 3789 # This code is free software; you can redistribute it and/or modify it 3790 # under the terms of the GNU General Public License version 2 only, as 3791 # published by the Free Software Foundation. Oracle designates this 3792 # particular file as subject to the "Classpath" exception as provided 3793 # by Oracle in the LICENSE file that accompanied this code. 3794 # 3795 # This code is distributed in the hope that it will be useful, but WITHOUT 3796 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3797 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3798 # version 2 for more details (a copy is included in the LICENSE file that 3799 # accompanied this code). 3800 # 3801 # You should have received a copy of the GNU General Public License version 3802 # 2 along with this work; if not, write to the Free Software Foundation, 3803 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3804 # 3805 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3806 # or visit www.oracle.com if you need additional information or have any 3807 # questions. 3808 # 3809 3810 ######################################################################## 3811 # This file handles detection of the Boot JDK. The Boot JDK detection 3812 # process has been developed as a response to solve a complex real-world 3813 # problem. Initially, it was simple, but it has grown as platform after 3814 # platform, idiosyncracy after idiosyncracy has been supported. 3815 # 3816 # The basic idea is this: 3817 # 1) You need an acceptable *) JDK to use as a Boot JDK 3818 # 2) There are several ways to locate a JDK, that are mostly platform 3819 # dependent **) 3820 # 3) You can have multiple JDKs installed 3821 # 4) If possible, configure should try to dig out an acceptable JDK 3822 # automatically, without having to resort to command-line options 3823 # 3824 # *) acceptable means e.g. JDK7 for building JDK8, a complete JDK (with 3825 # javac) and not a JRE, etc. 3826 # 3827 # **) On Windows we typically use a well-known path. 3828 # On MacOSX we typically use the tool java_home. 3829 # On Linux we typically find javac in the $PATH, and then follow a 3830 # chain of symlinks that often ends up in a real JDK. 3831 # 3832 # This leads to the code where we check in different ways to locate a 3833 # JDK, and if one is found, check if it is acceptable. If not, we print 3834 # our reasons for rejecting it (useful when debugging non-working 3835 # configure situations) and continue checking the next one. 3836 ######################################################################## 3837 3838 # Execute the check given as argument, and verify the result 3839 # If the Boot JDK was previously found, do nothing 3840 # $1 A command line (typically autoconf macro) to execute 3841 3842 3843 # Test: Is bootjdk explicitly set by command line arguments? 3844 3845 3846 # Test: Is $JAVA_HOME set? 3847 3848 3849 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 3850 3851 3852 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 3853 # $1: Argument to the java_home binary (optional) 3854 3855 3856 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 3857 3858 3859 # Look for a jdk in the given path. If there are multiple, try to select the newest. 3860 # If found, set BOOT_JDK and BOOT_JDK_FOUND. 3861 # $1 = Path to directory containing jdk installations. 3862 # $2 = String to append to the found JDK directory to get the proper JDK home 3863 3864 3865 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given 3866 # environmental variable as base for where to look. 3867 # $1 Name of an environmal variable, assumed to point to the Program Files directory. 3868 3869 3870 # Test: Is there a JDK installed in default, well-known locations? 3871 3872 3873 # Check that a command-line tool in the Boot JDK is correct 3874 # $1 = name of variable to assign 3875 # $2 = name of binary 3876 3877 3878 ############################################################################### 3879 # 3880 # We need a Boot JDK to bootstrap the build. 3881 # 3882 3883 3884 3885 3886 3887 # BUILD_JDK: the location of the latest JDK that can run 3888 # on the host system and supports the target class file version 3889 # generated in this JDK build. This variable should only be 3890 # used after the launchers are built. 3891 # 3892 3893 # Execute the check given as argument, and verify the result. 3894 # If the JDK was previously found, do nothing. 3895 # $1 A command line (typically autoconf macro) to execute 3896 3897 3898 # By default the BUILD_JDK is the JDK_OUTPUTDIR. If the target architecture 3899 # is different than the host system doing the build (e.g. cross-compilation), 3900 # a special BUILD_JDK is built as part of the build process. An external 3901 # prebuilt BUILD_JDK can also be supplied. 3902 3903 3904 # 3905 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3906 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3907 # 3908 # This code is free software; you can redistribute it and/or modify it 3909 # under the terms of the GNU General Public License version 2 only, as 3910 # published by the Free Software Foundation. Oracle designates this 3911 # particular file as subject to the "Classpath" exception as provided 3912 # by Oracle in the LICENSE file that accompanied this code. 3913 # 3914 # This code is distributed in the hope that it will be useful, but WITHOUT 3915 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3916 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3917 # version 2 for more details (a copy is included in the LICENSE file that 3918 # accompanied this code). 3919 # 3920 # You should have received a copy of the GNU General Public License version 3921 # 2 along with this work; if not, write to the Free Software Foundation, 3922 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3923 # 3924 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3925 # or visit www.oracle.com if you need additional information or have any 3926 # questions. 3927 # 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 ################################################################################ 3946 # 3947 # Runs icecc-create-env once and prints the error if it fails 3948 # 3949 # $1: arguments to icecc-create-env 3950 # $2: log file 3951 # 3952 3953 3954 ################################################################################ 3955 # 3956 # Optionally enable distributed compilation of native code using icecc/icecream 3957 # 3958 3959 3960 3961 3962 3963 3964 3965 # 3966 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3967 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3968 # 3969 # This code is free software; you can redistribute it and/or modify it 3970 # under the terms of the GNU General Public License version 2 only, as 3971 # published by the Free Software Foundation. Oracle designates this 3972 # particular file as subject to the "Classpath" exception as provided 3973 # by Oracle in the LICENSE file that accompanied this code. 3974 # 3975 # This code is distributed in the hope that it will be useful, but WITHOUT 3976 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3977 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3978 # version 2 for more details (a copy is included in the LICENSE file that 3979 # accompanied this code). 3980 # 3981 # You should have received a copy of the GNU General Public License version 3982 # 2 along with this work; if not, write to the Free Software Foundation, 3983 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3984 # 3985 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3986 # or visit www.oracle.com if you need additional information or have any 3987 # questions. 3988 # 3989 3990 ################################################################################ 3991 # 3992 # Setup ABI profile (for arm) 3993 # 3994 3995 3996 # Reset the global CFLAGS/LDFLAGS variables and initialize them with the 3997 # corresponding configure arguments instead 3998 3999 4000 # Setup the sysroot flags and add them to global CFLAGS and LDFLAGS so 4001 # that configure can use them while detecting compilers. 4002 # TOOLCHAIN_TYPE is available here. 4003 # Param 1 - Optional prefix to all variables. (e.g BUILD_) 4004 4005 4006 4007 4008 4009 4010 # Documentation on common flags used for solstudio in HIGHEST. 4011 # 4012 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be 4013 # done with care, there are some assumptions below that need to 4014 # be understood about the use of pointers, and IEEE behavior. 4015 # 4016 # -fns: Use non-standard floating point mode (not IEEE 754) 4017 # -fsimple: Do some simplification of floating point arithmetic (not IEEE 754) 4018 # -fsingle: Use single precision floating point with 'float' 4019 # -xalias_level=basic: Assume memory references via basic pointer types do not alias 4020 # (Source with excessing pointer casting and data access with mixed 4021 # pointer types are not recommended) 4022 # -xbuiltin=%all: Use intrinsic or inline versions for math/std functions 4023 # (If you expect perfect errno behavior, do not use this) 4024 # -xdepend: Loop data dependency optimizations (need -xO3 or higher) 4025 # -xrestrict: Pointer parameters to functions do not overlap 4026 # (Similar to -xalias_level=basic usage, but less obvious sometimes. 4027 # If you pass in multiple pointers to the same data, do not use this) 4028 # -xlibmil: Inline some library routines 4029 # (If you expect perfect errno behavior, do not use this) 4030 # -xlibmopt: Use optimized math routines (CURRENTLY DISABLED) 4031 # (If you expect perfect errno behavior, do not use this) 4032 # Can cause undefined external on Solaris 8 X86 on __sincos, removing for now 4033 4034 # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore. 4035 # Bug? 4036 #if test "x$OPENJDK_TARGET_CPU" = xsparc; then 4037 # CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s" 4038 # CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s" 4039 #fi 4040 4041 4042 4043 4044 4045 4046 ################################################################################ 4047 # $1 - Either BUILD or TARGET to pick the correct OS/CPU variables to check 4048 # conditionals against. 4049 # $2 - Optional prefix for each variable defined. 4050 4051 4052 # FLAGS_C_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4053 # IF_FALSE: [RUN-IF-FALSE]) 4054 # ------------------------------------------------------------ 4055 # Check that the C compiler supports an argument 4056 4057 4058 4059 4060 # FLAGS_CXX_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4061 # IF_FALSE: [RUN-IF-FALSE]) 4062 # ------------------------------------------------------------ 4063 # Check that the C++ compiler supports an argument 4064 4065 4066 4067 4068 # FLAGS_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4069 # IF_FALSE: [RUN-IF-FALSE]) 4070 # ------------------------------------------------------------ 4071 # Check that the C and C++ compilers support an argument 4072 4073 4074 4075 4076 # FLAGS_LINKER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4077 # IF_FALSE: [RUN-IF-FALSE]) 4078 # ------------------------------------------------------------ 4079 # Check that the linker support an argument 4080 4081 4082 4083 4084 4085 4086 # FLAGS_SETUP_GCC6_COMPILER_FLAGS([PREFIX]) 4087 # Arguments: 4088 # $1 - Optional prefix for each variable defined. 4089 4090 4091 # 4092 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4093 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4094 # 4095 # This code is free software; you can redistribute it and/or modify it 4096 # under the terms of the GNU General Public License version 2 only, as 4097 # published by the Free Software Foundation. Oracle designates this 4098 # particular file as subject to the "Classpath" exception as provided 4099 # by Oracle in the LICENSE file that accompanied this code. 4100 # 4101 # This code is distributed in the hope that it will be useful, but WITHOUT 4102 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4103 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4104 # version 2 for more details (a copy is included in the LICENSE file that 4105 # accompanied this code). 4106 # 4107 # You should have received a copy of the GNU General Public License version 4108 # 2 along with this work; if not, write to the Free Software Foundation, 4109 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4110 # 4111 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4112 # or visit www.oracle.com if you need additional information or have any 4113 # questions. 4114 # 4115 4116 4117 4118 4119 4120 cygwin_help() { 4121 case $1 in 4122 unzip) 4123 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )" 4124 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4125 ;; 4126 zip) 4127 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )" 4128 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4129 ;; 4130 make) 4131 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )" 4132 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4133 ;; 4134 freetype) 4135 HELP_MSG=" 4136 The freetype library can now be build during the configure process. 4137 Download the freetype sources and unpack them into an arbitrary directory: 4138 4139 wget http://download.savannah.gnu.org/releases/freetype/freetype-2.5.3.tar.gz 4140 tar -xzf freetype-2.5.3.tar.gz 4141 4142 Then run configure with '--with-freetype-src=<freetype_src>'. This will 4143 automatically build the freetype library into '<freetype_src>/lib64' for 64-bit 4144 builds or into '<freetype_src>/lib32' for 32-bit builds. 4145 Afterwards you can always use '--with-freetype-include=<freetype_src>/include' 4146 and '--with-freetype-lib=<freetype_src>/lib32|64' for other builds. 4147 4148 Alternatively you can unpack the sources like this to use the default directory: 4149 4150 tar --one-top-level=$HOME/freetype --strip-components=1 -xzf freetype-2.5.3.tar.gz" 4151 ;; 4152 esac 4153 } 4154 4155 msys_help() { 4156 PKGHANDLER_COMMAND="" 4157 } 4158 4159 apt_help() { 4160 case $1 in 4161 reduced) 4162 PKGHANDLER_COMMAND="sudo apt-get install gcc-multilib g++-multilib" ;; 4163 devkit) 4164 PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;; 4165 openjdk) 4166 PKGHANDLER_COMMAND="sudo apt-get install openjdk-8-jdk" ;; 4167 alsa) 4168 PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;; 4169 cups) 4170 PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;; 4171 freetype) 4172 PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;; 4173 ffi) 4174 PKGHANDLER_COMMAND="sudo apt-get install libffi-dev" ;; 4175 x11) 4176 PKGHANDLER_COMMAND="sudo apt-get install libx11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;; 4177 ccache) 4178 PKGHANDLER_COMMAND="sudo apt-get install ccache" ;; 4179 dtrace) 4180 PKGHANDLER_COMMAND="sudo apt-get install systemtap-sdt-dev" ;; 4181 esac 4182 } 4183 4184 yum_help() { 4185 case $1 in 4186 devkit) 4187 PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;; 4188 openjdk) 4189 PKGHANDLER_COMMAND="sudo yum install java-1.8.0-openjdk-devel" ;; 4190 alsa) 4191 PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;; 4192 cups) 4193 PKGHANDLER_COMMAND="sudo yum install cups-devel" ;; 4194 freetype) 4195 PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;; 4196 x11) 4197 PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel libXi-devel" ;; 4198 ccache) 4199 PKGHANDLER_COMMAND="sudo yum install ccache" ;; 4200 esac 4201 } 4202 4203 brew_help() { 4204 case $1 in 4205 openjdk) 4206 PKGHANDLER_COMMAND="brew cask install java" ;; 4207 freetype) 4208 PKGHANDLER_COMMAND="brew install freetype" ;; 4209 ccache) 4210 PKGHANDLER_COMMAND="brew install ccache" ;; 4211 esac 4212 } 4213 4214 port_help() { 4215 PKGHANDLER_COMMAND="" 4216 } 4217 4218 pkgutil_help() { 4219 PKGHANDLER_COMMAND="" 4220 } 4221 4222 pkgadd_help() { 4223 PKGHANDLER_COMMAND="" 4224 } 4225 4226 # This function will check if we're called from the "configure" wrapper while 4227 # printing --help. If so, we will print out additional information that can 4228 # only be extracted within the autoconf script, and then exit. This must be 4229 # called at the very beginning in configure.ac. 4230 4231 4232 4233 4234 4235 4236 # 4237 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4238 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4239 # 4240 # This code is free software; you can redistribute it and/or modify it 4241 # under the terms of the GNU General Public License version 2 only, as 4242 # published by the Free Software Foundation. Oracle designates this 4243 # particular file as subject to the "Classpath" exception as provided 4244 # by Oracle in the LICENSE file that accompanied this code. 4245 # 4246 # This code is distributed in the hope that it will be useful, but WITHOUT 4247 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4248 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4249 # version 2 for more details (a copy is included in the LICENSE file that 4250 # accompanied this code). 4251 # 4252 # You should have received a copy of the GNU General Public License version 4253 # 2 along with this work; if not, write to the Free Software Foundation, 4254 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4255 # 4256 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4257 # or visit www.oracle.com if you need additional information or have any 4258 # questions. 4259 # 4260 4261 # All valid JVM features, regardless of platform 4262 VALID_JVM_FEATURES="compiler1 compiler2 zero shark minimal dtrace jvmti jvmci \ 4263 graal vm-structs jni-check services management all-gcs nmt cds \ 4264 static-build link-time-opt aot" 4265 4266 # All valid JVM variants 4267 VALID_JVM_VARIANTS="server client minimal core zero zeroshark custom" 4268 4269 ############################################################################### 4270 # Check if the specified JVM variant should be built. To be used in shell if 4271 # constructs, like this: 4272 # if HOTSPOT_CHECK_JVM_VARIANT(server); then 4273 # 4274 # Only valid to use after HOTSPOT_SETUP_JVM_VARIANTS has setup variants. 4275 4276 # Definition kept in one line to allow inlining in if statements. 4277 # Additional [] needed to keep m4 from mangling shell constructs. 4278 4279 4280 ############################################################################### 4281 # Check if the specified JVM features are explicitly enabled. To be used in 4282 # shell if constructs, like this: 4283 # if HOTSPOT_CHECK_JVM_FEATURE(jvmti); then 4284 # 4285 # Only valid to use after HOTSPOT_SETUP_JVM_FEATURES has setup features. 4286 4287 # Definition kept in one line to allow inlining in if statements. 4288 # Additional [] needed to keep m4 from mangling shell constructs. 4289 4290 4291 ############################################################################### 4292 # Check which variants of the JVM that we want to build. Available variants are: 4293 # server: normal interpreter, and a tiered C1/C2 compiler 4294 # client: normal interpreter, and C1 (no C2 compiler) 4295 # minimal: reduced form of client with optional features stripped out 4296 # core: normal interpreter only, no compiler 4297 # zero: C++ based interpreter only, no compiler 4298 # zeroshark: C++ based interpreter, and a llvm-based compiler 4299 # custom: baseline JVM with no default features 4300 # 4301 4302 4303 ############################################################################### 4304 # Check if dtrace should be enabled and has all prerequisites present. 4305 # 4306 4307 4308 ################################################################################ 4309 # Check if AOT should be enabled 4310 # 4311 4312 4313 ################################################################################ 4314 # Allow to disable CDS 4315 # 4316 4317 4318 ############################################################################### 4319 # Set up all JVM features for each JVM variant. 4320 # 4321 4322 4323 ############################################################################### 4324 # Validate JVM features once all setup is complete, including custom setup. 4325 # 4326 4327 4328 ################################################################################ 4329 # 4330 # Specify which sources will be used to build the 64-bit ARM port 4331 # 4332 # --with-cpu-port=arm64 will use hotspot/src/cpu/arm 4333 # --with-cpu-port=aarch64 will use hotspot/src/cpu/aarch64 4334 # 4335 4336 4337 4338 ################################################################################ 4339 # Check if gtest should be built 4340 # 4341 4342 4343 # 4344 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4345 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4346 # 4347 # This code is free software; you can redistribute it and/or modify it 4348 # under the terms of the GNU General Public License version 2 only, as 4349 # published by the Free Software Foundation. Oracle designates this 4350 # particular file as subject to the "Classpath" exception as provided 4351 # by Oracle in the LICENSE file that accompanied this code. 4352 # 4353 # This code is distributed in the hope that it will be useful, but WITHOUT 4354 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4355 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4356 # version 2 for more details (a copy is included in the LICENSE file that 4357 # accompanied this code). 4358 # 4359 # You should have received a copy of the GNU General Public License version 4360 # 2 along with this work; if not, write to the Free Software Foundation, 4361 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4362 # 4363 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4364 # or visit www.oracle.com if you need additional information or have any 4365 # questions. 4366 # 4367 4368 ############################################################################### 4369 # Check which variant of the JDK that we want to build. 4370 # Currently we have: 4371 # normal: standard edition 4372 # but the custom make system may add other variants 4373 # 4374 # Effectively the JDK variant gives a name to a specific set of 4375 # modules to compile into the JDK. 4376 4377 4378 ############################################################################### 4379 # Set the debug level 4380 # release: no debug information, all optimizations, no asserts. 4381 # optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'. 4382 # fastdebug: debug information (-g), all optimizations, all asserts 4383 # slowdebug: debug information (-g), no optimizations, all asserts 4384 4385 4386 ############################################################################### 4387 # 4388 # Should we build only OpenJDK even if closed sources are present? 4389 # 4390 4391 4392 4393 4394 ############################################################################### 4395 # 4396 # Enable or disable the elliptic curve crypto implementation 4397 # 4398 4399 4400 4401 4402 ################################################################################ 4403 # 4404 # Gcov coverage data for hotspot 4405 # 4406 4407 4408 ################################################################################ 4409 # 4410 # Static build support. When enabled will generate static 4411 # libraries instead of shared libraries for all JDK libs. 4412 # 4413 4414 4415 ################################################################################ 4416 # 4417 # jlink options. 4418 # We always keep packaged modules in JDK image. 4419 # 4420 4421 4422 ################################################################################ 4423 # 4424 # Check if building of the jtreg failure handler should be enabled. 4425 # 4426 4427 4428 ################################################################################ 4429 # 4430 # Enable or disable generation of the classlist at build time 4431 # 4432 4433 4434 # 4435 # Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. 4436 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4437 # 4438 # This code is free software; you can redistribute it and/or modify it 4439 # under the terms of the GNU General Public License version 2 only, as 4440 # published by the Free Software Foundation. Oracle designates this 4441 # particular file as subject to the "Classpath" exception as provided 4442 # by Oracle in the LICENSE file that accompanied this code. 4443 # 4444 # This code is distributed in the hope that it will be useful, but WITHOUT 4445 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4446 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4447 # version 2 for more details (a copy is included in the LICENSE file that 4448 # accompanied this code). 4449 # 4450 # You should have received a copy of the GNU General Public License version 4451 # 2 along with this work; if not, write to the Free Software Foundation, 4452 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4453 # 4454 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4455 # or visit www.oracle.com if you need additional information or have any 4456 # questions. 4457 # 4458 4459 ############################################################################### 4460 # 4461 # Setup version numbers 4462 # 4463 4464 # Verify that a given string represents a valid version number, and assign it 4465 # to a variable. 4466 4467 # Argument 1: the variable to assign to 4468 # Argument 2: the value given by the user 4469 4470 4471 4472 4473 # 4474 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4475 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4476 # 4477 # This code is free software; you can redistribute it and/or modify it 4478 # under the terms of the GNU General Public License version 2 only, as 4479 # published by the Free Software Foundation. Oracle designates this 4480 # particular file as subject to the "Classpath" exception as provided 4481 # by Oracle in the LICENSE file that accompanied this code. 4482 # 4483 # This code is distributed in the hope that it will be useful, but WITHOUT 4484 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4485 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4486 # version 2 for more details (a copy is included in the LICENSE file that 4487 # accompanied this code). 4488 # 4489 # You should have received a copy of the GNU General Public License version 4490 # 2 along with this work; if not, write to the Free Software Foundation, 4491 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4492 # 4493 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4494 # or visit www.oracle.com if you need additional information or have any 4495 # questions. 4496 # 4497 4498 # Major library component reside in separate files. 4499 # 4500 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4501 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4502 # 4503 # This code is free software; you can redistribute it and/or modify it 4504 # under the terms of the GNU General Public License version 2 only, as 4505 # published by the Free Software Foundation. Oracle designates this 4506 # particular file as subject to the "Classpath" exception as provided 4507 # by Oracle in the LICENSE file that accompanied this code. 4508 # 4509 # This code is distributed in the hope that it will be useful, but WITHOUT 4510 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4511 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4512 # version 2 for more details (a copy is included in the LICENSE file that 4513 # accompanied this code). 4514 # 4515 # You should have received a copy of the GNU General Public License version 4516 # 2 along with this work; if not, write to the Free Software Foundation, 4517 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4518 # 4519 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4520 # or visit www.oracle.com if you need additional information or have any 4521 # questions. 4522 # 4523 4524 ################################################################################ 4525 # Setup alsa (Advanced Linux Sound Architecture) 4526 ################################################################################ 4527 4528 4529 # 4530 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4531 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4532 # 4533 # This code is free software; you can redistribute it and/or modify it 4534 # under the terms of the GNU General Public License version 2 only, as 4535 # published by the Free Software Foundation. Oracle designates this 4536 # particular file as subject to the "Classpath" exception as provided 4537 # by Oracle in the LICENSE file that accompanied this code. 4538 # 4539 # This code is distributed in the hope that it will be useful, but WITHOUT 4540 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4541 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4542 # version 2 for more details (a copy is included in the LICENSE file that 4543 # accompanied this code). 4544 # 4545 # You should have received a copy of the GNU General Public License version 4546 # 2 along with this work; if not, write to the Free Software Foundation, 4547 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4548 # 4549 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4550 # or visit www.oracle.com if you need additional information or have any 4551 # questions. 4552 # 4553 4554 ################################################################################ 4555 # Setup bundled libraries. 4556 # 4557 # For libjpeg, giflib, libpng, lcms2 and zlib, the source is present in the 4558 # OpenJDK repository. Default is to use these libraries as bundled, but they 4559 # might be replaced by en external version by the user. 4560 ################################################################################ 4561 4562 4563 ################################################################################ 4564 # Setup libjpeg 4565 ################################################################################ 4566 4567 4568 ################################################################################ 4569 # Setup giflib 4570 ################################################################################ 4571 4572 4573 ################################################################################ 4574 # Setup libpng 4575 ################################################################################ 4576 4577 4578 ################################################################################ 4579 # Setup zlib 4580 ################################################################################ 4581 4582 4583 ################################################################################ 4584 # Setup lcms (Little CMS) 4585 ################################################################################ 4586 4587 4588 # 4589 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4590 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4591 # 4592 # This code is free software; you can redistribute it and/or modify it 4593 # under the terms of the GNU General Public License version 2 only, as 4594 # published by the Free Software Foundation. Oracle designates this 4595 # particular file as subject to the "Classpath" exception as provided 4596 # by Oracle in the LICENSE file that accompanied this code. 4597 # 4598 # This code is distributed in the hope that it will be useful, but WITHOUT 4599 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4600 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4601 # version 2 for more details (a copy is included in the LICENSE file that 4602 # accompanied this code). 4603 # 4604 # You should have received a copy of the GNU General Public License version 4605 # 2 along with this work; if not, write to the Free Software Foundation, 4606 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4607 # 4608 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4609 # or visit www.oracle.com if you need additional information or have any 4610 # questions. 4611 # 4612 4613 ################################################################################ 4614 # Setup cups (Common Unix Printing System) 4615 ################################################################################ 4616 4617 4618 # 4619 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4620 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4621 # 4622 # This code is free software; you can redistribute it and/or modify it 4623 # under the terms of the GNU General Public License version 2 only, as 4624 # published by the Free Software Foundation. Oracle designates this 4625 # particular file as subject to the "Classpath" exception as provided 4626 # by Oracle in the LICENSE file that accompanied this code. 4627 # 4628 # This code is distributed in the hope that it will be useful, but WITHOUT 4629 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4630 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4631 # version 2 for more details (a copy is included in the LICENSE file that 4632 # accompanied this code). 4633 # 4634 # You should have received a copy of the GNU General Public License version 4635 # 2 along with this work; if not, write to the Free Software Foundation, 4636 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4637 # 4638 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4639 # or visit www.oracle.com if you need additional information or have any 4640 # questions. 4641 # 4642 4643 ################################################################################ 4644 # Setup libffi (Foreign Function Interface) 4645 ################################################################################ 4646 4647 4648 # 4649 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4650 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4651 # 4652 # This code is free software; you can redistribute it and/or modify it 4653 # under the terms of the GNU General Public License version 2 only, as 4654 # published by the Free Software Foundation. Oracle designates this 4655 # particular file as subject to the "Classpath" exception as provided 4656 # by Oracle in the LICENSE file that accompanied this code. 4657 # 4658 # This code is distributed in the hope that it will be useful, but WITHOUT 4659 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4660 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4661 # version 2 for more details (a copy is included in the LICENSE file that 4662 # accompanied this code). 4663 # 4664 # You should have received a copy of the GNU General Public License version 4665 # 2 along with this work; if not, write to the Free Software Foundation, 4666 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4667 # 4668 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4669 # or visit www.oracle.com if you need additional information or have any 4670 # questions. 4671 # 4672 4673 ################################################################################ 4674 # Build the freetype lib from source 4675 ################################################################################ 4676 4677 4678 ################################################################################ 4679 # Check if a potential freeype library match is correct and usable 4680 ################################################################################ 4681 4682 4683 ################################################################################ 4684 # Setup freetype (The FreeType2 font rendering library) 4685 ################################################################################ 4686 4687 4688 # 4689 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4690 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4691 # 4692 # This code is free software; you can redistribute it and/or modify it 4693 # under the terms of the GNU General Public License version 2 only, as 4694 # published by the Free Software Foundation. Oracle designates this 4695 # particular file as subject to the "Classpath" exception as provided 4696 # by Oracle in the LICENSE file that accompanied this code. 4697 # 4698 # This code is distributed in the hope that it will be useful, but WITHOUT 4699 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4700 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4701 # version 2 for more details (a copy is included in the LICENSE file that 4702 # accompanied this code). 4703 # 4704 # You should have received a copy of the GNU General Public License version 4705 # 2 along with this work; if not, write to the Free Software Foundation, 4706 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4707 # 4708 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4709 # or visit www.oracle.com if you need additional information or have any 4710 # questions. 4711 # 4712 4713 ################################################################################ 4714 # Setup the standard C/C++ runtime libraries. 4715 # 4716 # Most importantly, determine if stdc++ should be linked statically or 4717 # dynamically. 4718 ################################################################################ 4719 4720 4721 # 4722 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4723 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4724 # 4725 # This code is free software; you can redistribute it and/or modify it 4726 # under the terms of the GNU General Public License version 2 only, as 4727 # published by the Free Software Foundation. Oracle designates this 4728 # particular file as subject to the "Classpath" exception as provided 4729 # by Oracle in the LICENSE file that accompanied this code. 4730 # 4731 # This code is distributed in the hope that it will be useful, but WITHOUT 4732 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4733 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4734 # version 2 for more details (a copy is included in the LICENSE file that 4735 # accompanied this code). 4736 # 4737 # You should have received a copy of the GNU General Public License version 4738 # 2 along with this work; if not, write to the Free Software Foundation, 4739 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4740 # 4741 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4742 # or visit www.oracle.com if you need additional information or have any 4743 # questions. 4744 # 4745 4746 ################################################################################ 4747 # Setup X11 Windows system 4748 ################################################################################ 4749 4750 4751 4752 ################################################################################ 4753 # Determine which libraries are needed for this configuration 4754 ################################################################################ 4755 4756 4757 ################################################################################ 4758 # Parse library options, and setup needed libraries 4759 ################################################################################ 4760 4761 4762 ################################################################################ 4763 # Setup llvm (Low-Level VM) 4764 ################################################################################ 4765 4766 4767 ################################################################################ 4768 # Setup various libraries, typically small system libraries 4769 ################################################################################ 4770 4771 4772 ################################################################################ 4773 # libstlport.so.1 is needed for running gtest on Solaris. Find it to 4774 # redistribute it in the test image. 4775 ################################################################################ 4776 4777 4778 4779 # 4780 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4781 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4782 # 4783 # This code is free software; you can redistribute it and/or modify it 4784 # under the terms of the GNU General Public License version 2 only, as 4785 # published by the Free Software Foundation. Oracle designates this 4786 # particular file as subject to the "Classpath" exception as provided 4787 # by Oracle in the LICENSE file that accompanied this code. 4788 # 4789 # This code is distributed in the hope that it will be useful, but WITHOUT 4790 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4791 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4792 # version 2 for more details (a copy is included in the LICENSE file that 4793 # accompanied this code). 4794 # 4795 # You should have received a copy of the GNU General Public License version 4796 # 2 along with this work; if not, write to the Free Software Foundation, 4797 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4798 # 4799 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4800 # or visit www.oracle.com if you need additional information or have any 4801 # questions. 4802 # 4803 4804 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4805 # Converts autoconf style CPU name to OpenJDK style, into 4806 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN. 4807 4808 4809 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4810 # Converts autoconf style OS name to OpenJDK style, into 4811 # VAR_OS, VAR_OS_TYPE and VAR_OS_ENV. 4812 4813 4814 # Expects $host_os $host_cpu $build_os and $build_cpu 4815 # and $with_target_bits to have been setup! 4816 # 4817 # Translate the standard triplet(quadruplet) definition 4818 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU, 4819 # OPENJDK_BUILD_OS, etc. 4820 4821 4822 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour 4823 # accordingly. Must be done after setting up build and target system, but before 4824 # doing anything else with these values. 4825 4826 4827 # Setup the legacy variables, for controlling the old makefiles. 4828 # 4829 4830 4831 # $1 - Either TARGET or BUILD to setup the variables for. 4832 4833 4834 4835 4836 4837 4838 #%%% Build and target systems %%% 4839 4840 4841 4842 4843 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS. 4844 # Add -mX to various FLAGS variables. 4845 4846 4847 4848 4849 4850 4851 # 4852 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4853 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4854 # 4855 # This code is free software; you can redistribute it and/or modify it 4856 # under the terms of the GNU General Public License version 2 only, as 4857 # published by the Free Software Foundation. Oracle designates this 4858 # particular file as subject to the "Classpath" exception as provided 4859 # by Oracle in the LICENSE file that accompanied this code. 4860 # 4861 # This code is distributed in the hope that it will be useful, but WITHOUT 4862 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4863 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4864 # version 2 for more details (a copy is included in the LICENSE file that 4865 # accompanied this code). 4866 # 4867 # You should have received a copy of the GNU General Public License version 4868 # 2 along with this work; if not, write to the Free Software Foundation, 4869 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4870 # 4871 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4872 # or visit www.oracle.com if you need additional information or have any 4873 # questions. 4874 # 4875 4876 4877 4878 ################################################################################ 4879 # Define a mechanism for importing extra prebuilt modules 4880 # 4881 4882 4883 4884 # 4885 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4886 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4887 # 4888 # This code is free software; you can redistribute it and/or modify it 4889 # under the terms of the GNU General Public License version 2 only, as 4890 # published by the Free Software Foundation. Oracle designates this 4891 # particular file as subject to the "Classpath" exception as provided 4892 # by Oracle in the LICENSE file that accompanied this code. 4893 # 4894 # This code is distributed in the hope that it will be useful, but WITHOUT 4895 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4896 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4897 # version 2 for more details (a copy is included in the LICENSE file that 4898 # accompanied this code). 4899 # 4900 # You should have received a copy of the GNU General Public License version 4901 # 2 along with this work; if not, write to the Free Software Foundation, 4902 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4903 # 4904 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4905 # or visit www.oracle.com if you need additional information or have any 4906 # questions. 4907 # 4908 4909 ######################################################################## 4910 # This file is responsible for detecting, verifying and setting up the 4911 # toolchain, i.e. the compiler, linker and related utilities. It will setup 4912 # proper paths to the binaries, but it will not setup any flags. 4913 # 4914 # The binaries used is determined by the toolchain type, which is the family of 4915 # compilers and related tools that are used. 4916 ######################################################################## 4917 4918 4919 # All valid toolchains, regardless of platform (used by help.m4) 4920 VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft" 4921 4922 # These toolchains are valid on different platforms 4923 VALID_TOOLCHAINS_linux="gcc clang" 4924 VALID_TOOLCHAINS_solaris="solstudio" 4925 VALID_TOOLCHAINS_macosx="gcc clang" 4926 VALID_TOOLCHAINS_aix="xlc" 4927 VALID_TOOLCHAINS_windows="microsoft" 4928 4929 # Toolchain descriptions 4930 TOOLCHAIN_DESCRIPTION_clang="clang/LLVM" 4931 TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection" 4932 TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio" 4933 TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio" 4934 TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++" 4935 4936 # Minimum supported versions, empty means unspecified 4937 TOOLCHAIN_MINIMUM_VERSION_clang="3.2" 4938 TOOLCHAIN_MINIMUM_VERSION_gcc="4.7" 4939 TOOLCHAIN_MINIMUM_VERSION_microsoft="16.00.30319.01" # VS2010 4940 TOOLCHAIN_MINIMUM_VERSION_solstudio="5.13" 4941 TOOLCHAIN_MINIMUM_VERSION_xlc="" 4942 4943 # Prepare the system so that TOOLCHAIN_CHECK_COMPILER_VERSION can be called. 4944 # Must have CC_VERSION_NUMBER and CXX_VERSION_NUMBER. 4945 # $1 - optional variable prefix for compiler and version variables (BUILD_) 4946 # $2 - optional variable prefix for comparable variable (OPENJDK_BUILD_) 4947 4948 4949 # Check if the configured compiler (C and C++) is of a specific version or 4950 # newer. TOOLCHAIN_PREPARE_FOR_VERSION_COMPARISONS must have been called before. 4951 # 4952 # Arguments: 4953 # VERSION: The version string to check against the found version 4954 # IF_AT_LEAST: block to run if the compiler is at least this version (>=) 4955 # IF_OLDER_THAN: block to run if the compiler is older than this version (<) 4956 # PREFIX: Optional variable prefix for compiler to compare version for (OPENJDK_BUILD_) 4957 4958 4959 4960 4961 # Setup a number of variables describing how native output files are 4962 # named on this platform/toolchain. 4963 4964 4965 # Determine which toolchain type to use, and make sure it is valid for this 4966 # platform. Setup various information about the selected toolchain. 4967 4968 4969 # Before we start detecting the toolchain executables, we might need some 4970 # special setup, e.g. additional paths etc. 4971 4972 4973 # Restore path, etc 4974 4975 4976 # Check if a compiler is of the toolchain type we expect, and save the version 4977 # information from it. If the compiler does not match the expected type, 4978 # this function will abort using AC_MSG_ERROR. If it matches, the version will 4979 # be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and 4980 # the full version string in CC_VERSION_STRING/CXX_VERSION_STRING. 4981 # 4982 # $1 = compiler to test (CC or CXX) 4983 # $2 = human readable name of compiler (C or C++) 4984 4985 4986 # Try to locate the given C or C++ compiler in the path, or otherwise. 4987 # 4988 # $1 = compiler to test (CC or CXX) 4989 # $2 = human readable name of compiler (C or C++) 4990 # $3 = compiler name to search for 4991 4992 4993 # Detect the core components of the toolchain, i.e. the compilers (CC and CXX), 4994 # preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the 4995 # archiver (AR). Verify that the compilers are correct according to the 4996 # toolchain type. 4997 4998 4999 # Setup additional tools that is considered a part of the toolchain, but not the 5000 # core part. Many of these are highly platform-specific and do not exist, 5001 # and/or are not needed on all platforms. 5002 5003 5004 # Setup the build tools (i.e, the compiler and linker used to build programs 5005 # that should be run on the build platform, not the target platform, as a build 5006 # helper). Since the non-cross-compile case uses the normal, target compilers 5007 # for this, we can only do this after these have been setup. 5008 5009 5010 # Do some additional checks on the detected tools. 5011 5012 5013 # Setup the JTReg Regression Test Harness. 5014 5015 5016 # Setup the JIB dependency resolver 5017 5018 5019 # 5020 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 5021 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 5022 # 5023 # This code is free software; you can redistribute it and/or modify it 5024 # under the terms of the GNU General Public License version 2 only, as 5025 # published by the Free Software Foundation. Oracle designates this 5026 # particular file as subject to the "Classpath" exception as provided 5027 # by Oracle in the LICENSE file that accompanied this code. 5028 # 5029 # This code is distributed in the hope that it will be useful, but WITHOUT 5030 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 5031 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 5032 # version 2 for more details (a copy is included in the LICENSE file that 5033 # accompanied this code). 5034 # 5035 # You should have received a copy of the GNU General Public License version 5036 # 2 along with this work; if not, write to the Free Software Foundation, 5037 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 5038 # 5039 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 5040 # or visit www.oracle.com if you need additional information or have any 5041 # questions. 5042 # 5043 5044 ################################################################################ 5045 # The order of these defines the priority by which we try to find them. 5046 VALID_VS_VERSIONS="2013 2012 2010" 5047 5048 VS_DESCRIPTION_2010="Microsoft Visual Studio 2010" 5049 VS_VERSION_INTERNAL_2010=100 5050 VS_MSVCR_2010=msvcr100.dll 5051 # We don't use msvcp on Visual Studio 2010 5052 #VS_MSVCP_2010=msvcp100.dll 5053 VS_ENVVAR_2010="VS100COMNTOOLS" 5054 VS_VS_INSTALLDIR_2010="Microsoft Visual Studio 10.0" 5055 VS_SDK_INSTALLDIR_2010="Microsoft SDKs/Windows/v7.1" 5056 VS_VS_PLATFORM_NAME_2010="v100" 5057 VS_SDK_PLATFORM_NAME_2010="Windows7.1SDK" 5058 5059 VS_DESCRIPTION_2012="Microsoft Visual Studio 2012" 5060 VS_VERSION_INTERNAL_2012=110 5061 VS_MSVCR_2012=msvcr110.dll 5062 VS_MSVCP_2012=msvcp110.dll 5063 VS_ENVVAR_2012="VS110COMNTOOLS" 5064 VS_VS_INSTALLDIR_2012="Microsoft Visual Studio 11.0" 5065 VS_SDK_INSTALLDIR_2012= 5066 VS_VS_PLATFORM_NAME_2012="v110" 5067 VS_SDK_PLATFORM_NAME_2012= 5068 5069 VS_DESCRIPTION_2013="Microsoft Visual Studio 2013" 5070 VS_VERSION_INTERNAL_2013=120 5071 VS_MSVCR_2013=msvcr120.dll 5072 VS_MSVCP_2013=msvcp120.dll 5073 VS_ENVVAR_2013="VS120COMNTOOLS" 5074 VS_VS_INSTALLDIR_2013="Microsoft Visual Studio 12.0" 5075 VS_SDK_INSTALLDIR_2013= 5076 VS_VS_PLATFORM_NAME_2013="v120" 5077 VS_SDK_PLATFORM_NAME_2013= 5078 5079 ################################################################################ 5080 5081 5082 5083 ################################################################################ 5084 5085 5086 5087 ################################################################################ 5088 # Finds the bat or cmd file in Visual Studio or the SDK that sets up a proper 5089 # build environment and assigns it to VS_ENV_CMD 5090 5091 5092 ################################################################################ 5093 5094 5095 5096 ################################################################################ 5097 # Check if the VS env variables were setup prior to running configure. 5098 # If not, then find vcvarsall.bat and run it automatically, and integrate 5099 # the set env variables into the spec file. 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 # This line needs to be here, verbatim, after all includes and the dummy hook 5115 # definitions. It is replaced with custom functionality when building 5116 # custom sources. 5117 #CUSTOM_AUTOCONF_INCLUDE 5118 5119 # Do not change or remove the following line, it is needed for consistency checks: 5120 DATE_WHEN_GENERATED=1507635096 5121 5122 ############################################################################### 5123 # 5124 # Initialization / Boot-strapping 5125 # 5126 # The bootstrapping process needs to solve the "chicken or the egg" problem, 5127 # thus it jumps back and forth, each time gaining something needed later on. 5128 # 5129 ############################################################################### 5130 5131 # If we are requested to print additional help, do that and then exit. 5132 # This must be the very first call. 5133 5134 if test "x$CONFIGURE_PRINT_ADDITIONAL_HELP" != x; then 5135 5136 # Print available toolchains 5137 $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n" 5138 $PRINTF "Which are valid to use depends on the build platform.\n" 5139 for toolchain in $VALID_TOOLCHAINS_all; do 5140 # Use indirect variable referencing 5141 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 5142 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 5143 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 5144 done 5145 $PRINTF "\n" 5146 5147 # Print available jvm features 5148 $PRINTF "The following JVM features are available as arguments to --with-jvm-features.\n" 5149 $PRINTF "Which are valid to use depends on the target platform.\n " 5150 $PRINTF "%s " $VALID_JVM_FEATURES 5151 $PRINTF "\n" 5152 5153 # And now exit directly 5154 exit 0 5155 fi 5156 5157 5158 # Basic initialization that must happen first of all in the normal process. 5159 5160 # Save the original command line. This is passed to us by the wrapper configure script. 5161 5162 # Save the path variable before it gets changed 5163 ORIGINAL_PATH="$PATH" 5164 5165 DATE_WHEN_CONFIGURED=`LANG=C date` 5166 5167 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5 5168 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;} 5169 { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5 5170 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;} 5171 5172 5173 # Start with tools that do not need have cross compilation support 5174 # and can be expected to be found in the default PATH. These tools are 5175 # used by configure. 5176 5177 # First are all the simple required tools. 5178 5179 5180 5181 # Publish this variable in the help. 5182 5183 5184 if [ -z "${BASENAME+x}" ]; then 5185 # The variable is not set by user, try to locate tool using the code snippet 5186 for ac_prog in basename 5187 do 5188 # Extract the first word of "$ac_prog", so it can be a program name with args. 5189 set dummy $ac_prog; ac_word=$2 5190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5191 $as_echo_n "checking for $ac_word... " >&6; } 5192 if ${ac_cv_path_BASENAME+:} false; then : 5193 $as_echo_n "(cached) " >&6 5194 else 5195 case $BASENAME in 5196 [\\/]* | ?:[\\/]*) 5197 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5198 ;; 5199 *) 5200 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5201 for as_dir in $PATH 5202 do 5203 IFS=$as_save_IFS 5204 test -z "$as_dir" && as_dir=. 5205 for ac_exec_ext in '' $ac_executable_extensions; do 5206 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5207 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5208 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5209 break 2 5210 fi 5211 done 5212 done 5213 IFS=$as_save_IFS 5214 5215 ;; 5216 esac 5217 fi 5218 BASENAME=$ac_cv_path_BASENAME 5219 if test -n "$BASENAME"; then 5220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5221 $as_echo "$BASENAME" >&6; } 5222 else 5223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5224 $as_echo "no" >&6; } 5225 fi 5226 5227 5228 test -n "$BASENAME" && break 5229 done 5230 5231 else 5232 # The variable is set, but is it from the command line or the environment? 5233 5234 # Try to remove the string !BASENAME! from our list. 5235 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/} 5236 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5237 # If it failed, the variable was not from the command line. Ignore it, 5238 # but warn the user (except for BASH, which is always set by the calling BASH). 5239 if test "xBASENAME" != xBASH; then 5240 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5 5241 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;} 5242 fi 5243 # Try to locate tool using the code snippet 5244 for ac_prog in basename 5245 do 5246 # Extract the first word of "$ac_prog", so it can be a program name with args. 5247 set dummy $ac_prog; ac_word=$2 5248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5249 $as_echo_n "checking for $ac_word... " >&6; } 5250 if ${ac_cv_path_BASENAME+:} false; then : 5251 $as_echo_n "(cached) " >&6 5252 else 5253 case $BASENAME in 5254 [\\/]* | ?:[\\/]*) 5255 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5256 ;; 5257 *) 5258 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5259 for as_dir in $PATH 5260 do 5261 IFS=$as_save_IFS 5262 test -z "$as_dir" && as_dir=. 5263 for ac_exec_ext in '' $ac_executable_extensions; do 5264 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5265 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5266 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5267 break 2 5268 fi 5269 done 5270 done 5271 IFS=$as_save_IFS 5272 5273 ;; 5274 esac 5275 fi 5276 BASENAME=$ac_cv_path_BASENAME 5277 if test -n "$BASENAME"; then 5278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5279 $as_echo "$BASENAME" >&6; } 5280 else 5281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5282 $as_echo "no" >&6; } 5283 fi 5284 5285 5286 test -n "$BASENAME" && break 5287 done 5288 5289 else 5290 # If it succeeded, then it was overridden by the user. We will use it 5291 # for the tool. 5292 5293 # First remove it from the list of overridden variables, so we can test 5294 # for unknown variables in the end. 5295 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5296 5297 # Check if we try to supply an empty value 5298 if test "x$BASENAME" = x; then 5299 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASENAME= (no value)" >&5 5300 $as_echo "$as_me: Setting user supplied tool BASENAME= (no value)" >&6;} 5301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5302 $as_echo_n "checking for BASENAME... " >&6; } 5303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5304 $as_echo "disabled" >&6; } 5305 else 5306 # Check if the provided tool contains a complete path. 5307 tool_specified="$BASENAME" 5308 tool_basename="${tool_specified##*/}" 5309 if test "x$tool_basename" = "x$tool_specified"; then 5310 # A command without a complete path is provided, search $PATH. 5311 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5 5312 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;} 5313 # Extract the first word of "$tool_basename", so it can be a program name with args. 5314 set dummy $tool_basename; ac_word=$2 5315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5316 $as_echo_n "checking for $ac_word... " >&6; } 5317 if ${ac_cv_path_BASENAME+:} false; then : 5318 $as_echo_n "(cached) " >&6 5319 else 5320 case $BASENAME in 5321 [\\/]* | ?:[\\/]*) 5322 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5323 ;; 5324 *) 5325 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5326 for as_dir in $PATH 5327 do 5328 IFS=$as_save_IFS 5329 test -z "$as_dir" && as_dir=. 5330 for ac_exec_ext in '' $ac_executable_extensions; do 5331 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5332 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5333 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5334 break 2 5335 fi 5336 done 5337 done 5338 IFS=$as_save_IFS 5339 5340 ;; 5341 esac 5342 fi 5343 BASENAME=$ac_cv_path_BASENAME 5344 if test -n "$BASENAME"; then 5345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5346 $as_echo "$BASENAME" >&6; } 5347 else 5348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5349 $as_echo "no" >&6; } 5350 fi 5351 5352 5353 if test "x$BASENAME" = x; then 5354 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5355 fi 5356 else 5357 # Otherwise we believe it is a complete path. Use it as it is. 5358 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5 5359 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;} 5360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5361 $as_echo_n "checking for BASENAME... " >&6; } 5362 if test ! -x "$tool_specified"; then 5363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5364 $as_echo "not found" >&6; } 5365 as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5 5366 fi 5367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5368 $as_echo "$tool_specified" >&6; } 5369 fi 5370 fi 5371 fi 5372 5373 fi 5374 5375 5376 5377 if test "x$BASENAME" = x; then 5378 as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5 5379 fi 5380 5381 5382 5383 5384 5385 # Publish this variable in the help. 5386 5387 5388 if [ -z "${BASH+x}" ]; then 5389 # The variable is not set by user, try to locate tool using the code snippet 5390 for ac_prog in bash 5391 do 5392 # Extract the first word of "$ac_prog", so it can be a program name with args. 5393 set dummy $ac_prog; ac_word=$2 5394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5395 $as_echo_n "checking for $ac_word... " >&6; } 5396 if ${ac_cv_path_BASH+:} false; then : 5397 $as_echo_n "(cached) " >&6 5398 else 5399 case $BASH in 5400 [\\/]* | ?:[\\/]*) 5401 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5402 ;; 5403 *) 5404 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5405 for as_dir in $PATH 5406 do 5407 IFS=$as_save_IFS 5408 test -z "$as_dir" && as_dir=. 5409 for ac_exec_ext in '' $ac_executable_extensions; do 5410 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5411 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5412 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5413 break 2 5414 fi 5415 done 5416 done 5417 IFS=$as_save_IFS 5418 5419 ;; 5420 esac 5421 fi 5422 BASH=$ac_cv_path_BASH 5423 if test -n "$BASH"; then 5424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5425 $as_echo "$BASH" >&6; } 5426 else 5427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5428 $as_echo "no" >&6; } 5429 fi 5430 5431 5432 test -n "$BASH" && break 5433 done 5434 5435 else 5436 # The variable is set, but is it from the command line or the environment? 5437 5438 # Try to remove the string !BASH! from our list. 5439 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/} 5440 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5441 # If it failed, the variable was not from the command line. Ignore it, 5442 # but warn the user (except for BASH, which is always set by the calling BASH). 5443 if test "xBASH" != xBASH; then 5444 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5 5445 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;} 5446 fi 5447 # Try to locate tool using the code snippet 5448 for ac_prog in bash 5449 do 5450 # Extract the first word of "$ac_prog", so it can be a program name with args. 5451 set dummy $ac_prog; ac_word=$2 5452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5453 $as_echo_n "checking for $ac_word... " >&6; } 5454 if ${ac_cv_path_BASH+:} false; then : 5455 $as_echo_n "(cached) " >&6 5456 else 5457 case $BASH in 5458 [\\/]* | ?:[\\/]*) 5459 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5460 ;; 5461 *) 5462 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5463 for as_dir in $PATH 5464 do 5465 IFS=$as_save_IFS 5466 test -z "$as_dir" && as_dir=. 5467 for ac_exec_ext in '' $ac_executable_extensions; do 5468 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5469 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5470 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5471 break 2 5472 fi 5473 done 5474 done 5475 IFS=$as_save_IFS 5476 5477 ;; 5478 esac 5479 fi 5480 BASH=$ac_cv_path_BASH 5481 if test -n "$BASH"; then 5482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5483 $as_echo "$BASH" >&6; } 5484 else 5485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5486 $as_echo "no" >&6; } 5487 fi 5488 5489 5490 test -n "$BASH" && break 5491 done 5492 5493 else 5494 # If it succeeded, then it was overridden by the user. We will use it 5495 # for the tool. 5496 5497 # First remove it from the list of overridden variables, so we can test 5498 # for unknown variables in the end. 5499 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5500 5501 # Check if we try to supply an empty value 5502 if test "x$BASH" = x; then 5503 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASH= (no value)" >&5 5504 $as_echo "$as_me: Setting user supplied tool BASH= (no value)" >&6;} 5505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5506 $as_echo_n "checking for BASH... " >&6; } 5507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5508 $as_echo "disabled" >&6; } 5509 else 5510 # Check if the provided tool contains a complete path. 5511 tool_specified="$BASH" 5512 tool_basename="${tool_specified##*/}" 5513 if test "x$tool_basename" = "x$tool_specified"; then 5514 # A command without a complete path is provided, search $PATH. 5515 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5 5516 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;} 5517 # Extract the first word of "$tool_basename", so it can be a program name with args. 5518 set dummy $tool_basename; ac_word=$2 5519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5520 $as_echo_n "checking for $ac_word... " >&6; } 5521 if ${ac_cv_path_BASH+:} false; then : 5522 $as_echo_n "(cached) " >&6 5523 else 5524 case $BASH in 5525 [\\/]* | ?:[\\/]*) 5526 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5527 ;; 5528 *) 5529 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5530 for as_dir in $PATH 5531 do 5532 IFS=$as_save_IFS 5533 test -z "$as_dir" && as_dir=. 5534 for ac_exec_ext in '' $ac_executable_extensions; do 5535 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5536 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5537 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5538 break 2 5539 fi 5540 done 5541 done 5542 IFS=$as_save_IFS 5543 5544 ;; 5545 esac 5546 fi 5547 BASH=$ac_cv_path_BASH 5548 if test -n "$BASH"; then 5549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5550 $as_echo "$BASH" >&6; } 5551 else 5552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5553 $as_echo "no" >&6; } 5554 fi 5555 5556 5557 if test "x$BASH" = x; then 5558 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5559 fi 5560 else 5561 # Otherwise we believe it is a complete path. Use it as it is. 5562 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5 5563 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;} 5564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5565 $as_echo_n "checking for BASH... " >&6; } 5566 if test ! -x "$tool_specified"; then 5567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5568 $as_echo "not found" >&6; } 5569 as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5 5570 fi 5571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5572 $as_echo "$tool_specified" >&6; } 5573 fi 5574 fi 5575 fi 5576 5577 fi 5578 5579 5580 5581 if test "x$BASH" = x; then 5582 as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5 5583 fi 5584 5585 5586 5587 5588 5589 # Publish this variable in the help. 5590 5591 5592 if [ -z "${CAT+x}" ]; then 5593 # The variable is not set by user, try to locate tool using the code snippet 5594 for ac_prog in cat 5595 do 5596 # Extract the first word of "$ac_prog", so it can be a program name with args. 5597 set dummy $ac_prog; ac_word=$2 5598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5599 $as_echo_n "checking for $ac_word... " >&6; } 5600 if ${ac_cv_path_CAT+:} false; then : 5601 $as_echo_n "(cached) " >&6 5602 else 5603 case $CAT in 5604 [\\/]* | ?:[\\/]*) 5605 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5606 ;; 5607 *) 5608 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5609 for as_dir in $PATH 5610 do 5611 IFS=$as_save_IFS 5612 test -z "$as_dir" && as_dir=. 5613 for ac_exec_ext in '' $ac_executable_extensions; do 5614 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5615 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5616 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5617 break 2 5618 fi 5619 done 5620 done 5621 IFS=$as_save_IFS 5622 5623 ;; 5624 esac 5625 fi 5626 CAT=$ac_cv_path_CAT 5627 if test -n "$CAT"; then 5628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5629 $as_echo "$CAT" >&6; } 5630 else 5631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5632 $as_echo "no" >&6; } 5633 fi 5634 5635 5636 test -n "$CAT" && break 5637 done 5638 5639 else 5640 # The variable is set, but is it from the command line or the environment? 5641 5642 # Try to remove the string !CAT! from our list. 5643 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/} 5644 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5645 # If it failed, the variable was not from the command line. Ignore it, 5646 # but warn the user (except for BASH, which is always set by the calling BASH). 5647 if test "xCAT" != xBASH; then 5648 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5 5649 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;} 5650 fi 5651 # Try to locate tool using the code snippet 5652 for ac_prog in cat 5653 do 5654 # Extract the first word of "$ac_prog", so it can be a program name with args. 5655 set dummy $ac_prog; ac_word=$2 5656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5657 $as_echo_n "checking for $ac_word... " >&6; } 5658 if ${ac_cv_path_CAT+:} false; then : 5659 $as_echo_n "(cached) " >&6 5660 else 5661 case $CAT in 5662 [\\/]* | ?:[\\/]*) 5663 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5664 ;; 5665 *) 5666 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5667 for as_dir in $PATH 5668 do 5669 IFS=$as_save_IFS 5670 test -z "$as_dir" && as_dir=. 5671 for ac_exec_ext in '' $ac_executable_extensions; do 5672 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5673 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5674 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5675 break 2 5676 fi 5677 done 5678 done 5679 IFS=$as_save_IFS 5680 5681 ;; 5682 esac 5683 fi 5684 CAT=$ac_cv_path_CAT 5685 if test -n "$CAT"; then 5686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5687 $as_echo "$CAT" >&6; } 5688 else 5689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5690 $as_echo "no" >&6; } 5691 fi 5692 5693 5694 test -n "$CAT" && break 5695 done 5696 5697 else 5698 # If it succeeded, then it was overridden by the user. We will use it 5699 # for the tool. 5700 5701 # First remove it from the list of overridden variables, so we can test 5702 # for unknown variables in the end. 5703 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5704 5705 # Check if we try to supply an empty value 5706 if test "x$CAT" = x; then 5707 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CAT= (no value)" >&5 5708 $as_echo "$as_me: Setting user supplied tool CAT= (no value)" >&6;} 5709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5710 $as_echo_n "checking for CAT... " >&6; } 5711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5712 $as_echo "disabled" >&6; } 5713 else 5714 # Check if the provided tool contains a complete path. 5715 tool_specified="$CAT" 5716 tool_basename="${tool_specified##*/}" 5717 if test "x$tool_basename" = "x$tool_specified"; then 5718 # A command without a complete path is provided, search $PATH. 5719 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5 5720 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;} 5721 # Extract the first word of "$tool_basename", so it can be a program name with args. 5722 set dummy $tool_basename; ac_word=$2 5723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5724 $as_echo_n "checking for $ac_word... " >&6; } 5725 if ${ac_cv_path_CAT+:} false; then : 5726 $as_echo_n "(cached) " >&6 5727 else 5728 case $CAT in 5729 [\\/]* | ?:[\\/]*) 5730 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5731 ;; 5732 *) 5733 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5734 for as_dir in $PATH 5735 do 5736 IFS=$as_save_IFS 5737 test -z "$as_dir" && as_dir=. 5738 for ac_exec_ext in '' $ac_executable_extensions; do 5739 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5740 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5741 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5742 break 2 5743 fi 5744 done 5745 done 5746 IFS=$as_save_IFS 5747 5748 ;; 5749 esac 5750 fi 5751 CAT=$ac_cv_path_CAT 5752 if test -n "$CAT"; then 5753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5754 $as_echo "$CAT" >&6; } 5755 else 5756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5757 $as_echo "no" >&6; } 5758 fi 5759 5760 5761 if test "x$CAT" = x; then 5762 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5763 fi 5764 else 5765 # Otherwise we believe it is a complete path. Use it as it is. 5766 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5 5767 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;} 5768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5769 $as_echo_n "checking for CAT... " >&6; } 5770 if test ! -x "$tool_specified"; then 5771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5772 $as_echo "not found" >&6; } 5773 as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5 5774 fi 5775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5776 $as_echo "$tool_specified" >&6; } 5777 fi 5778 fi 5779 fi 5780 5781 fi 5782 5783 5784 5785 if test "x$CAT" = x; then 5786 as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5 5787 fi 5788 5789 5790 5791 5792 5793 # Publish this variable in the help. 5794 5795 5796 if [ -z "${CHMOD+x}" ]; then 5797 # The variable is not set by user, try to locate tool using the code snippet 5798 for ac_prog in chmod 5799 do 5800 # Extract the first word of "$ac_prog", so it can be a program name with args. 5801 set dummy $ac_prog; ac_word=$2 5802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5803 $as_echo_n "checking for $ac_word... " >&6; } 5804 if ${ac_cv_path_CHMOD+:} false; then : 5805 $as_echo_n "(cached) " >&6 5806 else 5807 case $CHMOD in 5808 [\\/]* | ?:[\\/]*) 5809 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5810 ;; 5811 *) 5812 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5813 for as_dir in $PATH 5814 do 5815 IFS=$as_save_IFS 5816 test -z "$as_dir" && as_dir=. 5817 for ac_exec_ext in '' $ac_executable_extensions; do 5818 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5819 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5820 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5821 break 2 5822 fi 5823 done 5824 done 5825 IFS=$as_save_IFS 5826 5827 ;; 5828 esac 5829 fi 5830 CHMOD=$ac_cv_path_CHMOD 5831 if test -n "$CHMOD"; then 5832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5833 $as_echo "$CHMOD" >&6; } 5834 else 5835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5836 $as_echo "no" >&6; } 5837 fi 5838 5839 5840 test -n "$CHMOD" && break 5841 done 5842 5843 else 5844 # The variable is set, but is it from the command line or the environment? 5845 5846 # Try to remove the string !CHMOD! from our list. 5847 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/} 5848 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5849 # If it failed, the variable was not from the command line. Ignore it, 5850 # but warn the user (except for BASH, which is always set by the calling BASH). 5851 if test "xCHMOD" != xBASH; then 5852 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5 5853 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;} 5854 fi 5855 # Try to locate tool using the code snippet 5856 for ac_prog in chmod 5857 do 5858 # Extract the first word of "$ac_prog", so it can be a program name with args. 5859 set dummy $ac_prog; ac_word=$2 5860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5861 $as_echo_n "checking for $ac_word... " >&6; } 5862 if ${ac_cv_path_CHMOD+:} false; then : 5863 $as_echo_n "(cached) " >&6 5864 else 5865 case $CHMOD in 5866 [\\/]* | ?:[\\/]*) 5867 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5868 ;; 5869 *) 5870 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5871 for as_dir in $PATH 5872 do 5873 IFS=$as_save_IFS 5874 test -z "$as_dir" && as_dir=. 5875 for ac_exec_ext in '' $ac_executable_extensions; do 5876 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5877 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5878 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5879 break 2 5880 fi 5881 done 5882 done 5883 IFS=$as_save_IFS 5884 5885 ;; 5886 esac 5887 fi 5888 CHMOD=$ac_cv_path_CHMOD 5889 if test -n "$CHMOD"; then 5890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5891 $as_echo "$CHMOD" >&6; } 5892 else 5893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5894 $as_echo "no" >&6; } 5895 fi 5896 5897 5898 test -n "$CHMOD" && break 5899 done 5900 5901 else 5902 # If it succeeded, then it was overridden by the user. We will use it 5903 # for the tool. 5904 5905 # First remove it from the list of overridden variables, so we can test 5906 # for unknown variables in the end. 5907 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5908 5909 # Check if we try to supply an empty value 5910 if test "x$CHMOD" = x; then 5911 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CHMOD= (no value)" >&5 5912 $as_echo "$as_me: Setting user supplied tool CHMOD= (no value)" >&6;} 5913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5914 $as_echo_n "checking for CHMOD... " >&6; } 5915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5916 $as_echo "disabled" >&6; } 5917 else 5918 # Check if the provided tool contains a complete path. 5919 tool_specified="$CHMOD" 5920 tool_basename="${tool_specified##*/}" 5921 if test "x$tool_basename" = "x$tool_specified"; then 5922 # A command without a complete path is provided, search $PATH. 5923 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5 5924 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;} 5925 # Extract the first word of "$tool_basename", so it can be a program name with args. 5926 set dummy $tool_basename; ac_word=$2 5927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5928 $as_echo_n "checking for $ac_word... " >&6; } 5929 if ${ac_cv_path_CHMOD+:} false; then : 5930 $as_echo_n "(cached) " >&6 5931 else 5932 case $CHMOD in 5933 [\\/]* | ?:[\\/]*) 5934 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5935 ;; 5936 *) 5937 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5938 for as_dir in $PATH 5939 do 5940 IFS=$as_save_IFS 5941 test -z "$as_dir" && as_dir=. 5942 for ac_exec_ext in '' $ac_executable_extensions; do 5943 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5944 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5945 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5946 break 2 5947 fi 5948 done 5949 done 5950 IFS=$as_save_IFS 5951 5952 ;; 5953 esac 5954 fi 5955 CHMOD=$ac_cv_path_CHMOD 5956 if test -n "$CHMOD"; then 5957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5958 $as_echo "$CHMOD" >&6; } 5959 else 5960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5961 $as_echo "no" >&6; } 5962 fi 5963 5964 5965 if test "x$CHMOD" = x; then 5966 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5967 fi 5968 else 5969 # Otherwise we believe it is a complete path. Use it as it is. 5970 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5 5971 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;} 5972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5973 $as_echo_n "checking for CHMOD... " >&6; } 5974 if test ! -x "$tool_specified"; then 5975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5976 $as_echo "not found" >&6; } 5977 as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5 5978 fi 5979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5980 $as_echo "$tool_specified" >&6; } 5981 fi 5982 fi 5983 fi 5984 5985 fi 5986 5987 5988 5989 if test "x$CHMOD" = x; then 5990 as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5 5991 fi 5992 5993 5994 5995 5996 5997 # Publish this variable in the help. 5998 5999 6000 if [ -z "${CMP+x}" ]; then 6001 # The variable is not set by user, try to locate tool using the code snippet 6002 for ac_prog in cmp 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_path_CMP+:} false; then : 6009 $as_echo_n "(cached) " >&6 6010 else 6011 case $CMP in 6012 [\\/]* | ?:[\\/]*) 6013 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6014 ;; 6015 *) 6016 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6017 for as_dir in $PATH 6018 do 6019 IFS=$as_save_IFS 6020 test -z "$as_dir" && as_dir=. 6021 for ac_exec_ext in '' $ac_executable_extensions; do 6022 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6023 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6024 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6025 break 2 6026 fi 6027 done 6028 done 6029 IFS=$as_save_IFS 6030 6031 ;; 6032 esac 6033 fi 6034 CMP=$ac_cv_path_CMP 6035 if test -n "$CMP"; then 6036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6037 $as_echo "$CMP" >&6; } 6038 else 6039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6040 $as_echo "no" >&6; } 6041 fi 6042 6043 6044 test -n "$CMP" && break 6045 done 6046 6047 else 6048 # The variable is set, but is it from the command line or the environment? 6049 6050 # Try to remove the string !CMP! from our list. 6051 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/} 6052 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6053 # If it failed, the variable was not from the command line. Ignore it, 6054 # but warn the user (except for BASH, which is always set by the calling BASH). 6055 if test "xCMP" != xBASH; then 6056 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5 6057 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;} 6058 fi 6059 # Try to locate tool using the code snippet 6060 for ac_prog in cmp 6061 do 6062 # Extract the first word of "$ac_prog", so it can be a program name with args. 6063 set dummy $ac_prog; ac_word=$2 6064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6065 $as_echo_n "checking for $ac_word... " >&6; } 6066 if ${ac_cv_path_CMP+:} false; then : 6067 $as_echo_n "(cached) " >&6 6068 else 6069 case $CMP in 6070 [\\/]* | ?:[\\/]*) 6071 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6072 ;; 6073 *) 6074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6075 for as_dir in $PATH 6076 do 6077 IFS=$as_save_IFS 6078 test -z "$as_dir" && as_dir=. 6079 for ac_exec_ext in '' $ac_executable_extensions; do 6080 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6081 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6082 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6083 break 2 6084 fi 6085 done 6086 done 6087 IFS=$as_save_IFS 6088 6089 ;; 6090 esac 6091 fi 6092 CMP=$ac_cv_path_CMP 6093 if test -n "$CMP"; then 6094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6095 $as_echo "$CMP" >&6; } 6096 else 6097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6098 $as_echo "no" >&6; } 6099 fi 6100 6101 6102 test -n "$CMP" && break 6103 done 6104 6105 else 6106 # If it succeeded, then it was overridden by the user. We will use it 6107 # for the tool. 6108 6109 # First remove it from the list of overridden variables, so we can test 6110 # for unknown variables in the end. 6111 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6112 6113 # Check if we try to supply an empty value 6114 if test "x$CMP" = x; then 6115 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CMP= (no value)" >&5 6116 $as_echo "$as_me: Setting user supplied tool CMP= (no value)" >&6;} 6117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6118 $as_echo_n "checking for CMP... " >&6; } 6119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6120 $as_echo "disabled" >&6; } 6121 else 6122 # Check if the provided tool contains a complete path. 6123 tool_specified="$CMP" 6124 tool_basename="${tool_specified##*/}" 6125 if test "x$tool_basename" = "x$tool_specified"; then 6126 # A command without a complete path is provided, search $PATH. 6127 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5 6128 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;} 6129 # Extract the first word of "$tool_basename", so it can be a program name with args. 6130 set dummy $tool_basename; ac_word=$2 6131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6132 $as_echo_n "checking for $ac_word... " >&6; } 6133 if ${ac_cv_path_CMP+:} false; then : 6134 $as_echo_n "(cached) " >&6 6135 else 6136 case $CMP in 6137 [\\/]* | ?:[\\/]*) 6138 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6139 ;; 6140 *) 6141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6142 for as_dir in $PATH 6143 do 6144 IFS=$as_save_IFS 6145 test -z "$as_dir" && as_dir=. 6146 for ac_exec_ext in '' $ac_executable_extensions; do 6147 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6148 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6149 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6150 break 2 6151 fi 6152 done 6153 done 6154 IFS=$as_save_IFS 6155 6156 ;; 6157 esac 6158 fi 6159 CMP=$ac_cv_path_CMP 6160 if test -n "$CMP"; then 6161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6162 $as_echo "$CMP" >&6; } 6163 else 6164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6165 $as_echo "no" >&6; } 6166 fi 6167 6168 6169 if test "x$CMP" = x; then 6170 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6171 fi 6172 else 6173 # Otherwise we believe it is a complete path. Use it as it is. 6174 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5 6175 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;} 6176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6177 $as_echo_n "checking for CMP... " >&6; } 6178 if test ! -x "$tool_specified"; then 6179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6180 $as_echo "not found" >&6; } 6181 as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5 6182 fi 6183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6184 $as_echo "$tool_specified" >&6; } 6185 fi 6186 fi 6187 fi 6188 6189 fi 6190 6191 6192 6193 if test "x$CMP" = x; then 6194 as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5 6195 fi 6196 6197 6198 6199 6200 6201 # Publish this variable in the help. 6202 6203 6204 if [ -z "${COMM+x}" ]; then 6205 # The variable is not set by user, try to locate tool using the code snippet 6206 for ac_prog in comm 6207 do 6208 # Extract the first word of "$ac_prog", so it can be a program name with args. 6209 set dummy $ac_prog; ac_word=$2 6210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6211 $as_echo_n "checking for $ac_word... " >&6; } 6212 if ${ac_cv_path_COMM+:} false; then : 6213 $as_echo_n "(cached) " >&6 6214 else 6215 case $COMM in 6216 [\\/]* | ?:[\\/]*) 6217 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6218 ;; 6219 *) 6220 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6221 for as_dir in $PATH 6222 do 6223 IFS=$as_save_IFS 6224 test -z "$as_dir" && as_dir=. 6225 for ac_exec_ext in '' $ac_executable_extensions; do 6226 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6227 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6228 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6229 break 2 6230 fi 6231 done 6232 done 6233 IFS=$as_save_IFS 6234 6235 ;; 6236 esac 6237 fi 6238 COMM=$ac_cv_path_COMM 6239 if test -n "$COMM"; then 6240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6241 $as_echo "$COMM" >&6; } 6242 else 6243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6244 $as_echo "no" >&6; } 6245 fi 6246 6247 6248 test -n "$COMM" && break 6249 done 6250 6251 else 6252 # The variable is set, but is it from the command line or the environment? 6253 6254 # Try to remove the string !COMM! from our list. 6255 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/} 6256 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6257 # If it failed, the variable was not from the command line. Ignore it, 6258 # but warn the user (except for BASH, which is always set by the calling BASH). 6259 if test "xCOMM" != xBASH; then 6260 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5 6261 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;} 6262 fi 6263 # Try to locate tool using the code snippet 6264 for ac_prog in comm 6265 do 6266 # Extract the first word of "$ac_prog", so it can be a program name with args. 6267 set dummy $ac_prog; ac_word=$2 6268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6269 $as_echo_n "checking for $ac_word... " >&6; } 6270 if ${ac_cv_path_COMM+:} false; then : 6271 $as_echo_n "(cached) " >&6 6272 else 6273 case $COMM in 6274 [\\/]* | ?:[\\/]*) 6275 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6276 ;; 6277 *) 6278 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6279 for as_dir in $PATH 6280 do 6281 IFS=$as_save_IFS 6282 test -z "$as_dir" && as_dir=. 6283 for ac_exec_ext in '' $ac_executable_extensions; do 6284 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6285 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6286 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6287 break 2 6288 fi 6289 done 6290 done 6291 IFS=$as_save_IFS 6292 6293 ;; 6294 esac 6295 fi 6296 COMM=$ac_cv_path_COMM 6297 if test -n "$COMM"; then 6298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6299 $as_echo "$COMM" >&6; } 6300 else 6301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6302 $as_echo "no" >&6; } 6303 fi 6304 6305 6306 test -n "$COMM" && break 6307 done 6308 6309 else 6310 # If it succeeded, then it was overridden by the user. We will use it 6311 # for the tool. 6312 6313 # First remove it from the list of overridden variables, so we can test 6314 # for unknown variables in the end. 6315 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6316 6317 # Check if we try to supply an empty value 6318 if test "x$COMM" = x; then 6319 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool COMM= (no value)" >&5 6320 $as_echo "$as_me: Setting user supplied tool COMM= (no value)" >&6;} 6321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6322 $as_echo_n "checking for COMM... " >&6; } 6323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6324 $as_echo "disabled" >&6; } 6325 else 6326 # Check if the provided tool contains a complete path. 6327 tool_specified="$COMM" 6328 tool_basename="${tool_specified##*/}" 6329 if test "x$tool_basename" = "x$tool_specified"; then 6330 # A command without a complete path is provided, search $PATH. 6331 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5 6332 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;} 6333 # Extract the first word of "$tool_basename", so it can be a program name with args. 6334 set dummy $tool_basename; ac_word=$2 6335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6336 $as_echo_n "checking for $ac_word... " >&6; } 6337 if ${ac_cv_path_COMM+:} false; then : 6338 $as_echo_n "(cached) " >&6 6339 else 6340 case $COMM in 6341 [\\/]* | ?:[\\/]*) 6342 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6343 ;; 6344 *) 6345 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6346 for as_dir in $PATH 6347 do 6348 IFS=$as_save_IFS 6349 test -z "$as_dir" && as_dir=. 6350 for ac_exec_ext in '' $ac_executable_extensions; do 6351 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6352 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6353 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6354 break 2 6355 fi 6356 done 6357 done 6358 IFS=$as_save_IFS 6359 6360 ;; 6361 esac 6362 fi 6363 COMM=$ac_cv_path_COMM 6364 if test -n "$COMM"; then 6365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6366 $as_echo "$COMM" >&6; } 6367 else 6368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6369 $as_echo "no" >&6; } 6370 fi 6371 6372 6373 if test "x$COMM" = x; then 6374 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6375 fi 6376 else 6377 # Otherwise we believe it is a complete path. Use it as it is. 6378 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5 6379 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;} 6380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6381 $as_echo_n "checking for COMM... " >&6; } 6382 if test ! -x "$tool_specified"; then 6383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6384 $as_echo "not found" >&6; } 6385 as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5 6386 fi 6387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6388 $as_echo "$tool_specified" >&6; } 6389 fi 6390 fi 6391 fi 6392 6393 fi 6394 6395 6396 6397 if test "x$COMM" = x; then 6398 as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5 6399 fi 6400 6401 6402 6403 6404 6405 # Publish this variable in the help. 6406 6407 6408 if [ -z "${CP+x}" ]; then 6409 # The variable is not set by user, try to locate tool using the code snippet 6410 for ac_prog in cp 6411 do 6412 # Extract the first word of "$ac_prog", so it can be a program name with args. 6413 set dummy $ac_prog; ac_word=$2 6414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6415 $as_echo_n "checking for $ac_word... " >&6; } 6416 if ${ac_cv_path_CP+:} false; then : 6417 $as_echo_n "(cached) " >&6 6418 else 6419 case $CP in 6420 [\\/]* | ?:[\\/]*) 6421 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6422 ;; 6423 *) 6424 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6425 for as_dir in $PATH 6426 do 6427 IFS=$as_save_IFS 6428 test -z "$as_dir" && as_dir=. 6429 for ac_exec_ext in '' $ac_executable_extensions; do 6430 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6431 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6432 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6433 break 2 6434 fi 6435 done 6436 done 6437 IFS=$as_save_IFS 6438 6439 ;; 6440 esac 6441 fi 6442 CP=$ac_cv_path_CP 6443 if test -n "$CP"; then 6444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6445 $as_echo "$CP" >&6; } 6446 else 6447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6448 $as_echo "no" >&6; } 6449 fi 6450 6451 6452 test -n "$CP" && break 6453 done 6454 6455 else 6456 # The variable is set, but is it from the command line or the environment? 6457 6458 # Try to remove the string !CP! from our list. 6459 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/} 6460 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6461 # If it failed, the variable was not from the command line. Ignore it, 6462 # but warn the user (except for BASH, which is always set by the calling BASH). 6463 if test "xCP" != xBASH; then 6464 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5 6465 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;} 6466 fi 6467 # Try to locate tool using the code snippet 6468 for ac_prog in cp 6469 do 6470 # Extract the first word of "$ac_prog", so it can be a program name with args. 6471 set dummy $ac_prog; ac_word=$2 6472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6473 $as_echo_n "checking for $ac_word... " >&6; } 6474 if ${ac_cv_path_CP+:} false; then : 6475 $as_echo_n "(cached) " >&6 6476 else 6477 case $CP in 6478 [\\/]* | ?:[\\/]*) 6479 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6480 ;; 6481 *) 6482 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6483 for as_dir in $PATH 6484 do 6485 IFS=$as_save_IFS 6486 test -z "$as_dir" && as_dir=. 6487 for ac_exec_ext in '' $ac_executable_extensions; do 6488 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6489 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6490 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6491 break 2 6492 fi 6493 done 6494 done 6495 IFS=$as_save_IFS 6496 6497 ;; 6498 esac 6499 fi 6500 CP=$ac_cv_path_CP 6501 if test -n "$CP"; then 6502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6503 $as_echo "$CP" >&6; } 6504 else 6505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6506 $as_echo "no" >&6; } 6507 fi 6508 6509 6510 test -n "$CP" && break 6511 done 6512 6513 else 6514 # If it succeeded, then it was overridden by the user. We will use it 6515 # for the tool. 6516 6517 # First remove it from the list of overridden variables, so we can test 6518 # for unknown variables in the end. 6519 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6520 6521 # Check if we try to supply an empty value 6522 if test "x$CP" = x; then 6523 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CP= (no value)" >&5 6524 $as_echo "$as_me: Setting user supplied tool CP= (no value)" >&6;} 6525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6526 $as_echo_n "checking for CP... " >&6; } 6527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6528 $as_echo "disabled" >&6; } 6529 else 6530 # Check if the provided tool contains a complete path. 6531 tool_specified="$CP" 6532 tool_basename="${tool_specified##*/}" 6533 if test "x$tool_basename" = "x$tool_specified"; then 6534 # A command without a complete path is provided, search $PATH. 6535 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5 6536 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;} 6537 # Extract the first word of "$tool_basename", so it can be a program name with args. 6538 set dummy $tool_basename; ac_word=$2 6539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6540 $as_echo_n "checking for $ac_word... " >&6; } 6541 if ${ac_cv_path_CP+:} false; then : 6542 $as_echo_n "(cached) " >&6 6543 else 6544 case $CP in 6545 [\\/]* | ?:[\\/]*) 6546 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6547 ;; 6548 *) 6549 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6550 for as_dir in $PATH 6551 do 6552 IFS=$as_save_IFS 6553 test -z "$as_dir" && as_dir=. 6554 for ac_exec_ext in '' $ac_executable_extensions; do 6555 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6556 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6557 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6558 break 2 6559 fi 6560 done 6561 done 6562 IFS=$as_save_IFS 6563 6564 ;; 6565 esac 6566 fi 6567 CP=$ac_cv_path_CP 6568 if test -n "$CP"; then 6569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6570 $as_echo "$CP" >&6; } 6571 else 6572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6573 $as_echo "no" >&6; } 6574 fi 6575 6576 6577 if test "x$CP" = x; then 6578 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6579 fi 6580 else 6581 # Otherwise we believe it is a complete path. Use it as it is. 6582 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5 6583 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;} 6584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6585 $as_echo_n "checking for CP... " >&6; } 6586 if test ! -x "$tool_specified"; then 6587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6588 $as_echo "not found" >&6; } 6589 as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5 6590 fi 6591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6592 $as_echo "$tool_specified" >&6; } 6593 fi 6594 fi 6595 fi 6596 6597 fi 6598 6599 6600 6601 if test "x$CP" = x; then 6602 as_fn_error $? "Could not find required tool for CP" "$LINENO" 5 6603 fi 6604 6605 6606 6607 6608 6609 # Publish this variable in the help. 6610 6611 6612 if [ -z "${CUT+x}" ]; then 6613 # The variable is not set by user, try to locate tool using the code snippet 6614 for ac_prog in cut 6615 do 6616 # Extract the first word of "$ac_prog", so it can be a program name with args. 6617 set dummy $ac_prog; ac_word=$2 6618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6619 $as_echo_n "checking for $ac_word... " >&6; } 6620 if ${ac_cv_path_CUT+:} false; then : 6621 $as_echo_n "(cached) " >&6 6622 else 6623 case $CUT in 6624 [\\/]* | ?:[\\/]*) 6625 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6626 ;; 6627 *) 6628 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6629 for as_dir in $PATH 6630 do 6631 IFS=$as_save_IFS 6632 test -z "$as_dir" && as_dir=. 6633 for ac_exec_ext in '' $ac_executable_extensions; do 6634 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6635 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6636 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6637 break 2 6638 fi 6639 done 6640 done 6641 IFS=$as_save_IFS 6642 6643 ;; 6644 esac 6645 fi 6646 CUT=$ac_cv_path_CUT 6647 if test -n "$CUT"; then 6648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6649 $as_echo "$CUT" >&6; } 6650 else 6651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6652 $as_echo "no" >&6; } 6653 fi 6654 6655 6656 test -n "$CUT" && break 6657 done 6658 6659 else 6660 # The variable is set, but is it from the command line or the environment? 6661 6662 # Try to remove the string !CUT! from our list. 6663 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/} 6664 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6665 # If it failed, the variable was not from the command line. Ignore it, 6666 # but warn the user (except for BASH, which is always set by the calling BASH). 6667 if test "xCUT" != xBASH; then 6668 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5 6669 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;} 6670 fi 6671 # Try to locate tool using the code snippet 6672 for ac_prog in cut 6673 do 6674 # Extract the first word of "$ac_prog", so it can be a program name with args. 6675 set dummy $ac_prog; ac_word=$2 6676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6677 $as_echo_n "checking for $ac_word... " >&6; } 6678 if ${ac_cv_path_CUT+:} false; then : 6679 $as_echo_n "(cached) " >&6 6680 else 6681 case $CUT in 6682 [\\/]* | ?:[\\/]*) 6683 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6684 ;; 6685 *) 6686 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6687 for as_dir in $PATH 6688 do 6689 IFS=$as_save_IFS 6690 test -z "$as_dir" && as_dir=. 6691 for ac_exec_ext in '' $ac_executable_extensions; do 6692 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6693 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6694 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6695 break 2 6696 fi 6697 done 6698 done 6699 IFS=$as_save_IFS 6700 6701 ;; 6702 esac 6703 fi 6704 CUT=$ac_cv_path_CUT 6705 if test -n "$CUT"; then 6706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6707 $as_echo "$CUT" >&6; } 6708 else 6709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6710 $as_echo "no" >&6; } 6711 fi 6712 6713 6714 test -n "$CUT" && break 6715 done 6716 6717 else 6718 # If it succeeded, then it was overridden by the user. We will use it 6719 # for the tool. 6720 6721 # First remove it from the list of overridden variables, so we can test 6722 # for unknown variables in the end. 6723 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6724 6725 # Check if we try to supply an empty value 6726 if test "x$CUT" = x; then 6727 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CUT= (no value)" >&5 6728 $as_echo "$as_me: Setting user supplied tool CUT= (no value)" >&6;} 6729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6730 $as_echo_n "checking for CUT... " >&6; } 6731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6732 $as_echo "disabled" >&6; } 6733 else 6734 # Check if the provided tool contains a complete path. 6735 tool_specified="$CUT" 6736 tool_basename="${tool_specified##*/}" 6737 if test "x$tool_basename" = "x$tool_specified"; then 6738 # A command without a complete path is provided, search $PATH. 6739 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5 6740 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;} 6741 # Extract the first word of "$tool_basename", so it can be a program name with args. 6742 set dummy $tool_basename; ac_word=$2 6743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6744 $as_echo_n "checking for $ac_word... " >&6; } 6745 if ${ac_cv_path_CUT+:} false; then : 6746 $as_echo_n "(cached) " >&6 6747 else 6748 case $CUT in 6749 [\\/]* | ?:[\\/]*) 6750 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6751 ;; 6752 *) 6753 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6754 for as_dir in $PATH 6755 do 6756 IFS=$as_save_IFS 6757 test -z "$as_dir" && as_dir=. 6758 for ac_exec_ext in '' $ac_executable_extensions; do 6759 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6760 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6761 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6762 break 2 6763 fi 6764 done 6765 done 6766 IFS=$as_save_IFS 6767 6768 ;; 6769 esac 6770 fi 6771 CUT=$ac_cv_path_CUT 6772 if test -n "$CUT"; then 6773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6774 $as_echo "$CUT" >&6; } 6775 else 6776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6777 $as_echo "no" >&6; } 6778 fi 6779 6780 6781 if test "x$CUT" = x; then 6782 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6783 fi 6784 else 6785 # Otherwise we believe it is a complete path. Use it as it is. 6786 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5 6787 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;} 6788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6789 $as_echo_n "checking for CUT... " >&6; } 6790 if test ! -x "$tool_specified"; then 6791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6792 $as_echo "not found" >&6; } 6793 as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5 6794 fi 6795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6796 $as_echo "$tool_specified" >&6; } 6797 fi 6798 fi 6799 fi 6800 6801 fi 6802 6803 6804 6805 if test "x$CUT" = x; then 6806 as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5 6807 fi 6808 6809 6810 6811 6812 6813 # Publish this variable in the help. 6814 6815 6816 if [ -z "${DATE+x}" ]; then 6817 # The variable is not set by user, try to locate tool using the code snippet 6818 for ac_prog in date 6819 do 6820 # Extract the first word of "$ac_prog", so it can be a program name with args. 6821 set dummy $ac_prog; ac_word=$2 6822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6823 $as_echo_n "checking for $ac_word... " >&6; } 6824 if ${ac_cv_path_DATE+:} false; then : 6825 $as_echo_n "(cached) " >&6 6826 else 6827 case $DATE in 6828 [\\/]* | ?:[\\/]*) 6829 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6830 ;; 6831 *) 6832 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6833 for as_dir in $PATH 6834 do 6835 IFS=$as_save_IFS 6836 test -z "$as_dir" && as_dir=. 6837 for ac_exec_ext in '' $ac_executable_extensions; do 6838 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6839 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6840 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6841 break 2 6842 fi 6843 done 6844 done 6845 IFS=$as_save_IFS 6846 6847 ;; 6848 esac 6849 fi 6850 DATE=$ac_cv_path_DATE 6851 if test -n "$DATE"; then 6852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6853 $as_echo "$DATE" >&6; } 6854 else 6855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6856 $as_echo "no" >&6; } 6857 fi 6858 6859 6860 test -n "$DATE" && break 6861 done 6862 6863 else 6864 # The variable is set, but is it from the command line or the environment? 6865 6866 # Try to remove the string !DATE! from our list. 6867 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/} 6868 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6869 # If it failed, the variable was not from the command line. Ignore it, 6870 # but warn the user (except for BASH, which is always set by the calling BASH). 6871 if test "xDATE" != xBASH; then 6872 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5 6873 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;} 6874 fi 6875 # Try to locate tool using the code snippet 6876 for ac_prog in date 6877 do 6878 # Extract the first word of "$ac_prog", so it can be a program name with args. 6879 set dummy $ac_prog; ac_word=$2 6880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6881 $as_echo_n "checking for $ac_word... " >&6; } 6882 if ${ac_cv_path_DATE+:} false; then : 6883 $as_echo_n "(cached) " >&6 6884 else 6885 case $DATE in 6886 [\\/]* | ?:[\\/]*) 6887 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6888 ;; 6889 *) 6890 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6891 for as_dir in $PATH 6892 do 6893 IFS=$as_save_IFS 6894 test -z "$as_dir" && as_dir=. 6895 for ac_exec_ext in '' $ac_executable_extensions; do 6896 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6897 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6898 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6899 break 2 6900 fi 6901 done 6902 done 6903 IFS=$as_save_IFS 6904 6905 ;; 6906 esac 6907 fi 6908 DATE=$ac_cv_path_DATE 6909 if test -n "$DATE"; then 6910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6911 $as_echo "$DATE" >&6; } 6912 else 6913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6914 $as_echo "no" >&6; } 6915 fi 6916 6917 6918 test -n "$DATE" && break 6919 done 6920 6921 else 6922 # If it succeeded, then it was overridden by the user. We will use it 6923 # for the tool. 6924 6925 # First remove it from the list of overridden variables, so we can test 6926 # for unknown variables in the end. 6927 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6928 6929 # Check if we try to supply an empty value 6930 if test "x$DATE" = x; then 6931 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DATE= (no value)" >&5 6932 $as_echo "$as_me: Setting user supplied tool DATE= (no value)" >&6;} 6933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6934 $as_echo_n "checking for DATE... " >&6; } 6935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6936 $as_echo "disabled" >&6; } 6937 else 6938 # Check if the provided tool contains a complete path. 6939 tool_specified="$DATE" 6940 tool_basename="${tool_specified##*/}" 6941 if test "x$tool_basename" = "x$tool_specified"; then 6942 # A command without a complete path is provided, search $PATH. 6943 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5 6944 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;} 6945 # Extract the first word of "$tool_basename", so it can be a program name with args. 6946 set dummy $tool_basename; ac_word=$2 6947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6948 $as_echo_n "checking for $ac_word... " >&6; } 6949 if ${ac_cv_path_DATE+:} false; then : 6950 $as_echo_n "(cached) " >&6 6951 else 6952 case $DATE in 6953 [\\/]* | ?:[\\/]*) 6954 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6955 ;; 6956 *) 6957 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6958 for as_dir in $PATH 6959 do 6960 IFS=$as_save_IFS 6961 test -z "$as_dir" && as_dir=. 6962 for ac_exec_ext in '' $ac_executable_extensions; do 6963 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6964 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6965 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6966 break 2 6967 fi 6968 done 6969 done 6970 IFS=$as_save_IFS 6971 6972 ;; 6973 esac 6974 fi 6975 DATE=$ac_cv_path_DATE 6976 if test -n "$DATE"; then 6977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6978 $as_echo "$DATE" >&6; } 6979 else 6980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6981 $as_echo "no" >&6; } 6982 fi 6983 6984 6985 if test "x$DATE" = x; then 6986 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6987 fi 6988 else 6989 # Otherwise we believe it is a complete path. Use it as it is. 6990 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5 6991 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;} 6992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6993 $as_echo_n "checking for DATE... " >&6; } 6994 if test ! -x "$tool_specified"; then 6995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6996 $as_echo "not found" >&6; } 6997 as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5 6998 fi 6999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7000 $as_echo "$tool_specified" >&6; } 7001 fi 7002 fi 7003 fi 7004 7005 fi 7006 7007 7008 7009 if test "x$DATE" = x; then 7010 as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5 7011 fi 7012 7013 7014 7015 7016 7017 # Publish this variable in the help. 7018 7019 7020 if [ -z "${DIFF+x}" ]; then 7021 # The variable is not set by user, try to locate tool using the code snippet 7022 for ac_prog in gdiff diff 7023 do 7024 # Extract the first word of "$ac_prog", so it can be a program name with args. 7025 set dummy $ac_prog; ac_word=$2 7026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7027 $as_echo_n "checking for $ac_word... " >&6; } 7028 if ${ac_cv_path_DIFF+:} false; then : 7029 $as_echo_n "(cached) " >&6 7030 else 7031 case $DIFF in 7032 [\\/]* | ?:[\\/]*) 7033 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7034 ;; 7035 *) 7036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7037 for as_dir in $PATH 7038 do 7039 IFS=$as_save_IFS 7040 test -z "$as_dir" && as_dir=. 7041 for ac_exec_ext in '' $ac_executable_extensions; do 7042 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7043 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7044 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7045 break 2 7046 fi 7047 done 7048 done 7049 IFS=$as_save_IFS 7050 7051 ;; 7052 esac 7053 fi 7054 DIFF=$ac_cv_path_DIFF 7055 if test -n "$DIFF"; then 7056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7057 $as_echo "$DIFF" >&6; } 7058 else 7059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7060 $as_echo "no" >&6; } 7061 fi 7062 7063 7064 test -n "$DIFF" && break 7065 done 7066 7067 else 7068 # The variable is set, but is it from the command line or the environment? 7069 7070 # Try to remove the string !DIFF! from our list. 7071 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/} 7072 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7073 # If it failed, the variable was not from the command line. Ignore it, 7074 # but warn the user (except for BASH, which is always set by the calling BASH). 7075 if test "xDIFF" != xBASH; then 7076 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5 7077 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;} 7078 fi 7079 # Try to locate tool using the code snippet 7080 for ac_prog in gdiff diff 7081 do 7082 # Extract the first word of "$ac_prog", so it can be a program name with args. 7083 set dummy $ac_prog; ac_word=$2 7084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7085 $as_echo_n "checking for $ac_word... " >&6; } 7086 if ${ac_cv_path_DIFF+:} false; then : 7087 $as_echo_n "(cached) " >&6 7088 else 7089 case $DIFF in 7090 [\\/]* | ?:[\\/]*) 7091 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7092 ;; 7093 *) 7094 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7095 for as_dir in $PATH 7096 do 7097 IFS=$as_save_IFS 7098 test -z "$as_dir" && as_dir=. 7099 for ac_exec_ext in '' $ac_executable_extensions; do 7100 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7101 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7102 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7103 break 2 7104 fi 7105 done 7106 done 7107 IFS=$as_save_IFS 7108 7109 ;; 7110 esac 7111 fi 7112 DIFF=$ac_cv_path_DIFF 7113 if test -n "$DIFF"; then 7114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7115 $as_echo "$DIFF" >&6; } 7116 else 7117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7118 $as_echo "no" >&6; } 7119 fi 7120 7121 7122 test -n "$DIFF" && break 7123 done 7124 7125 else 7126 # If it succeeded, then it was overridden by the user. We will use it 7127 # for the tool. 7128 7129 # First remove it from the list of overridden variables, so we can test 7130 # for unknown variables in the end. 7131 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7132 7133 # Check if we try to supply an empty value 7134 if test "x$DIFF" = x; then 7135 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIFF= (no value)" >&5 7136 $as_echo "$as_me: Setting user supplied tool DIFF= (no value)" >&6;} 7137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7138 $as_echo_n "checking for DIFF... " >&6; } 7139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7140 $as_echo "disabled" >&6; } 7141 else 7142 # Check if the provided tool contains a complete path. 7143 tool_specified="$DIFF" 7144 tool_basename="${tool_specified##*/}" 7145 if test "x$tool_basename" = "x$tool_specified"; then 7146 # A command without a complete path is provided, search $PATH. 7147 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5 7148 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;} 7149 # Extract the first word of "$tool_basename", so it can be a program name with args. 7150 set dummy $tool_basename; ac_word=$2 7151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7152 $as_echo_n "checking for $ac_word... " >&6; } 7153 if ${ac_cv_path_DIFF+:} false; then : 7154 $as_echo_n "(cached) " >&6 7155 else 7156 case $DIFF in 7157 [\\/]* | ?:[\\/]*) 7158 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7159 ;; 7160 *) 7161 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7162 for as_dir in $PATH 7163 do 7164 IFS=$as_save_IFS 7165 test -z "$as_dir" && as_dir=. 7166 for ac_exec_ext in '' $ac_executable_extensions; do 7167 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7168 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7169 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7170 break 2 7171 fi 7172 done 7173 done 7174 IFS=$as_save_IFS 7175 7176 ;; 7177 esac 7178 fi 7179 DIFF=$ac_cv_path_DIFF 7180 if test -n "$DIFF"; then 7181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7182 $as_echo "$DIFF" >&6; } 7183 else 7184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7185 $as_echo "no" >&6; } 7186 fi 7187 7188 7189 if test "x$DIFF" = x; then 7190 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7191 fi 7192 else 7193 # Otherwise we believe it is a complete path. Use it as it is. 7194 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5 7195 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;} 7196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7197 $as_echo_n "checking for DIFF... " >&6; } 7198 if test ! -x "$tool_specified"; then 7199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7200 $as_echo "not found" >&6; } 7201 as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5 7202 fi 7203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7204 $as_echo "$tool_specified" >&6; } 7205 fi 7206 fi 7207 fi 7208 7209 fi 7210 7211 7212 7213 if test "x$DIFF" = x; then 7214 as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5 7215 fi 7216 7217 7218 7219 7220 7221 # Publish this variable in the help. 7222 7223 7224 if [ -z "${DIRNAME+x}" ]; then 7225 # The variable is not set by user, try to locate tool using the code snippet 7226 for ac_prog in dirname 7227 do 7228 # Extract the first word of "$ac_prog", so it can be a program name with args. 7229 set dummy $ac_prog; ac_word=$2 7230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7231 $as_echo_n "checking for $ac_word... " >&6; } 7232 if ${ac_cv_path_DIRNAME+:} false; then : 7233 $as_echo_n "(cached) " >&6 7234 else 7235 case $DIRNAME in 7236 [\\/]* | ?:[\\/]*) 7237 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7238 ;; 7239 *) 7240 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7241 for as_dir in $PATH 7242 do 7243 IFS=$as_save_IFS 7244 test -z "$as_dir" && as_dir=. 7245 for ac_exec_ext in '' $ac_executable_extensions; do 7246 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7247 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7248 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7249 break 2 7250 fi 7251 done 7252 done 7253 IFS=$as_save_IFS 7254 7255 ;; 7256 esac 7257 fi 7258 DIRNAME=$ac_cv_path_DIRNAME 7259 if test -n "$DIRNAME"; then 7260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7261 $as_echo "$DIRNAME" >&6; } 7262 else 7263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7264 $as_echo "no" >&6; } 7265 fi 7266 7267 7268 test -n "$DIRNAME" && break 7269 done 7270 7271 else 7272 # The variable is set, but is it from the command line or the environment? 7273 7274 # Try to remove the string !DIRNAME! from our list. 7275 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/} 7276 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7277 # If it failed, the variable was not from the command line. Ignore it, 7278 # but warn the user (except for BASH, which is always set by the calling BASH). 7279 if test "xDIRNAME" != xBASH; then 7280 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5 7281 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;} 7282 fi 7283 # Try to locate tool using the code snippet 7284 for ac_prog in dirname 7285 do 7286 # Extract the first word of "$ac_prog", so it can be a program name with args. 7287 set dummy $ac_prog; ac_word=$2 7288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7289 $as_echo_n "checking for $ac_word... " >&6; } 7290 if ${ac_cv_path_DIRNAME+:} false; then : 7291 $as_echo_n "(cached) " >&6 7292 else 7293 case $DIRNAME in 7294 [\\/]* | ?:[\\/]*) 7295 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7296 ;; 7297 *) 7298 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7299 for as_dir in $PATH 7300 do 7301 IFS=$as_save_IFS 7302 test -z "$as_dir" && as_dir=. 7303 for ac_exec_ext in '' $ac_executable_extensions; do 7304 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7305 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7306 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7307 break 2 7308 fi 7309 done 7310 done 7311 IFS=$as_save_IFS 7312 7313 ;; 7314 esac 7315 fi 7316 DIRNAME=$ac_cv_path_DIRNAME 7317 if test -n "$DIRNAME"; then 7318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7319 $as_echo "$DIRNAME" >&6; } 7320 else 7321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7322 $as_echo "no" >&6; } 7323 fi 7324 7325 7326 test -n "$DIRNAME" && break 7327 done 7328 7329 else 7330 # If it succeeded, then it was overridden by the user. We will use it 7331 # for the tool. 7332 7333 # First remove it from the list of overridden variables, so we can test 7334 # for unknown variables in the end. 7335 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7336 7337 # Check if we try to supply an empty value 7338 if test "x$DIRNAME" = x; then 7339 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIRNAME= (no value)" >&5 7340 $as_echo "$as_me: Setting user supplied tool DIRNAME= (no value)" >&6;} 7341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7342 $as_echo_n "checking for DIRNAME... " >&6; } 7343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7344 $as_echo "disabled" >&6; } 7345 else 7346 # Check if the provided tool contains a complete path. 7347 tool_specified="$DIRNAME" 7348 tool_basename="${tool_specified##*/}" 7349 if test "x$tool_basename" = "x$tool_specified"; then 7350 # A command without a complete path is provided, search $PATH. 7351 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5 7352 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;} 7353 # Extract the first word of "$tool_basename", so it can be a program name with args. 7354 set dummy $tool_basename; ac_word=$2 7355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7356 $as_echo_n "checking for $ac_word... " >&6; } 7357 if ${ac_cv_path_DIRNAME+:} false; then : 7358 $as_echo_n "(cached) " >&6 7359 else 7360 case $DIRNAME in 7361 [\\/]* | ?:[\\/]*) 7362 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7363 ;; 7364 *) 7365 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7366 for as_dir in $PATH 7367 do 7368 IFS=$as_save_IFS 7369 test -z "$as_dir" && as_dir=. 7370 for ac_exec_ext in '' $ac_executable_extensions; do 7371 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7372 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7373 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7374 break 2 7375 fi 7376 done 7377 done 7378 IFS=$as_save_IFS 7379 7380 ;; 7381 esac 7382 fi 7383 DIRNAME=$ac_cv_path_DIRNAME 7384 if test -n "$DIRNAME"; then 7385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7386 $as_echo "$DIRNAME" >&6; } 7387 else 7388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7389 $as_echo "no" >&6; } 7390 fi 7391 7392 7393 if test "x$DIRNAME" = x; then 7394 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7395 fi 7396 else 7397 # Otherwise we believe it is a complete path. Use it as it is. 7398 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5 7399 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;} 7400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7401 $as_echo_n "checking for DIRNAME... " >&6; } 7402 if test ! -x "$tool_specified"; then 7403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7404 $as_echo "not found" >&6; } 7405 as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 7406 fi 7407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7408 $as_echo "$tool_specified" >&6; } 7409 fi 7410 fi 7411 fi 7412 7413 fi 7414 7415 7416 7417 if test "x$DIRNAME" = x; then 7418 as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5 7419 fi 7420 7421 7422 7423 7424 7425 # Publish this variable in the help. 7426 7427 7428 if [ -z "${ECHO+x}" ]; then 7429 # The variable is not set by user, try to locate tool using the code snippet 7430 for ac_prog in echo 7431 do 7432 # Extract the first word of "$ac_prog", so it can be a program name with args. 7433 set dummy $ac_prog; ac_word=$2 7434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7435 $as_echo_n "checking for $ac_word... " >&6; } 7436 if ${ac_cv_path_ECHO+:} false; then : 7437 $as_echo_n "(cached) " >&6 7438 else 7439 case $ECHO in 7440 [\\/]* | ?:[\\/]*) 7441 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7442 ;; 7443 *) 7444 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7445 for as_dir in $PATH 7446 do 7447 IFS=$as_save_IFS 7448 test -z "$as_dir" && as_dir=. 7449 for ac_exec_ext in '' $ac_executable_extensions; do 7450 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7451 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7452 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7453 break 2 7454 fi 7455 done 7456 done 7457 IFS=$as_save_IFS 7458 7459 ;; 7460 esac 7461 fi 7462 ECHO=$ac_cv_path_ECHO 7463 if test -n "$ECHO"; then 7464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7465 $as_echo "$ECHO" >&6; } 7466 else 7467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7468 $as_echo "no" >&6; } 7469 fi 7470 7471 7472 test -n "$ECHO" && break 7473 done 7474 7475 else 7476 # The variable is set, but is it from the command line or the environment? 7477 7478 # Try to remove the string !ECHO! from our list. 7479 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/} 7480 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7481 # If it failed, the variable was not from the command line. Ignore it, 7482 # but warn the user (except for BASH, which is always set by the calling BASH). 7483 if test "xECHO" != xBASH; then 7484 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5 7485 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;} 7486 fi 7487 # Try to locate tool using the code snippet 7488 for ac_prog in echo 7489 do 7490 # Extract the first word of "$ac_prog", so it can be a program name with args. 7491 set dummy $ac_prog; ac_word=$2 7492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7493 $as_echo_n "checking for $ac_word... " >&6; } 7494 if ${ac_cv_path_ECHO+:} false; then : 7495 $as_echo_n "(cached) " >&6 7496 else 7497 case $ECHO in 7498 [\\/]* | ?:[\\/]*) 7499 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7500 ;; 7501 *) 7502 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7503 for as_dir in $PATH 7504 do 7505 IFS=$as_save_IFS 7506 test -z "$as_dir" && as_dir=. 7507 for ac_exec_ext in '' $ac_executable_extensions; do 7508 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7509 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7510 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7511 break 2 7512 fi 7513 done 7514 done 7515 IFS=$as_save_IFS 7516 7517 ;; 7518 esac 7519 fi 7520 ECHO=$ac_cv_path_ECHO 7521 if test -n "$ECHO"; then 7522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7523 $as_echo "$ECHO" >&6; } 7524 else 7525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7526 $as_echo "no" >&6; } 7527 fi 7528 7529 7530 test -n "$ECHO" && break 7531 done 7532 7533 else 7534 # If it succeeded, then it was overridden by the user. We will use it 7535 # for the tool. 7536 7537 # First remove it from the list of overridden variables, so we can test 7538 # for unknown variables in the end. 7539 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7540 7541 # Check if we try to supply an empty value 7542 if test "x$ECHO" = x; then 7543 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ECHO= (no value)" >&5 7544 $as_echo "$as_me: Setting user supplied tool ECHO= (no value)" >&6;} 7545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7546 $as_echo_n "checking for ECHO... " >&6; } 7547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7548 $as_echo "disabled" >&6; } 7549 else 7550 # Check if the provided tool contains a complete path. 7551 tool_specified="$ECHO" 7552 tool_basename="${tool_specified##*/}" 7553 if test "x$tool_basename" = "x$tool_specified"; then 7554 # A command without a complete path is provided, search $PATH. 7555 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5 7556 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;} 7557 # Extract the first word of "$tool_basename", so it can be a program name with args. 7558 set dummy $tool_basename; ac_word=$2 7559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7560 $as_echo_n "checking for $ac_word... " >&6; } 7561 if ${ac_cv_path_ECHO+:} false; then : 7562 $as_echo_n "(cached) " >&6 7563 else 7564 case $ECHO in 7565 [\\/]* | ?:[\\/]*) 7566 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7567 ;; 7568 *) 7569 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7570 for as_dir in $PATH 7571 do 7572 IFS=$as_save_IFS 7573 test -z "$as_dir" && as_dir=. 7574 for ac_exec_ext in '' $ac_executable_extensions; do 7575 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7576 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7577 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7578 break 2 7579 fi 7580 done 7581 done 7582 IFS=$as_save_IFS 7583 7584 ;; 7585 esac 7586 fi 7587 ECHO=$ac_cv_path_ECHO 7588 if test -n "$ECHO"; then 7589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7590 $as_echo "$ECHO" >&6; } 7591 else 7592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7593 $as_echo "no" >&6; } 7594 fi 7595 7596 7597 if test "x$ECHO" = x; then 7598 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7599 fi 7600 else 7601 # Otherwise we believe it is a complete path. Use it as it is. 7602 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5 7603 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;} 7604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7605 $as_echo_n "checking for ECHO... " >&6; } 7606 if test ! -x "$tool_specified"; then 7607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7608 $as_echo "not found" >&6; } 7609 as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5 7610 fi 7611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7612 $as_echo "$tool_specified" >&6; } 7613 fi 7614 fi 7615 fi 7616 7617 fi 7618 7619 7620 7621 if test "x$ECHO" = x; then 7622 as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5 7623 fi 7624 7625 7626 7627 7628 7629 # Publish this variable in the help. 7630 7631 7632 if [ -z "${EXPR+x}" ]; then 7633 # The variable is not set by user, try to locate tool using the code snippet 7634 for ac_prog in expr 7635 do 7636 # Extract the first word of "$ac_prog", so it can be a program name with args. 7637 set dummy $ac_prog; ac_word=$2 7638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7639 $as_echo_n "checking for $ac_word... " >&6; } 7640 if ${ac_cv_path_EXPR+:} false; then : 7641 $as_echo_n "(cached) " >&6 7642 else 7643 case $EXPR in 7644 [\\/]* | ?:[\\/]*) 7645 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7646 ;; 7647 *) 7648 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7649 for as_dir in $PATH 7650 do 7651 IFS=$as_save_IFS 7652 test -z "$as_dir" && as_dir=. 7653 for ac_exec_ext in '' $ac_executable_extensions; do 7654 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7655 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7656 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7657 break 2 7658 fi 7659 done 7660 done 7661 IFS=$as_save_IFS 7662 7663 ;; 7664 esac 7665 fi 7666 EXPR=$ac_cv_path_EXPR 7667 if test -n "$EXPR"; then 7668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7669 $as_echo "$EXPR" >&6; } 7670 else 7671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7672 $as_echo "no" >&6; } 7673 fi 7674 7675 7676 test -n "$EXPR" && break 7677 done 7678 7679 else 7680 # The variable is set, but is it from the command line or the environment? 7681 7682 # Try to remove the string !EXPR! from our list. 7683 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/} 7684 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7685 # If it failed, the variable was not from the command line. Ignore it, 7686 # but warn the user (except for BASH, which is always set by the calling BASH). 7687 if test "xEXPR" != xBASH; then 7688 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5 7689 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;} 7690 fi 7691 # Try to locate tool using the code snippet 7692 for ac_prog in expr 7693 do 7694 # Extract the first word of "$ac_prog", so it can be a program name with args. 7695 set dummy $ac_prog; ac_word=$2 7696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7697 $as_echo_n "checking for $ac_word... " >&6; } 7698 if ${ac_cv_path_EXPR+:} false; then : 7699 $as_echo_n "(cached) " >&6 7700 else 7701 case $EXPR in 7702 [\\/]* | ?:[\\/]*) 7703 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7704 ;; 7705 *) 7706 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7707 for as_dir in $PATH 7708 do 7709 IFS=$as_save_IFS 7710 test -z "$as_dir" && as_dir=. 7711 for ac_exec_ext in '' $ac_executable_extensions; do 7712 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7713 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7714 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7715 break 2 7716 fi 7717 done 7718 done 7719 IFS=$as_save_IFS 7720 7721 ;; 7722 esac 7723 fi 7724 EXPR=$ac_cv_path_EXPR 7725 if test -n "$EXPR"; then 7726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7727 $as_echo "$EXPR" >&6; } 7728 else 7729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7730 $as_echo "no" >&6; } 7731 fi 7732 7733 7734 test -n "$EXPR" && break 7735 done 7736 7737 else 7738 # If it succeeded, then it was overridden by the user. We will use it 7739 # for the tool. 7740 7741 # First remove it from the list of overridden variables, so we can test 7742 # for unknown variables in the end. 7743 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7744 7745 # Check if we try to supply an empty value 7746 if test "x$EXPR" = x; then 7747 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EXPR= (no value)" >&5 7748 $as_echo "$as_me: Setting user supplied tool EXPR= (no value)" >&6;} 7749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7750 $as_echo_n "checking for EXPR... " >&6; } 7751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7752 $as_echo "disabled" >&6; } 7753 else 7754 # Check if the provided tool contains a complete path. 7755 tool_specified="$EXPR" 7756 tool_basename="${tool_specified##*/}" 7757 if test "x$tool_basename" = "x$tool_specified"; then 7758 # A command without a complete path is provided, search $PATH. 7759 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5 7760 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;} 7761 # Extract the first word of "$tool_basename", so it can be a program name with args. 7762 set dummy $tool_basename; ac_word=$2 7763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7764 $as_echo_n "checking for $ac_word... " >&6; } 7765 if ${ac_cv_path_EXPR+:} false; then : 7766 $as_echo_n "(cached) " >&6 7767 else 7768 case $EXPR in 7769 [\\/]* | ?:[\\/]*) 7770 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7771 ;; 7772 *) 7773 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7774 for as_dir in $PATH 7775 do 7776 IFS=$as_save_IFS 7777 test -z "$as_dir" && as_dir=. 7778 for ac_exec_ext in '' $ac_executable_extensions; do 7779 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7780 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7781 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7782 break 2 7783 fi 7784 done 7785 done 7786 IFS=$as_save_IFS 7787 7788 ;; 7789 esac 7790 fi 7791 EXPR=$ac_cv_path_EXPR 7792 if test -n "$EXPR"; then 7793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7794 $as_echo "$EXPR" >&6; } 7795 else 7796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7797 $as_echo "no" >&6; } 7798 fi 7799 7800 7801 if test "x$EXPR" = x; then 7802 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7803 fi 7804 else 7805 # Otherwise we believe it is a complete path. Use it as it is. 7806 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5 7807 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;} 7808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7809 $as_echo_n "checking for EXPR... " >&6; } 7810 if test ! -x "$tool_specified"; then 7811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7812 $as_echo "not found" >&6; } 7813 as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5 7814 fi 7815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7816 $as_echo "$tool_specified" >&6; } 7817 fi 7818 fi 7819 fi 7820 7821 fi 7822 7823 7824 7825 if test "x$EXPR" = x; then 7826 as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5 7827 fi 7828 7829 7830 7831 7832 7833 # Publish this variable in the help. 7834 7835 7836 if [ -z "${FILE+x}" ]; then 7837 # The variable is not set by user, try to locate tool using the code snippet 7838 for ac_prog in file 7839 do 7840 # Extract the first word of "$ac_prog", so it can be a program name with args. 7841 set dummy $ac_prog; ac_word=$2 7842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7843 $as_echo_n "checking for $ac_word... " >&6; } 7844 if ${ac_cv_path_FILE+:} false; then : 7845 $as_echo_n "(cached) " >&6 7846 else 7847 case $FILE in 7848 [\\/]* | ?:[\\/]*) 7849 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7850 ;; 7851 *) 7852 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7853 for as_dir in $PATH 7854 do 7855 IFS=$as_save_IFS 7856 test -z "$as_dir" && as_dir=. 7857 for ac_exec_ext in '' $ac_executable_extensions; do 7858 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7859 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7860 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7861 break 2 7862 fi 7863 done 7864 done 7865 IFS=$as_save_IFS 7866 7867 ;; 7868 esac 7869 fi 7870 FILE=$ac_cv_path_FILE 7871 if test -n "$FILE"; then 7872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7873 $as_echo "$FILE" >&6; } 7874 else 7875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7876 $as_echo "no" >&6; } 7877 fi 7878 7879 7880 test -n "$FILE" && break 7881 done 7882 7883 else 7884 # The variable is set, but is it from the command line or the environment? 7885 7886 # Try to remove the string !FILE! from our list. 7887 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/} 7888 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7889 # If it failed, the variable was not from the command line. Ignore it, 7890 # but warn the user (except for BASH, which is always set by the calling BASH). 7891 if test "xFILE" != xBASH; then 7892 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5 7893 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;} 7894 fi 7895 # Try to locate tool using the code snippet 7896 for ac_prog in file 7897 do 7898 # Extract the first word of "$ac_prog", so it can be a program name with args. 7899 set dummy $ac_prog; ac_word=$2 7900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7901 $as_echo_n "checking for $ac_word... " >&6; } 7902 if ${ac_cv_path_FILE+:} false; then : 7903 $as_echo_n "(cached) " >&6 7904 else 7905 case $FILE in 7906 [\\/]* | ?:[\\/]*) 7907 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7908 ;; 7909 *) 7910 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7911 for as_dir in $PATH 7912 do 7913 IFS=$as_save_IFS 7914 test -z "$as_dir" && as_dir=. 7915 for ac_exec_ext in '' $ac_executable_extensions; do 7916 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7917 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7918 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7919 break 2 7920 fi 7921 done 7922 done 7923 IFS=$as_save_IFS 7924 7925 ;; 7926 esac 7927 fi 7928 FILE=$ac_cv_path_FILE 7929 if test -n "$FILE"; then 7930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7931 $as_echo "$FILE" >&6; } 7932 else 7933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7934 $as_echo "no" >&6; } 7935 fi 7936 7937 7938 test -n "$FILE" && break 7939 done 7940 7941 else 7942 # If it succeeded, then it was overridden by the user. We will use it 7943 # for the tool. 7944 7945 # First remove it from the list of overridden variables, so we can test 7946 # for unknown variables in the end. 7947 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7948 7949 # Check if we try to supply an empty value 7950 if test "x$FILE" = x; then 7951 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FILE= (no value)" >&5 7952 $as_echo "$as_me: Setting user supplied tool FILE= (no value)" >&6;} 7953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 7954 $as_echo_n "checking for FILE... " >&6; } 7955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7956 $as_echo "disabled" >&6; } 7957 else 7958 # Check if the provided tool contains a complete path. 7959 tool_specified="$FILE" 7960 tool_basename="${tool_specified##*/}" 7961 if test "x$tool_basename" = "x$tool_specified"; then 7962 # A command without a complete path is provided, search $PATH. 7963 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5 7964 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;} 7965 # Extract the first word of "$tool_basename", so it can be a program name with args. 7966 set dummy $tool_basename; ac_word=$2 7967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7968 $as_echo_n "checking for $ac_word... " >&6; } 7969 if ${ac_cv_path_FILE+:} false; then : 7970 $as_echo_n "(cached) " >&6 7971 else 7972 case $FILE in 7973 [\\/]* | ?:[\\/]*) 7974 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7975 ;; 7976 *) 7977 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7978 for as_dir in $PATH 7979 do 7980 IFS=$as_save_IFS 7981 test -z "$as_dir" && as_dir=. 7982 for ac_exec_ext in '' $ac_executable_extensions; do 7983 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7984 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7985 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7986 break 2 7987 fi 7988 done 7989 done 7990 IFS=$as_save_IFS 7991 7992 ;; 7993 esac 7994 fi 7995 FILE=$ac_cv_path_FILE 7996 if test -n "$FILE"; then 7997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7998 $as_echo "$FILE" >&6; } 7999 else 8000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8001 $as_echo "no" >&6; } 8002 fi 8003 8004 8005 if test "x$FILE" = x; then 8006 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8007 fi 8008 else 8009 # Otherwise we believe it is a complete path. Use it as it is. 8010 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5 8011 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;} 8012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 8013 $as_echo_n "checking for FILE... " >&6; } 8014 if test ! -x "$tool_specified"; then 8015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8016 $as_echo "not found" >&6; } 8017 as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5 8018 fi 8019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8020 $as_echo "$tool_specified" >&6; } 8021 fi 8022 fi 8023 fi 8024 8025 fi 8026 8027 8028 8029 if test "x$FILE" = x; then 8030 as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5 8031 fi 8032 8033 8034 8035 8036 8037 # Publish this variable in the help. 8038 8039 8040 if [ -z "${FIND+x}" ]; then 8041 # The variable is not set by user, try to locate tool using the code snippet 8042 for ac_prog in find 8043 do 8044 # Extract the first word of "$ac_prog", so it can be a program name with args. 8045 set dummy $ac_prog; ac_word=$2 8046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8047 $as_echo_n "checking for $ac_word... " >&6; } 8048 if ${ac_cv_path_FIND+:} false; then : 8049 $as_echo_n "(cached) " >&6 8050 else 8051 case $FIND in 8052 [\\/]* | ?:[\\/]*) 8053 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8054 ;; 8055 *) 8056 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8057 for as_dir in $PATH 8058 do 8059 IFS=$as_save_IFS 8060 test -z "$as_dir" && as_dir=. 8061 for ac_exec_ext in '' $ac_executable_extensions; do 8062 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8063 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8064 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8065 break 2 8066 fi 8067 done 8068 done 8069 IFS=$as_save_IFS 8070 8071 ;; 8072 esac 8073 fi 8074 FIND=$ac_cv_path_FIND 8075 if test -n "$FIND"; then 8076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8077 $as_echo "$FIND" >&6; } 8078 else 8079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8080 $as_echo "no" >&6; } 8081 fi 8082 8083 8084 test -n "$FIND" && break 8085 done 8086 8087 else 8088 # The variable is set, but is it from the command line or the environment? 8089 8090 # Try to remove the string !FIND! from our list. 8091 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/} 8092 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8093 # If it failed, the variable was not from the command line. Ignore it, 8094 # but warn the user (except for BASH, which is always set by the calling BASH). 8095 if test "xFIND" != xBASH; then 8096 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5 8097 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;} 8098 fi 8099 # Try to locate tool using the code snippet 8100 for ac_prog in find 8101 do 8102 # Extract the first word of "$ac_prog", so it can be a program name with args. 8103 set dummy $ac_prog; ac_word=$2 8104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8105 $as_echo_n "checking for $ac_word... " >&6; } 8106 if ${ac_cv_path_FIND+:} false; then : 8107 $as_echo_n "(cached) " >&6 8108 else 8109 case $FIND in 8110 [\\/]* | ?:[\\/]*) 8111 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8112 ;; 8113 *) 8114 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8115 for as_dir in $PATH 8116 do 8117 IFS=$as_save_IFS 8118 test -z "$as_dir" && as_dir=. 8119 for ac_exec_ext in '' $ac_executable_extensions; do 8120 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8121 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8122 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8123 break 2 8124 fi 8125 done 8126 done 8127 IFS=$as_save_IFS 8128 8129 ;; 8130 esac 8131 fi 8132 FIND=$ac_cv_path_FIND 8133 if test -n "$FIND"; then 8134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8135 $as_echo "$FIND" >&6; } 8136 else 8137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8138 $as_echo "no" >&6; } 8139 fi 8140 8141 8142 test -n "$FIND" && break 8143 done 8144 8145 else 8146 # If it succeeded, then it was overridden by the user. We will use it 8147 # for the tool. 8148 8149 # First remove it from the list of overridden variables, so we can test 8150 # for unknown variables in the end. 8151 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8152 8153 # Check if we try to supply an empty value 8154 if test "x$FIND" = x; then 8155 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FIND= (no value)" >&5 8156 $as_echo "$as_me: Setting user supplied tool FIND= (no value)" >&6;} 8157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8158 $as_echo_n "checking for FIND... " >&6; } 8159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8160 $as_echo "disabled" >&6; } 8161 else 8162 # Check if the provided tool contains a complete path. 8163 tool_specified="$FIND" 8164 tool_basename="${tool_specified##*/}" 8165 if test "x$tool_basename" = "x$tool_specified"; then 8166 # A command without a complete path is provided, search $PATH. 8167 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5 8168 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;} 8169 # Extract the first word of "$tool_basename", so it can be a program name with args. 8170 set dummy $tool_basename; ac_word=$2 8171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8172 $as_echo_n "checking for $ac_word... " >&6; } 8173 if ${ac_cv_path_FIND+:} false; then : 8174 $as_echo_n "(cached) " >&6 8175 else 8176 case $FIND in 8177 [\\/]* | ?:[\\/]*) 8178 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8179 ;; 8180 *) 8181 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8182 for as_dir in $PATH 8183 do 8184 IFS=$as_save_IFS 8185 test -z "$as_dir" && as_dir=. 8186 for ac_exec_ext in '' $ac_executable_extensions; do 8187 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8188 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8189 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8190 break 2 8191 fi 8192 done 8193 done 8194 IFS=$as_save_IFS 8195 8196 ;; 8197 esac 8198 fi 8199 FIND=$ac_cv_path_FIND 8200 if test -n "$FIND"; then 8201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8202 $as_echo "$FIND" >&6; } 8203 else 8204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8205 $as_echo "no" >&6; } 8206 fi 8207 8208 8209 if test "x$FIND" = x; then 8210 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8211 fi 8212 else 8213 # Otherwise we believe it is a complete path. Use it as it is. 8214 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5 8215 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;} 8216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8217 $as_echo_n "checking for FIND... " >&6; } 8218 if test ! -x "$tool_specified"; then 8219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8220 $as_echo "not found" >&6; } 8221 as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5 8222 fi 8223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8224 $as_echo "$tool_specified" >&6; } 8225 fi 8226 fi 8227 fi 8228 8229 fi 8230 8231 8232 8233 if test "x$FIND" = x; then 8234 as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5 8235 fi 8236 8237 8238 8239 8240 8241 # Publish this variable in the help. 8242 8243 8244 if [ -z "${HEAD+x}" ]; then 8245 # The variable is not set by user, try to locate tool using the code snippet 8246 for ac_prog in head 8247 do 8248 # Extract the first word of "$ac_prog", so it can be a program name with args. 8249 set dummy $ac_prog; ac_word=$2 8250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8251 $as_echo_n "checking for $ac_word... " >&6; } 8252 if ${ac_cv_path_HEAD+:} false; then : 8253 $as_echo_n "(cached) " >&6 8254 else 8255 case $HEAD in 8256 [\\/]* | ?:[\\/]*) 8257 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8258 ;; 8259 *) 8260 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8261 for as_dir in $PATH 8262 do 8263 IFS=$as_save_IFS 8264 test -z "$as_dir" && as_dir=. 8265 for ac_exec_ext in '' $ac_executable_extensions; do 8266 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8267 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8268 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8269 break 2 8270 fi 8271 done 8272 done 8273 IFS=$as_save_IFS 8274 8275 ;; 8276 esac 8277 fi 8278 HEAD=$ac_cv_path_HEAD 8279 if test -n "$HEAD"; then 8280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8281 $as_echo "$HEAD" >&6; } 8282 else 8283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8284 $as_echo "no" >&6; } 8285 fi 8286 8287 8288 test -n "$HEAD" && break 8289 done 8290 8291 else 8292 # The variable is set, but is it from the command line or the environment? 8293 8294 # Try to remove the string !HEAD! from our list. 8295 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/} 8296 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8297 # If it failed, the variable was not from the command line. Ignore it, 8298 # but warn the user (except for BASH, which is always set by the calling BASH). 8299 if test "xHEAD" != xBASH; then 8300 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5 8301 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;} 8302 fi 8303 # Try to locate tool using the code snippet 8304 for ac_prog in head 8305 do 8306 # Extract the first word of "$ac_prog", so it can be a program name with args. 8307 set dummy $ac_prog; ac_word=$2 8308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8309 $as_echo_n "checking for $ac_word... " >&6; } 8310 if ${ac_cv_path_HEAD+:} false; then : 8311 $as_echo_n "(cached) " >&6 8312 else 8313 case $HEAD in 8314 [\\/]* | ?:[\\/]*) 8315 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8316 ;; 8317 *) 8318 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8319 for as_dir in $PATH 8320 do 8321 IFS=$as_save_IFS 8322 test -z "$as_dir" && as_dir=. 8323 for ac_exec_ext in '' $ac_executable_extensions; do 8324 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8325 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8326 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8327 break 2 8328 fi 8329 done 8330 done 8331 IFS=$as_save_IFS 8332 8333 ;; 8334 esac 8335 fi 8336 HEAD=$ac_cv_path_HEAD 8337 if test -n "$HEAD"; then 8338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8339 $as_echo "$HEAD" >&6; } 8340 else 8341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8342 $as_echo "no" >&6; } 8343 fi 8344 8345 8346 test -n "$HEAD" && break 8347 done 8348 8349 else 8350 # If it succeeded, then it was overridden by the user. We will use it 8351 # for the tool. 8352 8353 # First remove it from the list of overridden variables, so we can test 8354 # for unknown variables in the end. 8355 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8356 8357 # Check if we try to supply an empty value 8358 if test "x$HEAD" = x; then 8359 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HEAD= (no value)" >&5 8360 $as_echo "$as_me: Setting user supplied tool HEAD= (no value)" >&6;} 8361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8362 $as_echo_n "checking for HEAD... " >&6; } 8363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8364 $as_echo "disabled" >&6; } 8365 else 8366 # Check if the provided tool contains a complete path. 8367 tool_specified="$HEAD" 8368 tool_basename="${tool_specified##*/}" 8369 if test "x$tool_basename" = "x$tool_specified"; then 8370 # A command without a complete path is provided, search $PATH. 8371 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5 8372 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;} 8373 # Extract the first word of "$tool_basename", so it can be a program name with args. 8374 set dummy $tool_basename; ac_word=$2 8375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8376 $as_echo_n "checking for $ac_word... " >&6; } 8377 if ${ac_cv_path_HEAD+:} false; then : 8378 $as_echo_n "(cached) " >&6 8379 else 8380 case $HEAD in 8381 [\\/]* | ?:[\\/]*) 8382 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8383 ;; 8384 *) 8385 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8386 for as_dir in $PATH 8387 do 8388 IFS=$as_save_IFS 8389 test -z "$as_dir" && as_dir=. 8390 for ac_exec_ext in '' $ac_executable_extensions; do 8391 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8392 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8393 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8394 break 2 8395 fi 8396 done 8397 done 8398 IFS=$as_save_IFS 8399 8400 ;; 8401 esac 8402 fi 8403 HEAD=$ac_cv_path_HEAD 8404 if test -n "$HEAD"; then 8405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8406 $as_echo "$HEAD" >&6; } 8407 else 8408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8409 $as_echo "no" >&6; } 8410 fi 8411 8412 8413 if test "x$HEAD" = x; then 8414 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8415 fi 8416 else 8417 # Otherwise we believe it is a complete path. Use it as it is. 8418 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5 8419 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;} 8420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8421 $as_echo_n "checking for HEAD... " >&6; } 8422 if test ! -x "$tool_specified"; then 8423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8424 $as_echo "not found" >&6; } 8425 as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5 8426 fi 8427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8428 $as_echo "$tool_specified" >&6; } 8429 fi 8430 fi 8431 fi 8432 8433 fi 8434 8435 8436 8437 if test "x$HEAD" = x; then 8438 as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5 8439 fi 8440 8441 8442 8443 8444 8445 # Publish this variable in the help. 8446 8447 8448 if [ -z "${GUNZIP+x}" ]; then 8449 # The variable is not set by user, try to locate tool using the code snippet 8450 for ac_prog in gunzip 8451 do 8452 # Extract the first word of "$ac_prog", so it can be a program name with args. 8453 set dummy $ac_prog; ac_word=$2 8454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8455 $as_echo_n "checking for $ac_word... " >&6; } 8456 if ${ac_cv_path_GUNZIP+:} false; then : 8457 $as_echo_n "(cached) " >&6 8458 else 8459 case $GUNZIP in 8460 [\\/]* | ?:[\\/]*) 8461 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8462 ;; 8463 *) 8464 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8465 for as_dir in $PATH 8466 do 8467 IFS=$as_save_IFS 8468 test -z "$as_dir" && as_dir=. 8469 for ac_exec_ext in '' $ac_executable_extensions; do 8470 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8471 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8472 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8473 break 2 8474 fi 8475 done 8476 done 8477 IFS=$as_save_IFS 8478 8479 ;; 8480 esac 8481 fi 8482 GUNZIP=$ac_cv_path_GUNZIP 8483 if test -n "$GUNZIP"; then 8484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8485 $as_echo "$GUNZIP" >&6; } 8486 else 8487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8488 $as_echo "no" >&6; } 8489 fi 8490 8491 8492 test -n "$GUNZIP" && break 8493 done 8494 8495 else 8496 # The variable is set, but is it from the command line or the environment? 8497 8498 # Try to remove the string !GUNZIP! from our list. 8499 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GUNZIP!/} 8500 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8501 # If it failed, the variable was not from the command line. Ignore it, 8502 # but warn the user (except for BASH, which is always set by the calling BASH). 8503 if test "xGUNZIP" != xBASH; then 8504 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&5 8505 $as_echo "$as_me: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&2;} 8506 fi 8507 # Try to locate tool using the code snippet 8508 for ac_prog in gunzip 8509 do 8510 # Extract the first word of "$ac_prog", so it can be a program name with args. 8511 set dummy $ac_prog; ac_word=$2 8512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8513 $as_echo_n "checking for $ac_word... " >&6; } 8514 if ${ac_cv_path_GUNZIP+:} false; then : 8515 $as_echo_n "(cached) " >&6 8516 else 8517 case $GUNZIP in 8518 [\\/]* | ?:[\\/]*) 8519 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8520 ;; 8521 *) 8522 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8523 for as_dir in $PATH 8524 do 8525 IFS=$as_save_IFS 8526 test -z "$as_dir" && as_dir=. 8527 for ac_exec_ext in '' $ac_executable_extensions; do 8528 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8529 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8530 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8531 break 2 8532 fi 8533 done 8534 done 8535 IFS=$as_save_IFS 8536 8537 ;; 8538 esac 8539 fi 8540 GUNZIP=$ac_cv_path_GUNZIP 8541 if test -n "$GUNZIP"; then 8542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8543 $as_echo "$GUNZIP" >&6; } 8544 else 8545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8546 $as_echo "no" >&6; } 8547 fi 8548 8549 8550 test -n "$GUNZIP" && break 8551 done 8552 8553 else 8554 # If it succeeded, then it was overridden by the user. We will use it 8555 # for the tool. 8556 8557 # First remove it from the list of overridden variables, so we can test 8558 # for unknown variables in the end. 8559 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8560 8561 # Check if we try to supply an empty value 8562 if test "x$GUNZIP" = x; then 8563 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GUNZIP= (no value)" >&5 8564 $as_echo "$as_me: Setting user supplied tool GUNZIP= (no value)" >&6;} 8565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8566 $as_echo_n "checking for GUNZIP... " >&6; } 8567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8568 $as_echo "disabled" >&6; } 8569 else 8570 # Check if the provided tool contains a complete path. 8571 tool_specified="$GUNZIP" 8572 tool_basename="${tool_specified##*/}" 8573 if test "x$tool_basename" = "x$tool_specified"; then 8574 # A command without a complete path is provided, search $PATH. 8575 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GUNZIP=$tool_basename" >&5 8576 $as_echo "$as_me: Will search for user supplied tool GUNZIP=$tool_basename" >&6;} 8577 # Extract the first word of "$tool_basename", so it can be a program name with args. 8578 set dummy $tool_basename; ac_word=$2 8579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8580 $as_echo_n "checking for $ac_word... " >&6; } 8581 if ${ac_cv_path_GUNZIP+:} false; then : 8582 $as_echo_n "(cached) " >&6 8583 else 8584 case $GUNZIP in 8585 [\\/]* | ?:[\\/]*) 8586 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8587 ;; 8588 *) 8589 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8590 for as_dir in $PATH 8591 do 8592 IFS=$as_save_IFS 8593 test -z "$as_dir" && as_dir=. 8594 for ac_exec_ext in '' $ac_executable_extensions; do 8595 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8596 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8597 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8598 break 2 8599 fi 8600 done 8601 done 8602 IFS=$as_save_IFS 8603 8604 ;; 8605 esac 8606 fi 8607 GUNZIP=$ac_cv_path_GUNZIP 8608 if test -n "$GUNZIP"; then 8609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8610 $as_echo "$GUNZIP" >&6; } 8611 else 8612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8613 $as_echo "no" >&6; } 8614 fi 8615 8616 8617 if test "x$GUNZIP" = x; then 8618 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8619 fi 8620 else 8621 # Otherwise we believe it is a complete path. Use it as it is. 8622 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GUNZIP=$tool_specified" >&5 8623 $as_echo "$as_me: Will use user supplied tool GUNZIP=$tool_specified" >&6;} 8624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8625 $as_echo_n "checking for GUNZIP... " >&6; } 8626 if test ! -x "$tool_specified"; then 8627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8628 $as_echo "not found" >&6; } 8629 as_fn_error $? "User supplied tool GUNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8630 fi 8631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8632 $as_echo "$tool_specified" >&6; } 8633 fi 8634 fi 8635 fi 8636 8637 fi 8638 8639 8640 8641 if test "x$GUNZIP" = x; then 8642 as_fn_error $? "Could not find required tool for GUNZIP" "$LINENO" 5 8643 fi 8644 8645 8646 8647 8648 8649 # Publish this variable in the help. 8650 8651 8652 if [ -z "${GZIP+x}" ]; then 8653 # The variable is not set by user, try to locate tool using the code snippet 8654 for ac_prog in pigz gzip 8655 do 8656 # Extract the first word of "$ac_prog", so it can be a program name with args. 8657 set dummy $ac_prog; ac_word=$2 8658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8659 $as_echo_n "checking for $ac_word... " >&6; } 8660 if ${ac_cv_path_GZIP+:} false; then : 8661 $as_echo_n "(cached) " >&6 8662 else 8663 case $GZIP in 8664 [\\/]* | ?:[\\/]*) 8665 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8666 ;; 8667 *) 8668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8669 for as_dir in $PATH 8670 do 8671 IFS=$as_save_IFS 8672 test -z "$as_dir" && as_dir=. 8673 for ac_exec_ext in '' $ac_executable_extensions; do 8674 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8675 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8676 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8677 break 2 8678 fi 8679 done 8680 done 8681 IFS=$as_save_IFS 8682 8683 ;; 8684 esac 8685 fi 8686 GZIP=$ac_cv_path_GZIP 8687 if test -n "$GZIP"; then 8688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8689 $as_echo "$GZIP" >&6; } 8690 else 8691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8692 $as_echo "no" >&6; } 8693 fi 8694 8695 8696 test -n "$GZIP" && break 8697 done 8698 8699 else 8700 # The variable is set, but is it from the command line or the environment? 8701 8702 # Try to remove the string !GZIP! from our list. 8703 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GZIP!/} 8704 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8705 # If it failed, the variable was not from the command line. Ignore it, 8706 # but warn the user (except for BASH, which is always set by the calling BASH). 8707 if test "xGZIP" != xBASH; then 8708 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&5 8709 $as_echo "$as_me: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&2;} 8710 fi 8711 # Try to locate tool using the code snippet 8712 for ac_prog in pigz gzip 8713 do 8714 # Extract the first word of "$ac_prog", so it can be a program name with args. 8715 set dummy $ac_prog; ac_word=$2 8716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8717 $as_echo_n "checking for $ac_word... " >&6; } 8718 if ${ac_cv_path_GZIP+:} false; then : 8719 $as_echo_n "(cached) " >&6 8720 else 8721 case $GZIP in 8722 [\\/]* | ?:[\\/]*) 8723 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8724 ;; 8725 *) 8726 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8727 for as_dir in $PATH 8728 do 8729 IFS=$as_save_IFS 8730 test -z "$as_dir" && as_dir=. 8731 for ac_exec_ext in '' $ac_executable_extensions; do 8732 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8733 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8734 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8735 break 2 8736 fi 8737 done 8738 done 8739 IFS=$as_save_IFS 8740 8741 ;; 8742 esac 8743 fi 8744 GZIP=$ac_cv_path_GZIP 8745 if test -n "$GZIP"; then 8746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8747 $as_echo "$GZIP" >&6; } 8748 else 8749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8750 $as_echo "no" >&6; } 8751 fi 8752 8753 8754 test -n "$GZIP" && break 8755 done 8756 8757 else 8758 # If it succeeded, then it was overridden by the user. We will use it 8759 # for the tool. 8760 8761 # First remove it from the list of overridden variables, so we can test 8762 # for unknown variables in the end. 8763 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8764 8765 # Check if we try to supply an empty value 8766 if test "x$GZIP" = x; then 8767 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GZIP= (no value)" >&5 8768 $as_echo "$as_me: Setting user supplied tool GZIP= (no value)" >&6;} 8769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8770 $as_echo_n "checking for GZIP... " >&6; } 8771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8772 $as_echo "disabled" >&6; } 8773 else 8774 # Check if the provided tool contains a complete path. 8775 tool_specified="$GZIP" 8776 tool_basename="${tool_specified##*/}" 8777 if test "x$tool_basename" = "x$tool_specified"; then 8778 # A command without a complete path is provided, search $PATH. 8779 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GZIP=$tool_basename" >&5 8780 $as_echo "$as_me: Will search for user supplied tool GZIP=$tool_basename" >&6;} 8781 # Extract the first word of "$tool_basename", so it can be a program name with args. 8782 set dummy $tool_basename; ac_word=$2 8783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8784 $as_echo_n "checking for $ac_word... " >&6; } 8785 if ${ac_cv_path_GZIP+:} false; then : 8786 $as_echo_n "(cached) " >&6 8787 else 8788 case $GZIP in 8789 [\\/]* | ?:[\\/]*) 8790 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8791 ;; 8792 *) 8793 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8794 for as_dir in $PATH 8795 do 8796 IFS=$as_save_IFS 8797 test -z "$as_dir" && as_dir=. 8798 for ac_exec_ext in '' $ac_executable_extensions; do 8799 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8800 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8802 break 2 8803 fi 8804 done 8805 done 8806 IFS=$as_save_IFS 8807 8808 ;; 8809 esac 8810 fi 8811 GZIP=$ac_cv_path_GZIP 8812 if test -n "$GZIP"; then 8813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8814 $as_echo "$GZIP" >&6; } 8815 else 8816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8817 $as_echo "no" >&6; } 8818 fi 8819 8820 8821 if test "x$GZIP" = x; then 8822 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8823 fi 8824 else 8825 # Otherwise we believe it is a complete path. Use it as it is. 8826 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GZIP=$tool_specified" >&5 8827 $as_echo "$as_me: Will use user supplied tool GZIP=$tool_specified" >&6;} 8828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8829 $as_echo_n "checking for GZIP... " >&6; } 8830 if test ! -x "$tool_specified"; then 8831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8832 $as_echo "not found" >&6; } 8833 as_fn_error $? "User supplied tool GZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8834 fi 8835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8836 $as_echo "$tool_specified" >&6; } 8837 fi 8838 fi 8839 fi 8840 8841 fi 8842 8843 8844 8845 if test "x$GZIP" = x; then 8846 as_fn_error $? "Could not find required tool for GZIP" "$LINENO" 5 8847 fi 8848 8849 8850 8851 8852 8853 # Publish this variable in the help. 8854 8855 8856 if [ -z "${LN+x}" ]; then 8857 # The variable is not set by user, try to locate tool using the code snippet 8858 for ac_prog in ln 8859 do 8860 # Extract the first word of "$ac_prog", so it can be a program name with args. 8861 set dummy $ac_prog; ac_word=$2 8862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8863 $as_echo_n "checking for $ac_word... " >&6; } 8864 if ${ac_cv_path_LN+:} false; then : 8865 $as_echo_n "(cached) " >&6 8866 else 8867 case $LN in 8868 [\\/]* | ?:[\\/]*) 8869 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8870 ;; 8871 *) 8872 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8873 for as_dir in $PATH 8874 do 8875 IFS=$as_save_IFS 8876 test -z "$as_dir" && as_dir=. 8877 for ac_exec_ext in '' $ac_executable_extensions; do 8878 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8879 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8880 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8881 break 2 8882 fi 8883 done 8884 done 8885 IFS=$as_save_IFS 8886 8887 ;; 8888 esac 8889 fi 8890 LN=$ac_cv_path_LN 8891 if test -n "$LN"; then 8892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8893 $as_echo "$LN" >&6; } 8894 else 8895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8896 $as_echo "no" >&6; } 8897 fi 8898 8899 8900 test -n "$LN" && break 8901 done 8902 8903 else 8904 # The variable is set, but is it from the command line or the environment? 8905 8906 # Try to remove the string !LN! from our list. 8907 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/} 8908 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8909 # If it failed, the variable was not from the command line. Ignore it, 8910 # but warn the user (except for BASH, which is always set by the calling BASH). 8911 if test "xLN" != xBASH; then 8912 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5 8913 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;} 8914 fi 8915 # Try to locate tool using the code snippet 8916 for ac_prog in ln 8917 do 8918 # Extract the first word of "$ac_prog", so it can be a program name with args. 8919 set dummy $ac_prog; ac_word=$2 8920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8921 $as_echo_n "checking for $ac_word... " >&6; } 8922 if ${ac_cv_path_LN+:} false; then : 8923 $as_echo_n "(cached) " >&6 8924 else 8925 case $LN in 8926 [\\/]* | ?:[\\/]*) 8927 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8928 ;; 8929 *) 8930 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8931 for as_dir in $PATH 8932 do 8933 IFS=$as_save_IFS 8934 test -z "$as_dir" && as_dir=. 8935 for ac_exec_ext in '' $ac_executable_extensions; do 8936 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8937 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8938 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8939 break 2 8940 fi 8941 done 8942 done 8943 IFS=$as_save_IFS 8944 8945 ;; 8946 esac 8947 fi 8948 LN=$ac_cv_path_LN 8949 if test -n "$LN"; then 8950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8951 $as_echo "$LN" >&6; } 8952 else 8953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8954 $as_echo "no" >&6; } 8955 fi 8956 8957 8958 test -n "$LN" && break 8959 done 8960 8961 else 8962 # If it succeeded, then it was overridden by the user. We will use it 8963 # for the tool. 8964 8965 # First remove it from the list of overridden variables, so we can test 8966 # for unknown variables in the end. 8967 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8968 8969 # Check if we try to supply an empty value 8970 if test "x$LN" = x; then 8971 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LN= (no value)" >&5 8972 $as_echo "$as_me: Setting user supplied tool LN= (no value)" >&6;} 8973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 8974 $as_echo_n "checking for LN... " >&6; } 8975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8976 $as_echo "disabled" >&6; } 8977 else 8978 # Check if the provided tool contains a complete path. 8979 tool_specified="$LN" 8980 tool_basename="${tool_specified##*/}" 8981 if test "x$tool_basename" = "x$tool_specified"; then 8982 # A command without a complete path is provided, search $PATH. 8983 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5 8984 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;} 8985 # Extract the first word of "$tool_basename", so it can be a program name with args. 8986 set dummy $tool_basename; ac_word=$2 8987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8988 $as_echo_n "checking for $ac_word... " >&6; } 8989 if ${ac_cv_path_LN+:} false; then : 8990 $as_echo_n "(cached) " >&6 8991 else 8992 case $LN in 8993 [\\/]* | ?:[\\/]*) 8994 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8995 ;; 8996 *) 8997 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8998 for as_dir in $PATH 8999 do 9000 IFS=$as_save_IFS 9001 test -z "$as_dir" && as_dir=. 9002 for ac_exec_ext in '' $ac_executable_extensions; do 9003 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9004 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 9005 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9006 break 2 9007 fi 9008 done 9009 done 9010 IFS=$as_save_IFS 9011 9012 ;; 9013 esac 9014 fi 9015 LN=$ac_cv_path_LN 9016 if test -n "$LN"; then 9017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 9018 $as_echo "$LN" >&6; } 9019 else 9020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9021 $as_echo "no" >&6; } 9022 fi 9023 9024 9025 if test "x$LN" = x; then 9026 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9027 fi 9028 else 9029 # Otherwise we believe it is a complete path. Use it as it is. 9030 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5 9031 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;} 9032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 9033 $as_echo_n "checking for LN... " >&6; } 9034 if test ! -x "$tool_specified"; then 9035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9036 $as_echo "not found" >&6; } 9037 as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5 9038 fi 9039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9040 $as_echo "$tool_specified" >&6; } 9041 fi 9042 fi 9043 fi 9044 9045 fi 9046 9047 9048 9049 if test "x$LN" = x; then 9050 as_fn_error $? "Could not find required tool for LN" "$LINENO" 5 9051 fi 9052 9053 9054 9055 9056 9057 # Publish this variable in the help. 9058 9059 9060 if [ -z "${LS+x}" ]; then 9061 # The variable is not set by user, try to locate tool using the code snippet 9062 for ac_prog in ls 9063 do 9064 # Extract the first word of "$ac_prog", so it can be a program name with args. 9065 set dummy $ac_prog; ac_word=$2 9066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9067 $as_echo_n "checking for $ac_word... " >&6; } 9068 if ${ac_cv_path_LS+:} false; then : 9069 $as_echo_n "(cached) " >&6 9070 else 9071 case $LS in 9072 [\\/]* | ?:[\\/]*) 9073 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9074 ;; 9075 *) 9076 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9077 for as_dir in $PATH 9078 do 9079 IFS=$as_save_IFS 9080 test -z "$as_dir" && as_dir=. 9081 for ac_exec_ext in '' $ac_executable_extensions; do 9082 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9083 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9084 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9085 break 2 9086 fi 9087 done 9088 done 9089 IFS=$as_save_IFS 9090 9091 ;; 9092 esac 9093 fi 9094 LS=$ac_cv_path_LS 9095 if test -n "$LS"; then 9096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9097 $as_echo "$LS" >&6; } 9098 else 9099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9100 $as_echo "no" >&6; } 9101 fi 9102 9103 9104 test -n "$LS" && break 9105 done 9106 9107 else 9108 # The variable is set, but is it from the command line or the environment? 9109 9110 # Try to remove the string !LS! from our list. 9111 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/} 9112 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9113 # If it failed, the variable was not from the command line. Ignore it, 9114 # but warn the user (except for BASH, which is always set by the calling BASH). 9115 if test "xLS" != xBASH; then 9116 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5 9117 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;} 9118 fi 9119 # Try to locate tool using the code snippet 9120 for ac_prog in ls 9121 do 9122 # Extract the first word of "$ac_prog", so it can be a program name with args. 9123 set dummy $ac_prog; ac_word=$2 9124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9125 $as_echo_n "checking for $ac_word... " >&6; } 9126 if ${ac_cv_path_LS+:} false; then : 9127 $as_echo_n "(cached) " >&6 9128 else 9129 case $LS in 9130 [\\/]* | ?:[\\/]*) 9131 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9132 ;; 9133 *) 9134 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9135 for as_dir in $PATH 9136 do 9137 IFS=$as_save_IFS 9138 test -z "$as_dir" && as_dir=. 9139 for ac_exec_ext in '' $ac_executable_extensions; do 9140 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9141 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9142 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9143 break 2 9144 fi 9145 done 9146 done 9147 IFS=$as_save_IFS 9148 9149 ;; 9150 esac 9151 fi 9152 LS=$ac_cv_path_LS 9153 if test -n "$LS"; then 9154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9155 $as_echo "$LS" >&6; } 9156 else 9157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9158 $as_echo "no" >&6; } 9159 fi 9160 9161 9162 test -n "$LS" && break 9163 done 9164 9165 else 9166 # If it succeeded, then it was overridden by the user. We will use it 9167 # for the tool. 9168 9169 # First remove it from the list of overridden variables, so we can test 9170 # for unknown variables in the end. 9171 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9172 9173 # Check if we try to supply an empty value 9174 if test "x$LS" = x; then 9175 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LS= (no value)" >&5 9176 $as_echo "$as_me: Setting user supplied tool LS= (no value)" >&6;} 9177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9178 $as_echo_n "checking for LS... " >&6; } 9179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9180 $as_echo "disabled" >&6; } 9181 else 9182 # Check if the provided tool contains a complete path. 9183 tool_specified="$LS" 9184 tool_basename="${tool_specified##*/}" 9185 if test "x$tool_basename" = "x$tool_specified"; then 9186 # A command without a complete path is provided, search $PATH. 9187 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5 9188 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;} 9189 # Extract the first word of "$tool_basename", so it can be a program name with args. 9190 set dummy $tool_basename; ac_word=$2 9191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9192 $as_echo_n "checking for $ac_word... " >&6; } 9193 if ${ac_cv_path_LS+:} false; then : 9194 $as_echo_n "(cached) " >&6 9195 else 9196 case $LS in 9197 [\\/]* | ?:[\\/]*) 9198 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9199 ;; 9200 *) 9201 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9202 for as_dir in $PATH 9203 do 9204 IFS=$as_save_IFS 9205 test -z "$as_dir" && as_dir=. 9206 for ac_exec_ext in '' $ac_executable_extensions; do 9207 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9208 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9209 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9210 break 2 9211 fi 9212 done 9213 done 9214 IFS=$as_save_IFS 9215 9216 ;; 9217 esac 9218 fi 9219 LS=$ac_cv_path_LS 9220 if test -n "$LS"; then 9221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9222 $as_echo "$LS" >&6; } 9223 else 9224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9225 $as_echo "no" >&6; } 9226 fi 9227 9228 9229 if test "x$LS" = x; then 9230 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9231 fi 9232 else 9233 # Otherwise we believe it is a complete path. Use it as it is. 9234 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5 9235 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;} 9236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9237 $as_echo_n "checking for LS... " >&6; } 9238 if test ! -x "$tool_specified"; then 9239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9240 $as_echo "not found" >&6; } 9241 as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5 9242 fi 9243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9244 $as_echo "$tool_specified" >&6; } 9245 fi 9246 fi 9247 fi 9248 9249 fi 9250 9251 9252 9253 if test "x$LS" = x; then 9254 as_fn_error $? "Could not find required tool for LS" "$LINENO" 5 9255 fi 9256 9257 9258 9259 9260 9261 # Publish this variable in the help. 9262 9263 9264 if [ -z "${MKDIR+x}" ]; then 9265 # The variable is not set by user, try to locate tool using the code snippet 9266 for ac_prog in mkdir 9267 do 9268 # Extract the first word of "$ac_prog", so it can be a program name with args. 9269 set dummy $ac_prog; ac_word=$2 9270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9271 $as_echo_n "checking for $ac_word... " >&6; } 9272 if ${ac_cv_path_MKDIR+:} false; then : 9273 $as_echo_n "(cached) " >&6 9274 else 9275 case $MKDIR in 9276 [\\/]* | ?:[\\/]*) 9277 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9278 ;; 9279 *) 9280 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9281 for as_dir in $PATH 9282 do 9283 IFS=$as_save_IFS 9284 test -z "$as_dir" && as_dir=. 9285 for ac_exec_ext in '' $ac_executable_extensions; do 9286 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9287 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9288 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9289 break 2 9290 fi 9291 done 9292 done 9293 IFS=$as_save_IFS 9294 9295 ;; 9296 esac 9297 fi 9298 MKDIR=$ac_cv_path_MKDIR 9299 if test -n "$MKDIR"; then 9300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9301 $as_echo "$MKDIR" >&6; } 9302 else 9303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9304 $as_echo "no" >&6; } 9305 fi 9306 9307 9308 test -n "$MKDIR" && break 9309 done 9310 9311 else 9312 # The variable is set, but is it from the command line or the environment? 9313 9314 # Try to remove the string !MKDIR! from our list. 9315 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/} 9316 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9317 # If it failed, the variable was not from the command line. Ignore it, 9318 # but warn the user (except for BASH, which is always set by the calling BASH). 9319 if test "xMKDIR" != xBASH; then 9320 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5 9321 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;} 9322 fi 9323 # Try to locate tool using the code snippet 9324 for ac_prog in mkdir 9325 do 9326 # Extract the first word of "$ac_prog", so it can be a program name with args. 9327 set dummy $ac_prog; ac_word=$2 9328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9329 $as_echo_n "checking for $ac_word... " >&6; } 9330 if ${ac_cv_path_MKDIR+:} false; then : 9331 $as_echo_n "(cached) " >&6 9332 else 9333 case $MKDIR in 9334 [\\/]* | ?:[\\/]*) 9335 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9336 ;; 9337 *) 9338 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9339 for as_dir in $PATH 9340 do 9341 IFS=$as_save_IFS 9342 test -z "$as_dir" && as_dir=. 9343 for ac_exec_ext in '' $ac_executable_extensions; do 9344 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9345 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9346 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9347 break 2 9348 fi 9349 done 9350 done 9351 IFS=$as_save_IFS 9352 9353 ;; 9354 esac 9355 fi 9356 MKDIR=$ac_cv_path_MKDIR 9357 if test -n "$MKDIR"; then 9358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9359 $as_echo "$MKDIR" >&6; } 9360 else 9361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9362 $as_echo "no" >&6; } 9363 fi 9364 9365 9366 test -n "$MKDIR" && break 9367 done 9368 9369 else 9370 # If it succeeded, then it was overridden by the user. We will use it 9371 # for the tool. 9372 9373 # First remove it from the list of overridden variables, so we can test 9374 # for unknown variables in the end. 9375 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9376 9377 # Check if we try to supply an empty value 9378 if test "x$MKDIR" = x; then 9379 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKDIR= (no value)" >&5 9380 $as_echo "$as_me: Setting user supplied tool MKDIR= (no value)" >&6;} 9381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9382 $as_echo_n "checking for MKDIR... " >&6; } 9383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9384 $as_echo "disabled" >&6; } 9385 else 9386 # Check if the provided tool contains a complete path. 9387 tool_specified="$MKDIR" 9388 tool_basename="${tool_specified##*/}" 9389 if test "x$tool_basename" = "x$tool_specified"; then 9390 # A command without a complete path is provided, search $PATH. 9391 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5 9392 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;} 9393 # Extract the first word of "$tool_basename", so it can be a program name with args. 9394 set dummy $tool_basename; ac_word=$2 9395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9396 $as_echo_n "checking for $ac_word... " >&6; } 9397 if ${ac_cv_path_MKDIR+:} false; then : 9398 $as_echo_n "(cached) " >&6 9399 else 9400 case $MKDIR in 9401 [\\/]* | ?:[\\/]*) 9402 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9403 ;; 9404 *) 9405 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9406 for as_dir in $PATH 9407 do 9408 IFS=$as_save_IFS 9409 test -z "$as_dir" && as_dir=. 9410 for ac_exec_ext in '' $ac_executable_extensions; do 9411 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9412 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9413 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9414 break 2 9415 fi 9416 done 9417 done 9418 IFS=$as_save_IFS 9419 9420 ;; 9421 esac 9422 fi 9423 MKDIR=$ac_cv_path_MKDIR 9424 if test -n "$MKDIR"; then 9425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9426 $as_echo "$MKDIR" >&6; } 9427 else 9428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9429 $as_echo "no" >&6; } 9430 fi 9431 9432 9433 if test "x$MKDIR" = x; then 9434 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9435 fi 9436 else 9437 # Otherwise we believe it is a complete path. Use it as it is. 9438 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5 9439 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;} 9440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9441 $as_echo_n "checking for MKDIR... " >&6; } 9442 if test ! -x "$tool_specified"; then 9443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9444 $as_echo "not found" >&6; } 9445 as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 9446 fi 9447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9448 $as_echo "$tool_specified" >&6; } 9449 fi 9450 fi 9451 fi 9452 9453 fi 9454 9455 9456 9457 if test "x$MKDIR" = x; then 9458 as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5 9459 fi 9460 9461 9462 9463 9464 9465 # Publish this variable in the help. 9466 9467 9468 if [ -z "${MKTEMP+x}" ]; then 9469 # The variable is not set by user, try to locate tool using the code snippet 9470 for ac_prog in mktemp 9471 do 9472 # Extract the first word of "$ac_prog", so it can be a program name with args. 9473 set dummy $ac_prog; ac_word=$2 9474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9475 $as_echo_n "checking for $ac_word... " >&6; } 9476 if ${ac_cv_path_MKTEMP+:} false; then : 9477 $as_echo_n "(cached) " >&6 9478 else 9479 case $MKTEMP in 9480 [\\/]* | ?:[\\/]*) 9481 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9482 ;; 9483 *) 9484 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9485 for as_dir in $PATH 9486 do 9487 IFS=$as_save_IFS 9488 test -z "$as_dir" && as_dir=. 9489 for ac_exec_ext in '' $ac_executable_extensions; do 9490 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9491 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9492 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9493 break 2 9494 fi 9495 done 9496 done 9497 IFS=$as_save_IFS 9498 9499 ;; 9500 esac 9501 fi 9502 MKTEMP=$ac_cv_path_MKTEMP 9503 if test -n "$MKTEMP"; then 9504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9505 $as_echo "$MKTEMP" >&6; } 9506 else 9507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9508 $as_echo "no" >&6; } 9509 fi 9510 9511 9512 test -n "$MKTEMP" && break 9513 done 9514 9515 else 9516 # The variable is set, but is it from the command line or the environment? 9517 9518 # Try to remove the string !MKTEMP! from our list. 9519 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/} 9520 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9521 # If it failed, the variable was not from the command line. Ignore it, 9522 # but warn the user (except for BASH, which is always set by the calling BASH). 9523 if test "xMKTEMP" != xBASH; then 9524 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5 9525 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;} 9526 fi 9527 # Try to locate tool using the code snippet 9528 for ac_prog in mktemp 9529 do 9530 # Extract the first word of "$ac_prog", so it can be a program name with args. 9531 set dummy $ac_prog; ac_word=$2 9532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9533 $as_echo_n "checking for $ac_word... " >&6; } 9534 if ${ac_cv_path_MKTEMP+:} false; then : 9535 $as_echo_n "(cached) " >&6 9536 else 9537 case $MKTEMP in 9538 [\\/]* | ?:[\\/]*) 9539 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9540 ;; 9541 *) 9542 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9543 for as_dir in $PATH 9544 do 9545 IFS=$as_save_IFS 9546 test -z "$as_dir" && as_dir=. 9547 for ac_exec_ext in '' $ac_executable_extensions; do 9548 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9549 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9550 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9551 break 2 9552 fi 9553 done 9554 done 9555 IFS=$as_save_IFS 9556 9557 ;; 9558 esac 9559 fi 9560 MKTEMP=$ac_cv_path_MKTEMP 9561 if test -n "$MKTEMP"; then 9562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9563 $as_echo "$MKTEMP" >&6; } 9564 else 9565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9566 $as_echo "no" >&6; } 9567 fi 9568 9569 9570 test -n "$MKTEMP" && break 9571 done 9572 9573 else 9574 # If it succeeded, then it was overridden by the user. We will use it 9575 # for the tool. 9576 9577 # First remove it from the list of overridden variables, so we can test 9578 # for unknown variables in the end. 9579 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9580 9581 # Check if we try to supply an empty value 9582 if test "x$MKTEMP" = x; then 9583 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKTEMP= (no value)" >&5 9584 $as_echo "$as_me: Setting user supplied tool MKTEMP= (no value)" >&6;} 9585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9586 $as_echo_n "checking for MKTEMP... " >&6; } 9587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9588 $as_echo "disabled" >&6; } 9589 else 9590 # Check if the provided tool contains a complete path. 9591 tool_specified="$MKTEMP" 9592 tool_basename="${tool_specified##*/}" 9593 if test "x$tool_basename" = "x$tool_specified"; then 9594 # A command without a complete path is provided, search $PATH. 9595 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5 9596 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;} 9597 # Extract the first word of "$tool_basename", so it can be a program name with args. 9598 set dummy $tool_basename; ac_word=$2 9599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9600 $as_echo_n "checking for $ac_word... " >&6; } 9601 if ${ac_cv_path_MKTEMP+:} false; then : 9602 $as_echo_n "(cached) " >&6 9603 else 9604 case $MKTEMP in 9605 [\\/]* | ?:[\\/]*) 9606 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9607 ;; 9608 *) 9609 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9610 for as_dir in $PATH 9611 do 9612 IFS=$as_save_IFS 9613 test -z "$as_dir" && as_dir=. 9614 for ac_exec_ext in '' $ac_executable_extensions; do 9615 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9616 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9617 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9618 break 2 9619 fi 9620 done 9621 done 9622 IFS=$as_save_IFS 9623 9624 ;; 9625 esac 9626 fi 9627 MKTEMP=$ac_cv_path_MKTEMP 9628 if test -n "$MKTEMP"; then 9629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9630 $as_echo "$MKTEMP" >&6; } 9631 else 9632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9633 $as_echo "no" >&6; } 9634 fi 9635 9636 9637 if test "x$MKTEMP" = x; then 9638 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9639 fi 9640 else 9641 # Otherwise we believe it is a complete path. Use it as it is. 9642 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5 9643 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;} 9644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9645 $as_echo_n "checking for MKTEMP... " >&6; } 9646 if test ! -x "$tool_specified"; then 9647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9648 $as_echo "not found" >&6; } 9649 as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5 9650 fi 9651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9652 $as_echo "$tool_specified" >&6; } 9653 fi 9654 fi 9655 fi 9656 9657 fi 9658 9659 9660 9661 if test "x$MKTEMP" = x; then 9662 as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5 9663 fi 9664 9665 9666 9667 9668 9669 # Publish this variable in the help. 9670 9671 9672 if [ -z "${MV+x}" ]; then 9673 # The variable is not set by user, try to locate tool using the code snippet 9674 for ac_prog in mv 9675 do 9676 # Extract the first word of "$ac_prog", so it can be a program name with args. 9677 set dummy $ac_prog; ac_word=$2 9678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9679 $as_echo_n "checking for $ac_word... " >&6; } 9680 if ${ac_cv_path_MV+:} false; then : 9681 $as_echo_n "(cached) " >&6 9682 else 9683 case $MV in 9684 [\\/]* | ?:[\\/]*) 9685 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9686 ;; 9687 *) 9688 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9689 for as_dir in $PATH 9690 do 9691 IFS=$as_save_IFS 9692 test -z "$as_dir" && as_dir=. 9693 for ac_exec_ext in '' $ac_executable_extensions; do 9694 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9695 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9696 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9697 break 2 9698 fi 9699 done 9700 done 9701 IFS=$as_save_IFS 9702 9703 ;; 9704 esac 9705 fi 9706 MV=$ac_cv_path_MV 9707 if test -n "$MV"; then 9708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9709 $as_echo "$MV" >&6; } 9710 else 9711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9712 $as_echo "no" >&6; } 9713 fi 9714 9715 9716 test -n "$MV" && break 9717 done 9718 9719 else 9720 # The variable is set, but is it from the command line or the environment? 9721 9722 # Try to remove the string !MV! from our list. 9723 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/} 9724 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9725 # If it failed, the variable was not from the command line. Ignore it, 9726 # but warn the user (except for BASH, which is always set by the calling BASH). 9727 if test "xMV" != xBASH; then 9728 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5 9729 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;} 9730 fi 9731 # Try to locate tool using the code snippet 9732 for ac_prog in mv 9733 do 9734 # Extract the first word of "$ac_prog", so it can be a program name with args. 9735 set dummy $ac_prog; ac_word=$2 9736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9737 $as_echo_n "checking for $ac_word... " >&6; } 9738 if ${ac_cv_path_MV+:} false; then : 9739 $as_echo_n "(cached) " >&6 9740 else 9741 case $MV in 9742 [\\/]* | ?:[\\/]*) 9743 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9744 ;; 9745 *) 9746 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9747 for as_dir in $PATH 9748 do 9749 IFS=$as_save_IFS 9750 test -z "$as_dir" && as_dir=. 9751 for ac_exec_ext in '' $ac_executable_extensions; do 9752 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9753 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9754 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9755 break 2 9756 fi 9757 done 9758 done 9759 IFS=$as_save_IFS 9760 9761 ;; 9762 esac 9763 fi 9764 MV=$ac_cv_path_MV 9765 if test -n "$MV"; then 9766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9767 $as_echo "$MV" >&6; } 9768 else 9769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9770 $as_echo "no" >&6; } 9771 fi 9772 9773 9774 test -n "$MV" && break 9775 done 9776 9777 else 9778 # If it succeeded, then it was overridden by the user. We will use it 9779 # for the tool. 9780 9781 # First remove it from the list of overridden variables, so we can test 9782 # for unknown variables in the end. 9783 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9784 9785 # Check if we try to supply an empty value 9786 if test "x$MV" = x; then 9787 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MV= (no value)" >&5 9788 $as_echo "$as_me: Setting user supplied tool MV= (no value)" >&6;} 9789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9790 $as_echo_n "checking for MV... " >&6; } 9791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9792 $as_echo "disabled" >&6; } 9793 else 9794 # Check if the provided tool contains a complete path. 9795 tool_specified="$MV" 9796 tool_basename="${tool_specified##*/}" 9797 if test "x$tool_basename" = "x$tool_specified"; then 9798 # A command without a complete path is provided, search $PATH. 9799 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5 9800 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;} 9801 # Extract the first word of "$tool_basename", so it can be a program name with args. 9802 set dummy $tool_basename; ac_word=$2 9803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9804 $as_echo_n "checking for $ac_word... " >&6; } 9805 if ${ac_cv_path_MV+:} false; then : 9806 $as_echo_n "(cached) " >&6 9807 else 9808 case $MV in 9809 [\\/]* | ?:[\\/]*) 9810 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9811 ;; 9812 *) 9813 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9814 for as_dir in $PATH 9815 do 9816 IFS=$as_save_IFS 9817 test -z "$as_dir" && as_dir=. 9818 for ac_exec_ext in '' $ac_executable_extensions; do 9819 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9820 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9821 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9822 break 2 9823 fi 9824 done 9825 done 9826 IFS=$as_save_IFS 9827 9828 ;; 9829 esac 9830 fi 9831 MV=$ac_cv_path_MV 9832 if test -n "$MV"; then 9833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9834 $as_echo "$MV" >&6; } 9835 else 9836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9837 $as_echo "no" >&6; } 9838 fi 9839 9840 9841 if test "x$MV" = x; then 9842 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9843 fi 9844 else 9845 # Otherwise we believe it is a complete path. Use it as it is. 9846 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5 9847 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;} 9848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9849 $as_echo_n "checking for MV... " >&6; } 9850 if test ! -x "$tool_specified"; then 9851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9852 $as_echo "not found" >&6; } 9853 as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5 9854 fi 9855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9856 $as_echo "$tool_specified" >&6; } 9857 fi 9858 fi 9859 fi 9860 9861 fi 9862 9863 9864 9865 if test "x$MV" = x; then 9866 as_fn_error $? "Could not find required tool for MV" "$LINENO" 5 9867 fi 9868 9869 9870 9871 9872 9873 # Publish this variable in the help. 9874 9875 9876 if [ -z "${NAWK+x}" ]; then 9877 # The variable is not set by user, try to locate tool using the code snippet 9878 for ac_prog in nawk gawk awk 9879 do 9880 # Extract the first word of "$ac_prog", so it can be a program name with args. 9881 set dummy $ac_prog; ac_word=$2 9882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9883 $as_echo_n "checking for $ac_word... " >&6; } 9884 if ${ac_cv_path_NAWK+:} false; then : 9885 $as_echo_n "(cached) " >&6 9886 else 9887 case $NAWK in 9888 [\\/]* | ?:[\\/]*) 9889 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9890 ;; 9891 *) 9892 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9893 for as_dir in $PATH 9894 do 9895 IFS=$as_save_IFS 9896 test -z "$as_dir" && as_dir=. 9897 for ac_exec_ext in '' $ac_executable_extensions; do 9898 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9899 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9900 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9901 break 2 9902 fi 9903 done 9904 done 9905 IFS=$as_save_IFS 9906 9907 ;; 9908 esac 9909 fi 9910 NAWK=$ac_cv_path_NAWK 9911 if test -n "$NAWK"; then 9912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9913 $as_echo "$NAWK" >&6; } 9914 else 9915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9916 $as_echo "no" >&6; } 9917 fi 9918 9919 9920 test -n "$NAWK" && break 9921 done 9922 9923 else 9924 # The variable is set, but is it from the command line or the environment? 9925 9926 # Try to remove the string !NAWK! from our list. 9927 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/} 9928 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9929 # If it failed, the variable was not from the command line. Ignore it, 9930 # but warn the user (except for BASH, which is always set by the calling BASH). 9931 if test "xNAWK" != xBASH; then 9932 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5 9933 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;} 9934 fi 9935 # Try to locate tool using the code snippet 9936 for ac_prog in nawk gawk awk 9937 do 9938 # Extract the first word of "$ac_prog", so it can be a program name with args. 9939 set dummy $ac_prog; ac_word=$2 9940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9941 $as_echo_n "checking for $ac_word... " >&6; } 9942 if ${ac_cv_path_NAWK+:} false; then : 9943 $as_echo_n "(cached) " >&6 9944 else 9945 case $NAWK in 9946 [\\/]* | ?:[\\/]*) 9947 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9948 ;; 9949 *) 9950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9951 for as_dir in $PATH 9952 do 9953 IFS=$as_save_IFS 9954 test -z "$as_dir" && as_dir=. 9955 for ac_exec_ext in '' $ac_executable_extensions; do 9956 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9957 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9958 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9959 break 2 9960 fi 9961 done 9962 done 9963 IFS=$as_save_IFS 9964 9965 ;; 9966 esac 9967 fi 9968 NAWK=$ac_cv_path_NAWK 9969 if test -n "$NAWK"; then 9970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9971 $as_echo "$NAWK" >&6; } 9972 else 9973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9974 $as_echo "no" >&6; } 9975 fi 9976 9977 9978 test -n "$NAWK" && break 9979 done 9980 9981 else 9982 # If it succeeded, then it was overridden by the user. We will use it 9983 # for the tool. 9984 9985 # First remove it from the list of overridden variables, so we can test 9986 # for unknown variables in the end. 9987 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9988 9989 # Check if we try to supply an empty value 9990 if test "x$NAWK" = x; then 9991 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NAWK= (no value)" >&5 9992 $as_echo "$as_me: Setting user supplied tool NAWK= (no value)" >&6;} 9993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 9994 $as_echo_n "checking for NAWK... " >&6; } 9995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9996 $as_echo "disabled" >&6; } 9997 else 9998 # Check if the provided tool contains a complete path. 9999 tool_specified="$NAWK" 10000 tool_basename="${tool_specified##*/}" 10001 if test "x$tool_basename" = "x$tool_specified"; then 10002 # A command without a complete path is provided, search $PATH. 10003 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5 10004 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;} 10005 # Extract the first word of "$tool_basename", so it can be a program name with args. 10006 set dummy $tool_basename; ac_word=$2 10007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10008 $as_echo_n "checking for $ac_word... " >&6; } 10009 if ${ac_cv_path_NAWK+:} false; then : 10010 $as_echo_n "(cached) " >&6 10011 else 10012 case $NAWK in 10013 [\\/]* | ?:[\\/]*) 10014 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 10015 ;; 10016 *) 10017 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10018 for as_dir in $PATH 10019 do 10020 IFS=$as_save_IFS 10021 test -z "$as_dir" && as_dir=. 10022 for ac_exec_ext in '' $ac_executable_extensions; do 10023 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10024 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 10025 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10026 break 2 10027 fi 10028 done 10029 done 10030 IFS=$as_save_IFS 10031 10032 ;; 10033 esac 10034 fi 10035 NAWK=$ac_cv_path_NAWK 10036 if test -n "$NAWK"; then 10037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 10038 $as_echo "$NAWK" >&6; } 10039 else 10040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10041 $as_echo "no" >&6; } 10042 fi 10043 10044 10045 if test "x$NAWK" = x; then 10046 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10047 fi 10048 else 10049 # Otherwise we believe it is a complete path. Use it as it is. 10050 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5 10051 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;} 10052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 10053 $as_echo_n "checking for NAWK... " >&6; } 10054 if test ! -x "$tool_specified"; then 10055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10056 $as_echo "not found" >&6; } 10057 as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5 10058 fi 10059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10060 $as_echo "$tool_specified" >&6; } 10061 fi 10062 fi 10063 fi 10064 10065 fi 10066 10067 10068 10069 if test "x$NAWK" = x; then 10070 as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5 10071 fi 10072 10073 10074 10075 10076 10077 # Publish this variable in the help. 10078 10079 10080 if [ -z "${PRINTF+x}" ]; then 10081 # The variable is not set by user, try to locate tool using the code snippet 10082 for ac_prog in printf 10083 do 10084 # Extract the first word of "$ac_prog", so it can be a program name with args. 10085 set dummy $ac_prog; ac_word=$2 10086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10087 $as_echo_n "checking for $ac_word... " >&6; } 10088 if ${ac_cv_path_PRINTF+:} false; then : 10089 $as_echo_n "(cached) " >&6 10090 else 10091 case $PRINTF in 10092 [\\/]* | ?:[\\/]*) 10093 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10094 ;; 10095 *) 10096 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10097 for as_dir in $PATH 10098 do 10099 IFS=$as_save_IFS 10100 test -z "$as_dir" && as_dir=. 10101 for ac_exec_ext in '' $ac_executable_extensions; do 10102 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10103 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10104 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10105 break 2 10106 fi 10107 done 10108 done 10109 IFS=$as_save_IFS 10110 10111 ;; 10112 esac 10113 fi 10114 PRINTF=$ac_cv_path_PRINTF 10115 if test -n "$PRINTF"; then 10116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10117 $as_echo "$PRINTF" >&6; } 10118 else 10119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10120 $as_echo "no" >&6; } 10121 fi 10122 10123 10124 test -n "$PRINTF" && break 10125 done 10126 10127 else 10128 # The variable is set, but is it from the command line or the environment? 10129 10130 # Try to remove the string !PRINTF! from our list. 10131 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/} 10132 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10133 # If it failed, the variable was not from the command line. Ignore it, 10134 # but warn the user (except for BASH, which is always set by the calling BASH). 10135 if test "xPRINTF" != xBASH; then 10136 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5 10137 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;} 10138 fi 10139 # Try to locate tool using the code snippet 10140 for ac_prog in printf 10141 do 10142 # Extract the first word of "$ac_prog", so it can be a program name with args. 10143 set dummy $ac_prog; ac_word=$2 10144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10145 $as_echo_n "checking for $ac_word... " >&6; } 10146 if ${ac_cv_path_PRINTF+:} false; then : 10147 $as_echo_n "(cached) " >&6 10148 else 10149 case $PRINTF in 10150 [\\/]* | ?:[\\/]*) 10151 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10152 ;; 10153 *) 10154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10155 for as_dir in $PATH 10156 do 10157 IFS=$as_save_IFS 10158 test -z "$as_dir" && as_dir=. 10159 for ac_exec_ext in '' $ac_executable_extensions; do 10160 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10161 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10162 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10163 break 2 10164 fi 10165 done 10166 done 10167 IFS=$as_save_IFS 10168 10169 ;; 10170 esac 10171 fi 10172 PRINTF=$ac_cv_path_PRINTF 10173 if test -n "$PRINTF"; then 10174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10175 $as_echo "$PRINTF" >&6; } 10176 else 10177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10178 $as_echo "no" >&6; } 10179 fi 10180 10181 10182 test -n "$PRINTF" && break 10183 done 10184 10185 else 10186 # If it succeeded, then it was overridden by the user. We will use it 10187 # for the tool. 10188 10189 # First remove it from the list of overridden variables, so we can test 10190 # for unknown variables in the end. 10191 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10192 10193 # Check if we try to supply an empty value 10194 if test "x$PRINTF" = x; then 10195 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PRINTF= (no value)" >&5 10196 $as_echo "$as_me: Setting user supplied tool PRINTF= (no value)" >&6;} 10197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10198 $as_echo_n "checking for PRINTF... " >&6; } 10199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10200 $as_echo "disabled" >&6; } 10201 else 10202 # Check if the provided tool contains a complete path. 10203 tool_specified="$PRINTF" 10204 tool_basename="${tool_specified##*/}" 10205 if test "x$tool_basename" = "x$tool_specified"; then 10206 # A command without a complete path is provided, search $PATH. 10207 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5 10208 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;} 10209 # Extract the first word of "$tool_basename", so it can be a program name with args. 10210 set dummy $tool_basename; ac_word=$2 10211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10212 $as_echo_n "checking for $ac_word... " >&6; } 10213 if ${ac_cv_path_PRINTF+:} false; then : 10214 $as_echo_n "(cached) " >&6 10215 else 10216 case $PRINTF in 10217 [\\/]* | ?:[\\/]*) 10218 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10219 ;; 10220 *) 10221 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10222 for as_dir in $PATH 10223 do 10224 IFS=$as_save_IFS 10225 test -z "$as_dir" && as_dir=. 10226 for ac_exec_ext in '' $ac_executable_extensions; do 10227 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10228 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10229 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10230 break 2 10231 fi 10232 done 10233 done 10234 IFS=$as_save_IFS 10235 10236 ;; 10237 esac 10238 fi 10239 PRINTF=$ac_cv_path_PRINTF 10240 if test -n "$PRINTF"; then 10241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10242 $as_echo "$PRINTF" >&6; } 10243 else 10244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10245 $as_echo "no" >&6; } 10246 fi 10247 10248 10249 if test "x$PRINTF" = x; then 10250 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10251 fi 10252 else 10253 # Otherwise we believe it is a complete path. Use it as it is. 10254 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5 10255 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;} 10256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10257 $as_echo_n "checking for PRINTF... " >&6; } 10258 if test ! -x "$tool_specified"; then 10259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10260 $as_echo "not found" >&6; } 10261 as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5 10262 fi 10263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10264 $as_echo "$tool_specified" >&6; } 10265 fi 10266 fi 10267 fi 10268 10269 fi 10270 10271 10272 10273 if test "x$PRINTF" = x; then 10274 as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5 10275 fi 10276 10277 10278 10279 10280 10281 # Publish this variable in the help. 10282 10283 10284 if [ -z "${RM+x}" ]; then 10285 # The variable is not set by user, try to locate tool using the code snippet 10286 for ac_prog in rm 10287 do 10288 # Extract the first word of "$ac_prog", so it can be a program name with args. 10289 set dummy $ac_prog; ac_word=$2 10290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10291 $as_echo_n "checking for $ac_word... " >&6; } 10292 if ${ac_cv_path_RM+:} false; then : 10293 $as_echo_n "(cached) " >&6 10294 else 10295 case $RM in 10296 [\\/]* | ?:[\\/]*) 10297 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10298 ;; 10299 *) 10300 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10301 for as_dir in $PATH 10302 do 10303 IFS=$as_save_IFS 10304 test -z "$as_dir" && as_dir=. 10305 for ac_exec_ext in '' $ac_executable_extensions; do 10306 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10307 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10308 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10309 break 2 10310 fi 10311 done 10312 done 10313 IFS=$as_save_IFS 10314 10315 ;; 10316 esac 10317 fi 10318 RM=$ac_cv_path_RM 10319 if test -n "$RM"; then 10320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10321 $as_echo "$RM" >&6; } 10322 else 10323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10324 $as_echo "no" >&6; } 10325 fi 10326 10327 10328 test -n "$RM" && break 10329 done 10330 10331 else 10332 # The variable is set, but is it from the command line or the environment? 10333 10334 # Try to remove the string !RM! from our list. 10335 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/} 10336 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10337 # If it failed, the variable was not from the command line. Ignore it, 10338 # but warn the user (except for BASH, which is always set by the calling BASH). 10339 if test "xRM" != xBASH; then 10340 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5 10341 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;} 10342 fi 10343 # Try to locate tool using the code snippet 10344 for ac_prog in rm 10345 do 10346 # Extract the first word of "$ac_prog", so it can be a program name with args. 10347 set dummy $ac_prog; ac_word=$2 10348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10349 $as_echo_n "checking for $ac_word... " >&6; } 10350 if ${ac_cv_path_RM+:} false; then : 10351 $as_echo_n "(cached) " >&6 10352 else 10353 case $RM in 10354 [\\/]* | ?:[\\/]*) 10355 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10356 ;; 10357 *) 10358 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10359 for as_dir in $PATH 10360 do 10361 IFS=$as_save_IFS 10362 test -z "$as_dir" && as_dir=. 10363 for ac_exec_ext in '' $ac_executable_extensions; do 10364 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10365 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10366 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10367 break 2 10368 fi 10369 done 10370 done 10371 IFS=$as_save_IFS 10372 10373 ;; 10374 esac 10375 fi 10376 RM=$ac_cv_path_RM 10377 if test -n "$RM"; then 10378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10379 $as_echo "$RM" >&6; } 10380 else 10381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10382 $as_echo "no" >&6; } 10383 fi 10384 10385 10386 test -n "$RM" && break 10387 done 10388 10389 else 10390 # If it succeeded, then it was overridden by the user. We will use it 10391 # for the tool. 10392 10393 # First remove it from the list of overridden variables, so we can test 10394 # for unknown variables in the end. 10395 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10396 10397 # Check if we try to supply an empty value 10398 if test "x$RM" = x; then 10399 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RM= (no value)" >&5 10400 $as_echo "$as_me: Setting user supplied tool RM= (no value)" >&6;} 10401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10402 $as_echo_n "checking for RM... " >&6; } 10403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10404 $as_echo "disabled" >&6; } 10405 else 10406 # Check if the provided tool contains a complete path. 10407 tool_specified="$RM" 10408 tool_basename="${tool_specified##*/}" 10409 if test "x$tool_basename" = "x$tool_specified"; then 10410 # A command without a complete path is provided, search $PATH. 10411 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5 10412 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;} 10413 # Extract the first word of "$tool_basename", so it can be a program name with args. 10414 set dummy $tool_basename; ac_word=$2 10415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10416 $as_echo_n "checking for $ac_word... " >&6; } 10417 if ${ac_cv_path_RM+:} false; then : 10418 $as_echo_n "(cached) " >&6 10419 else 10420 case $RM in 10421 [\\/]* | ?:[\\/]*) 10422 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10423 ;; 10424 *) 10425 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10426 for as_dir in $PATH 10427 do 10428 IFS=$as_save_IFS 10429 test -z "$as_dir" && as_dir=. 10430 for ac_exec_ext in '' $ac_executable_extensions; do 10431 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10432 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10433 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10434 break 2 10435 fi 10436 done 10437 done 10438 IFS=$as_save_IFS 10439 10440 ;; 10441 esac 10442 fi 10443 RM=$ac_cv_path_RM 10444 if test -n "$RM"; then 10445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10446 $as_echo "$RM" >&6; } 10447 else 10448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10449 $as_echo "no" >&6; } 10450 fi 10451 10452 10453 if test "x$RM" = x; then 10454 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10455 fi 10456 else 10457 # Otherwise we believe it is a complete path. Use it as it is. 10458 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5 10459 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;} 10460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10461 $as_echo_n "checking for RM... " >&6; } 10462 if test ! -x "$tool_specified"; then 10463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10464 $as_echo "not found" >&6; } 10465 as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5 10466 fi 10467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10468 $as_echo "$tool_specified" >&6; } 10469 fi 10470 fi 10471 fi 10472 10473 fi 10474 10475 10476 10477 if test "x$RM" = x; then 10478 as_fn_error $? "Could not find required tool for RM" "$LINENO" 5 10479 fi 10480 10481 10482 10483 10484 10485 # Publish this variable in the help. 10486 10487 10488 if [ -z "${RMDIR+x}" ]; then 10489 # The variable is not set by user, try to locate tool using the code snippet 10490 for ac_prog in rmdir 10491 do 10492 # Extract the first word of "$ac_prog", so it can be a program name with args. 10493 set dummy $ac_prog; ac_word=$2 10494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10495 $as_echo_n "checking for $ac_word... " >&6; } 10496 if ${ac_cv_path_RMDIR+:} false; then : 10497 $as_echo_n "(cached) " >&6 10498 else 10499 case $RMDIR in 10500 [\\/]* | ?:[\\/]*) 10501 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10502 ;; 10503 *) 10504 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10505 for as_dir in $PATH 10506 do 10507 IFS=$as_save_IFS 10508 test -z "$as_dir" && as_dir=. 10509 for ac_exec_ext in '' $ac_executable_extensions; do 10510 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10511 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10512 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10513 break 2 10514 fi 10515 done 10516 done 10517 IFS=$as_save_IFS 10518 10519 ;; 10520 esac 10521 fi 10522 RMDIR=$ac_cv_path_RMDIR 10523 if test -n "$RMDIR"; then 10524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10525 $as_echo "$RMDIR" >&6; } 10526 else 10527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10528 $as_echo "no" >&6; } 10529 fi 10530 10531 10532 test -n "$RMDIR" && break 10533 done 10534 10535 else 10536 # The variable is set, but is it from the command line or the environment? 10537 10538 # Try to remove the string !RMDIR! from our list. 10539 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RMDIR!/} 10540 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10541 # If it failed, the variable was not from the command line. Ignore it, 10542 # but warn the user (except for BASH, which is always set by the calling BASH). 10543 if test "xRMDIR" != xBASH; then 10544 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&5 10545 $as_echo "$as_me: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&2;} 10546 fi 10547 # Try to locate tool using the code snippet 10548 for ac_prog in rmdir 10549 do 10550 # Extract the first word of "$ac_prog", so it can be a program name with args. 10551 set dummy $ac_prog; ac_word=$2 10552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10553 $as_echo_n "checking for $ac_word... " >&6; } 10554 if ${ac_cv_path_RMDIR+:} false; then : 10555 $as_echo_n "(cached) " >&6 10556 else 10557 case $RMDIR in 10558 [\\/]* | ?:[\\/]*) 10559 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10560 ;; 10561 *) 10562 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10563 for as_dir in $PATH 10564 do 10565 IFS=$as_save_IFS 10566 test -z "$as_dir" && as_dir=. 10567 for ac_exec_ext in '' $ac_executable_extensions; do 10568 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10569 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10570 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10571 break 2 10572 fi 10573 done 10574 done 10575 IFS=$as_save_IFS 10576 10577 ;; 10578 esac 10579 fi 10580 RMDIR=$ac_cv_path_RMDIR 10581 if test -n "$RMDIR"; then 10582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10583 $as_echo "$RMDIR" >&6; } 10584 else 10585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10586 $as_echo "no" >&6; } 10587 fi 10588 10589 10590 test -n "$RMDIR" && break 10591 done 10592 10593 else 10594 # If it succeeded, then it was overridden by the user. We will use it 10595 # for the tool. 10596 10597 # First remove it from the list of overridden variables, so we can test 10598 # for unknown variables in the end. 10599 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10600 10601 # Check if we try to supply an empty value 10602 if test "x$RMDIR" = x; then 10603 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RMDIR= (no value)" >&5 10604 $as_echo "$as_me: Setting user supplied tool RMDIR= (no value)" >&6;} 10605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10606 $as_echo_n "checking for RMDIR... " >&6; } 10607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10608 $as_echo "disabled" >&6; } 10609 else 10610 # Check if the provided tool contains a complete path. 10611 tool_specified="$RMDIR" 10612 tool_basename="${tool_specified##*/}" 10613 if test "x$tool_basename" = "x$tool_specified"; then 10614 # A command without a complete path is provided, search $PATH. 10615 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RMDIR=$tool_basename" >&5 10616 $as_echo "$as_me: Will search for user supplied tool RMDIR=$tool_basename" >&6;} 10617 # Extract the first word of "$tool_basename", so it can be a program name with args. 10618 set dummy $tool_basename; ac_word=$2 10619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10620 $as_echo_n "checking for $ac_word... " >&6; } 10621 if ${ac_cv_path_RMDIR+:} false; then : 10622 $as_echo_n "(cached) " >&6 10623 else 10624 case $RMDIR in 10625 [\\/]* | ?:[\\/]*) 10626 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10627 ;; 10628 *) 10629 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10630 for as_dir in $PATH 10631 do 10632 IFS=$as_save_IFS 10633 test -z "$as_dir" && as_dir=. 10634 for ac_exec_ext in '' $ac_executable_extensions; do 10635 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10636 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10637 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10638 break 2 10639 fi 10640 done 10641 done 10642 IFS=$as_save_IFS 10643 10644 ;; 10645 esac 10646 fi 10647 RMDIR=$ac_cv_path_RMDIR 10648 if test -n "$RMDIR"; then 10649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10650 $as_echo "$RMDIR" >&6; } 10651 else 10652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10653 $as_echo "no" >&6; } 10654 fi 10655 10656 10657 if test "x$RMDIR" = x; then 10658 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10659 fi 10660 else 10661 # Otherwise we believe it is a complete path. Use it as it is. 10662 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RMDIR=$tool_specified" >&5 10663 $as_echo "$as_me: Will use user supplied tool RMDIR=$tool_specified" >&6;} 10664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10665 $as_echo_n "checking for RMDIR... " >&6; } 10666 if test ! -x "$tool_specified"; then 10667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10668 $as_echo "not found" >&6; } 10669 as_fn_error $? "User supplied tool RMDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 10670 fi 10671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10672 $as_echo "$tool_specified" >&6; } 10673 fi 10674 fi 10675 fi 10676 10677 fi 10678 10679 10680 10681 if test "x$RMDIR" = x; then 10682 as_fn_error $? "Could not find required tool for RMDIR" "$LINENO" 5 10683 fi 10684 10685 10686 10687 10688 10689 # Publish this variable in the help. 10690 10691 10692 if [ -z "${SH+x}" ]; then 10693 # The variable is not set by user, try to locate tool using the code snippet 10694 for ac_prog in sh 10695 do 10696 # Extract the first word of "$ac_prog", so it can be a program name with args. 10697 set dummy $ac_prog; ac_word=$2 10698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10699 $as_echo_n "checking for $ac_word... " >&6; } 10700 if ${ac_cv_path_SH+:} false; then : 10701 $as_echo_n "(cached) " >&6 10702 else 10703 case $SH in 10704 [\\/]* | ?:[\\/]*) 10705 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10706 ;; 10707 *) 10708 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10709 for as_dir in $PATH 10710 do 10711 IFS=$as_save_IFS 10712 test -z "$as_dir" && as_dir=. 10713 for ac_exec_ext in '' $ac_executable_extensions; do 10714 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10715 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10716 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10717 break 2 10718 fi 10719 done 10720 done 10721 IFS=$as_save_IFS 10722 10723 ;; 10724 esac 10725 fi 10726 SH=$ac_cv_path_SH 10727 if test -n "$SH"; then 10728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10729 $as_echo "$SH" >&6; } 10730 else 10731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10732 $as_echo "no" >&6; } 10733 fi 10734 10735 10736 test -n "$SH" && break 10737 done 10738 10739 else 10740 # The variable is set, but is it from the command line or the environment? 10741 10742 # Try to remove the string !SH! from our list. 10743 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/} 10744 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10745 # If it failed, the variable was not from the command line. Ignore it, 10746 # but warn the user (except for BASH, which is always set by the calling BASH). 10747 if test "xSH" != xBASH; then 10748 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5 10749 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;} 10750 fi 10751 # Try to locate tool using the code snippet 10752 for ac_prog in sh 10753 do 10754 # Extract the first word of "$ac_prog", so it can be a program name with args. 10755 set dummy $ac_prog; ac_word=$2 10756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10757 $as_echo_n "checking for $ac_word... " >&6; } 10758 if ${ac_cv_path_SH+:} false; then : 10759 $as_echo_n "(cached) " >&6 10760 else 10761 case $SH in 10762 [\\/]* | ?:[\\/]*) 10763 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10764 ;; 10765 *) 10766 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10767 for as_dir in $PATH 10768 do 10769 IFS=$as_save_IFS 10770 test -z "$as_dir" && as_dir=. 10771 for ac_exec_ext in '' $ac_executable_extensions; do 10772 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10773 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10774 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10775 break 2 10776 fi 10777 done 10778 done 10779 IFS=$as_save_IFS 10780 10781 ;; 10782 esac 10783 fi 10784 SH=$ac_cv_path_SH 10785 if test -n "$SH"; then 10786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10787 $as_echo "$SH" >&6; } 10788 else 10789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10790 $as_echo "no" >&6; } 10791 fi 10792 10793 10794 test -n "$SH" && break 10795 done 10796 10797 else 10798 # If it succeeded, then it was overridden by the user. We will use it 10799 # for the tool. 10800 10801 # First remove it from the list of overridden variables, so we can test 10802 # for unknown variables in the end. 10803 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10804 10805 # Check if we try to supply an empty value 10806 if test "x$SH" = x; then 10807 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SH= (no value)" >&5 10808 $as_echo "$as_me: Setting user supplied tool SH= (no value)" >&6;} 10809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10810 $as_echo_n "checking for SH... " >&6; } 10811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10812 $as_echo "disabled" >&6; } 10813 else 10814 # Check if the provided tool contains a complete path. 10815 tool_specified="$SH" 10816 tool_basename="${tool_specified##*/}" 10817 if test "x$tool_basename" = "x$tool_specified"; then 10818 # A command without a complete path is provided, search $PATH. 10819 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5 10820 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;} 10821 # Extract the first word of "$tool_basename", so it can be a program name with args. 10822 set dummy $tool_basename; ac_word=$2 10823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10824 $as_echo_n "checking for $ac_word... " >&6; } 10825 if ${ac_cv_path_SH+:} false; then : 10826 $as_echo_n "(cached) " >&6 10827 else 10828 case $SH in 10829 [\\/]* | ?:[\\/]*) 10830 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10831 ;; 10832 *) 10833 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10834 for as_dir in $PATH 10835 do 10836 IFS=$as_save_IFS 10837 test -z "$as_dir" && as_dir=. 10838 for ac_exec_ext in '' $ac_executable_extensions; do 10839 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10840 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10841 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10842 break 2 10843 fi 10844 done 10845 done 10846 IFS=$as_save_IFS 10847 10848 ;; 10849 esac 10850 fi 10851 SH=$ac_cv_path_SH 10852 if test -n "$SH"; then 10853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10854 $as_echo "$SH" >&6; } 10855 else 10856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10857 $as_echo "no" >&6; } 10858 fi 10859 10860 10861 if test "x$SH" = x; then 10862 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10863 fi 10864 else 10865 # Otherwise we believe it is a complete path. Use it as it is. 10866 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5 10867 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;} 10868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10869 $as_echo_n "checking for SH... " >&6; } 10870 if test ! -x "$tool_specified"; then 10871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10872 $as_echo "not found" >&6; } 10873 as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5 10874 fi 10875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10876 $as_echo "$tool_specified" >&6; } 10877 fi 10878 fi 10879 fi 10880 10881 fi 10882 10883 10884 10885 if test "x$SH" = x; then 10886 as_fn_error $? "Could not find required tool for SH" "$LINENO" 5 10887 fi 10888 10889 10890 10891 10892 10893 # Publish this variable in the help. 10894 10895 10896 if [ -z "${SORT+x}" ]; then 10897 # The variable is not set by user, try to locate tool using the code snippet 10898 for ac_prog in sort 10899 do 10900 # Extract the first word of "$ac_prog", so it can be a program name with args. 10901 set dummy $ac_prog; ac_word=$2 10902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10903 $as_echo_n "checking for $ac_word... " >&6; } 10904 if ${ac_cv_path_SORT+:} false; then : 10905 $as_echo_n "(cached) " >&6 10906 else 10907 case $SORT in 10908 [\\/]* | ?:[\\/]*) 10909 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10910 ;; 10911 *) 10912 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10913 for as_dir in $PATH 10914 do 10915 IFS=$as_save_IFS 10916 test -z "$as_dir" && as_dir=. 10917 for ac_exec_ext in '' $ac_executable_extensions; do 10918 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10919 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10920 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10921 break 2 10922 fi 10923 done 10924 done 10925 IFS=$as_save_IFS 10926 10927 ;; 10928 esac 10929 fi 10930 SORT=$ac_cv_path_SORT 10931 if test -n "$SORT"; then 10932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10933 $as_echo "$SORT" >&6; } 10934 else 10935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10936 $as_echo "no" >&6; } 10937 fi 10938 10939 10940 test -n "$SORT" && break 10941 done 10942 10943 else 10944 # The variable is set, but is it from the command line or the environment? 10945 10946 # Try to remove the string !SORT! from our list. 10947 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/} 10948 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10949 # If it failed, the variable was not from the command line. Ignore it, 10950 # but warn the user (except for BASH, which is always set by the calling BASH). 10951 if test "xSORT" != xBASH; then 10952 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5 10953 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;} 10954 fi 10955 # Try to locate tool using the code snippet 10956 for ac_prog in sort 10957 do 10958 # Extract the first word of "$ac_prog", so it can be a program name with args. 10959 set dummy $ac_prog; ac_word=$2 10960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10961 $as_echo_n "checking for $ac_word... " >&6; } 10962 if ${ac_cv_path_SORT+:} false; then : 10963 $as_echo_n "(cached) " >&6 10964 else 10965 case $SORT in 10966 [\\/]* | ?:[\\/]*) 10967 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10968 ;; 10969 *) 10970 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10971 for as_dir in $PATH 10972 do 10973 IFS=$as_save_IFS 10974 test -z "$as_dir" && as_dir=. 10975 for ac_exec_ext in '' $ac_executable_extensions; do 10976 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10977 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10978 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10979 break 2 10980 fi 10981 done 10982 done 10983 IFS=$as_save_IFS 10984 10985 ;; 10986 esac 10987 fi 10988 SORT=$ac_cv_path_SORT 10989 if test -n "$SORT"; then 10990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10991 $as_echo "$SORT" >&6; } 10992 else 10993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10994 $as_echo "no" >&6; } 10995 fi 10996 10997 10998 test -n "$SORT" && break 10999 done 11000 11001 else 11002 # If it succeeded, then it was overridden by the user. We will use it 11003 # for the tool. 11004 11005 # First remove it from the list of overridden variables, so we can test 11006 # for unknown variables in the end. 11007 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11008 11009 # Check if we try to supply an empty value 11010 if test "x$SORT" = x; then 11011 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SORT= (no value)" >&5 11012 $as_echo "$as_me: Setting user supplied tool SORT= (no value)" >&6;} 11013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11014 $as_echo_n "checking for SORT... " >&6; } 11015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11016 $as_echo "disabled" >&6; } 11017 else 11018 # Check if the provided tool contains a complete path. 11019 tool_specified="$SORT" 11020 tool_basename="${tool_specified##*/}" 11021 if test "x$tool_basename" = "x$tool_specified"; then 11022 # A command without a complete path is provided, search $PATH. 11023 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5 11024 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;} 11025 # Extract the first word of "$tool_basename", so it can be a program name with args. 11026 set dummy $tool_basename; ac_word=$2 11027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11028 $as_echo_n "checking for $ac_word... " >&6; } 11029 if ${ac_cv_path_SORT+:} false; then : 11030 $as_echo_n "(cached) " >&6 11031 else 11032 case $SORT in 11033 [\\/]* | ?:[\\/]*) 11034 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 11035 ;; 11036 *) 11037 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11038 for as_dir in $PATH 11039 do 11040 IFS=$as_save_IFS 11041 test -z "$as_dir" && as_dir=. 11042 for ac_exec_ext in '' $ac_executable_extensions; do 11043 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11044 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 11045 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11046 break 2 11047 fi 11048 done 11049 done 11050 IFS=$as_save_IFS 11051 11052 ;; 11053 esac 11054 fi 11055 SORT=$ac_cv_path_SORT 11056 if test -n "$SORT"; then 11057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 11058 $as_echo "$SORT" >&6; } 11059 else 11060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11061 $as_echo "no" >&6; } 11062 fi 11063 11064 11065 if test "x$SORT" = x; then 11066 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11067 fi 11068 else 11069 # Otherwise we believe it is a complete path. Use it as it is. 11070 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5 11071 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;} 11072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11073 $as_echo_n "checking for SORT... " >&6; } 11074 if test ! -x "$tool_specified"; then 11075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11076 $as_echo "not found" >&6; } 11077 as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5 11078 fi 11079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11080 $as_echo "$tool_specified" >&6; } 11081 fi 11082 fi 11083 fi 11084 11085 fi 11086 11087 11088 11089 if test "x$SORT" = x; then 11090 as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5 11091 fi 11092 11093 11094 11095 11096 11097 # Publish this variable in the help. 11098 11099 11100 if [ -z "${TAIL+x}" ]; then 11101 # The variable is not set by user, try to locate tool using the code snippet 11102 for ac_prog in tail 11103 do 11104 # Extract the first word of "$ac_prog", so it can be a program name with args. 11105 set dummy $ac_prog; ac_word=$2 11106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11107 $as_echo_n "checking for $ac_word... " >&6; } 11108 if ${ac_cv_path_TAIL+:} false; then : 11109 $as_echo_n "(cached) " >&6 11110 else 11111 case $TAIL in 11112 [\\/]* | ?:[\\/]*) 11113 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11114 ;; 11115 *) 11116 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11117 for as_dir in $PATH 11118 do 11119 IFS=$as_save_IFS 11120 test -z "$as_dir" && as_dir=. 11121 for ac_exec_ext in '' $ac_executable_extensions; do 11122 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11123 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11124 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11125 break 2 11126 fi 11127 done 11128 done 11129 IFS=$as_save_IFS 11130 11131 ;; 11132 esac 11133 fi 11134 TAIL=$ac_cv_path_TAIL 11135 if test -n "$TAIL"; then 11136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11137 $as_echo "$TAIL" >&6; } 11138 else 11139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11140 $as_echo "no" >&6; } 11141 fi 11142 11143 11144 test -n "$TAIL" && break 11145 done 11146 11147 else 11148 # The variable is set, but is it from the command line or the environment? 11149 11150 # Try to remove the string !TAIL! from our list. 11151 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/} 11152 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11153 # If it failed, the variable was not from the command line. Ignore it, 11154 # but warn the user (except for BASH, which is always set by the calling BASH). 11155 if test "xTAIL" != xBASH; then 11156 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5 11157 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;} 11158 fi 11159 # Try to locate tool using the code snippet 11160 for ac_prog in tail 11161 do 11162 # Extract the first word of "$ac_prog", so it can be a program name with args. 11163 set dummy $ac_prog; ac_word=$2 11164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11165 $as_echo_n "checking for $ac_word... " >&6; } 11166 if ${ac_cv_path_TAIL+:} false; then : 11167 $as_echo_n "(cached) " >&6 11168 else 11169 case $TAIL in 11170 [\\/]* | ?:[\\/]*) 11171 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11172 ;; 11173 *) 11174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11175 for as_dir in $PATH 11176 do 11177 IFS=$as_save_IFS 11178 test -z "$as_dir" && as_dir=. 11179 for ac_exec_ext in '' $ac_executable_extensions; do 11180 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11181 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11182 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11183 break 2 11184 fi 11185 done 11186 done 11187 IFS=$as_save_IFS 11188 11189 ;; 11190 esac 11191 fi 11192 TAIL=$ac_cv_path_TAIL 11193 if test -n "$TAIL"; then 11194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11195 $as_echo "$TAIL" >&6; } 11196 else 11197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11198 $as_echo "no" >&6; } 11199 fi 11200 11201 11202 test -n "$TAIL" && break 11203 done 11204 11205 else 11206 # If it succeeded, then it was overridden by the user. We will use it 11207 # for the tool. 11208 11209 # First remove it from the list of overridden variables, so we can test 11210 # for unknown variables in the end. 11211 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11212 11213 # Check if we try to supply an empty value 11214 if test "x$TAIL" = x; then 11215 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAIL= (no value)" >&5 11216 $as_echo "$as_me: Setting user supplied tool TAIL= (no value)" >&6;} 11217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11218 $as_echo_n "checking for TAIL... " >&6; } 11219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11220 $as_echo "disabled" >&6; } 11221 else 11222 # Check if the provided tool contains a complete path. 11223 tool_specified="$TAIL" 11224 tool_basename="${tool_specified##*/}" 11225 if test "x$tool_basename" = "x$tool_specified"; then 11226 # A command without a complete path is provided, search $PATH. 11227 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5 11228 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;} 11229 # Extract the first word of "$tool_basename", so it can be a program name with args. 11230 set dummy $tool_basename; ac_word=$2 11231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11232 $as_echo_n "checking for $ac_word... " >&6; } 11233 if ${ac_cv_path_TAIL+:} false; then : 11234 $as_echo_n "(cached) " >&6 11235 else 11236 case $TAIL in 11237 [\\/]* | ?:[\\/]*) 11238 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11239 ;; 11240 *) 11241 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11242 for as_dir in $PATH 11243 do 11244 IFS=$as_save_IFS 11245 test -z "$as_dir" && as_dir=. 11246 for ac_exec_ext in '' $ac_executable_extensions; do 11247 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11248 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11249 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11250 break 2 11251 fi 11252 done 11253 done 11254 IFS=$as_save_IFS 11255 11256 ;; 11257 esac 11258 fi 11259 TAIL=$ac_cv_path_TAIL 11260 if test -n "$TAIL"; then 11261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11262 $as_echo "$TAIL" >&6; } 11263 else 11264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11265 $as_echo "no" >&6; } 11266 fi 11267 11268 11269 if test "x$TAIL" = x; then 11270 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11271 fi 11272 else 11273 # Otherwise we believe it is a complete path. Use it as it is. 11274 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5 11275 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;} 11276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11277 $as_echo_n "checking for TAIL... " >&6; } 11278 if test ! -x "$tool_specified"; then 11279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11280 $as_echo "not found" >&6; } 11281 as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5 11282 fi 11283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11284 $as_echo "$tool_specified" >&6; } 11285 fi 11286 fi 11287 fi 11288 11289 fi 11290 11291 11292 11293 if test "x$TAIL" = x; then 11294 as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5 11295 fi 11296 11297 11298 11299 11300 11301 # Publish this variable in the help. 11302 11303 11304 if [ -z "${TAR+x}" ]; then 11305 # The variable is not set by user, try to locate tool using the code snippet 11306 for ac_prog in gtar tar 11307 do 11308 # Extract the first word of "$ac_prog", so it can be a program name with args. 11309 set dummy $ac_prog; ac_word=$2 11310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11311 $as_echo_n "checking for $ac_word... " >&6; } 11312 if ${ac_cv_path_TAR+:} false; then : 11313 $as_echo_n "(cached) " >&6 11314 else 11315 case $TAR in 11316 [\\/]* | ?:[\\/]*) 11317 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11318 ;; 11319 *) 11320 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11321 for as_dir in $PATH 11322 do 11323 IFS=$as_save_IFS 11324 test -z "$as_dir" && as_dir=. 11325 for ac_exec_ext in '' $ac_executable_extensions; do 11326 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11327 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11328 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11329 break 2 11330 fi 11331 done 11332 done 11333 IFS=$as_save_IFS 11334 11335 ;; 11336 esac 11337 fi 11338 TAR=$ac_cv_path_TAR 11339 if test -n "$TAR"; then 11340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11341 $as_echo "$TAR" >&6; } 11342 else 11343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11344 $as_echo "no" >&6; } 11345 fi 11346 11347 11348 test -n "$TAR" && break 11349 done 11350 11351 else 11352 # The variable is set, but is it from the command line or the environment? 11353 11354 # Try to remove the string !TAR! from our list. 11355 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/} 11356 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11357 # If it failed, the variable was not from the command line. Ignore it, 11358 # but warn the user (except for BASH, which is always set by the calling BASH). 11359 if test "xTAR" != xBASH; then 11360 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5 11361 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;} 11362 fi 11363 # Try to locate tool using the code snippet 11364 for ac_prog in gtar tar 11365 do 11366 # Extract the first word of "$ac_prog", so it can be a program name with args. 11367 set dummy $ac_prog; ac_word=$2 11368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11369 $as_echo_n "checking for $ac_word... " >&6; } 11370 if ${ac_cv_path_TAR+:} false; then : 11371 $as_echo_n "(cached) " >&6 11372 else 11373 case $TAR in 11374 [\\/]* | ?:[\\/]*) 11375 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11376 ;; 11377 *) 11378 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11379 for as_dir in $PATH 11380 do 11381 IFS=$as_save_IFS 11382 test -z "$as_dir" && as_dir=. 11383 for ac_exec_ext in '' $ac_executable_extensions; do 11384 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11385 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11386 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11387 break 2 11388 fi 11389 done 11390 done 11391 IFS=$as_save_IFS 11392 11393 ;; 11394 esac 11395 fi 11396 TAR=$ac_cv_path_TAR 11397 if test -n "$TAR"; then 11398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11399 $as_echo "$TAR" >&6; } 11400 else 11401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11402 $as_echo "no" >&6; } 11403 fi 11404 11405 11406 test -n "$TAR" && break 11407 done 11408 11409 else 11410 # If it succeeded, then it was overridden by the user. We will use it 11411 # for the tool. 11412 11413 # First remove it from the list of overridden variables, so we can test 11414 # for unknown variables in the end. 11415 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11416 11417 # Check if we try to supply an empty value 11418 if test "x$TAR" = x; then 11419 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAR= (no value)" >&5 11420 $as_echo "$as_me: Setting user supplied tool TAR= (no value)" >&6;} 11421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11422 $as_echo_n "checking for TAR... " >&6; } 11423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11424 $as_echo "disabled" >&6; } 11425 else 11426 # Check if the provided tool contains a complete path. 11427 tool_specified="$TAR" 11428 tool_basename="${tool_specified##*/}" 11429 if test "x$tool_basename" = "x$tool_specified"; then 11430 # A command without a complete path is provided, search $PATH. 11431 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5 11432 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;} 11433 # Extract the first word of "$tool_basename", so it can be a program name with args. 11434 set dummy $tool_basename; ac_word=$2 11435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11436 $as_echo_n "checking for $ac_word... " >&6; } 11437 if ${ac_cv_path_TAR+:} false; then : 11438 $as_echo_n "(cached) " >&6 11439 else 11440 case $TAR in 11441 [\\/]* | ?:[\\/]*) 11442 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11443 ;; 11444 *) 11445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11446 for as_dir in $PATH 11447 do 11448 IFS=$as_save_IFS 11449 test -z "$as_dir" && as_dir=. 11450 for ac_exec_ext in '' $ac_executable_extensions; do 11451 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11452 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11453 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11454 break 2 11455 fi 11456 done 11457 done 11458 IFS=$as_save_IFS 11459 11460 ;; 11461 esac 11462 fi 11463 TAR=$ac_cv_path_TAR 11464 if test -n "$TAR"; then 11465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11466 $as_echo "$TAR" >&6; } 11467 else 11468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11469 $as_echo "no" >&6; } 11470 fi 11471 11472 11473 if test "x$TAR" = x; then 11474 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11475 fi 11476 else 11477 # Otherwise we believe it is a complete path. Use it as it is. 11478 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5 11479 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;} 11480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11481 $as_echo_n "checking for TAR... " >&6; } 11482 if test ! -x "$tool_specified"; then 11483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11484 $as_echo "not found" >&6; } 11485 as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5 11486 fi 11487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11488 $as_echo "$tool_specified" >&6; } 11489 fi 11490 fi 11491 fi 11492 11493 fi 11494 11495 11496 11497 if test "x$TAR" = x; then 11498 as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5 11499 fi 11500 11501 11502 11503 11504 11505 # Publish this variable in the help. 11506 11507 11508 if [ -z "${TEE+x}" ]; then 11509 # The variable is not set by user, try to locate tool using the code snippet 11510 for ac_prog in tee 11511 do 11512 # Extract the first word of "$ac_prog", so it can be a program name with args. 11513 set dummy $ac_prog; ac_word=$2 11514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11515 $as_echo_n "checking for $ac_word... " >&6; } 11516 if ${ac_cv_path_TEE+:} false; then : 11517 $as_echo_n "(cached) " >&6 11518 else 11519 case $TEE in 11520 [\\/]* | ?:[\\/]*) 11521 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11522 ;; 11523 *) 11524 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11525 for as_dir in $PATH 11526 do 11527 IFS=$as_save_IFS 11528 test -z "$as_dir" && as_dir=. 11529 for ac_exec_ext in '' $ac_executable_extensions; do 11530 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11531 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11532 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11533 break 2 11534 fi 11535 done 11536 done 11537 IFS=$as_save_IFS 11538 11539 ;; 11540 esac 11541 fi 11542 TEE=$ac_cv_path_TEE 11543 if test -n "$TEE"; then 11544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11545 $as_echo "$TEE" >&6; } 11546 else 11547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11548 $as_echo "no" >&6; } 11549 fi 11550 11551 11552 test -n "$TEE" && break 11553 done 11554 11555 else 11556 # The variable is set, but is it from the command line or the environment? 11557 11558 # Try to remove the string !TEE! from our list. 11559 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/} 11560 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11561 # If it failed, the variable was not from the command line. Ignore it, 11562 # but warn the user (except for BASH, which is always set by the calling BASH). 11563 if test "xTEE" != xBASH; then 11564 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5 11565 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;} 11566 fi 11567 # Try to locate tool using the code snippet 11568 for ac_prog in tee 11569 do 11570 # Extract the first word of "$ac_prog", so it can be a program name with args. 11571 set dummy $ac_prog; ac_word=$2 11572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11573 $as_echo_n "checking for $ac_word... " >&6; } 11574 if ${ac_cv_path_TEE+:} false; then : 11575 $as_echo_n "(cached) " >&6 11576 else 11577 case $TEE in 11578 [\\/]* | ?:[\\/]*) 11579 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11580 ;; 11581 *) 11582 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11583 for as_dir in $PATH 11584 do 11585 IFS=$as_save_IFS 11586 test -z "$as_dir" && as_dir=. 11587 for ac_exec_ext in '' $ac_executable_extensions; do 11588 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11589 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11590 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11591 break 2 11592 fi 11593 done 11594 done 11595 IFS=$as_save_IFS 11596 11597 ;; 11598 esac 11599 fi 11600 TEE=$ac_cv_path_TEE 11601 if test -n "$TEE"; then 11602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11603 $as_echo "$TEE" >&6; } 11604 else 11605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11606 $as_echo "no" >&6; } 11607 fi 11608 11609 11610 test -n "$TEE" && break 11611 done 11612 11613 else 11614 # If it succeeded, then it was overridden by the user. We will use it 11615 # for the tool. 11616 11617 # First remove it from the list of overridden variables, so we can test 11618 # for unknown variables in the end. 11619 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11620 11621 # Check if we try to supply an empty value 11622 if test "x$TEE" = x; then 11623 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TEE= (no value)" >&5 11624 $as_echo "$as_me: Setting user supplied tool TEE= (no value)" >&6;} 11625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11626 $as_echo_n "checking for TEE... " >&6; } 11627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11628 $as_echo "disabled" >&6; } 11629 else 11630 # Check if the provided tool contains a complete path. 11631 tool_specified="$TEE" 11632 tool_basename="${tool_specified##*/}" 11633 if test "x$tool_basename" = "x$tool_specified"; then 11634 # A command without a complete path is provided, search $PATH. 11635 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5 11636 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;} 11637 # Extract the first word of "$tool_basename", so it can be a program name with args. 11638 set dummy $tool_basename; ac_word=$2 11639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11640 $as_echo_n "checking for $ac_word... " >&6; } 11641 if ${ac_cv_path_TEE+:} false; then : 11642 $as_echo_n "(cached) " >&6 11643 else 11644 case $TEE in 11645 [\\/]* | ?:[\\/]*) 11646 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11647 ;; 11648 *) 11649 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11650 for as_dir in $PATH 11651 do 11652 IFS=$as_save_IFS 11653 test -z "$as_dir" && as_dir=. 11654 for ac_exec_ext in '' $ac_executable_extensions; do 11655 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11656 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11657 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11658 break 2 11659 fi 11660 done 11661 done 11662 IFS=$as_save_IFS 11663 11664 ;; 11665 esac 11666 fi 11667 TEE=$ac_cv_path_TEE 11668 if test -n "$TEE"; then 11669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11670 $as_echo "$TEE" >&6; } 11671 else 11672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11673 $as_echo "no" >&6; } 11674 fi 11675 11676 11677 if test "x$TEE" = x; then 11678 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11679 fi 11680 else 11681 # Otherwise we believe it is a complete path. Use it as it is. 11682 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5 11683 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;} 11684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11685 $as_echo_n "checking for TEE... " >&6; } 11686 if test ! -x "$tool_specified"; then 11687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11688 $as_echo "not found" >&6; } 11689 as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5 11690 fi 11691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11692 $as_echo "$tool_specified" >&6; } 11693 fi 11694 fi 11695 fi 11696 11697 fi 11698 11699 11700 11701 if test "x$TEE" = x; then 11702 as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5 11703 fi 11704 11705 11706 11707 11708 11709 # Publish this variable in the help. 11710 11711 11712 if [ -z "${TOUCH+x}" ]; then 11713 # The variable is not set by user, try to locate tool using the code snippet 11714 for ac_prog in touch 11715 do 11716 # Extract the first word of "$ac_prog", so it can be a program name with args. 11717 set dummy $ac_prog; ac_word=$2 11718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11719 $as_echo_n "checking for $ac_word... " >&6; } 11720 if ${ac_cv_path_TOUCH+:} false; then : 11721 $as_echo_n "(cached) " >&6 11722 else 11723 case $TOUCH in 11724 [\\/]* | ?:[\\/]*) 11725 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11726 ;; 11727 *) 11728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11729 for as_dir in $PATH 11730 do 11731 IFS=$as_save_IFS 11732 test -z "$as_dir" && as_dir=. 11733 for ac_exec_ext in '' $ac_executable_extensions; do 11734 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11735 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11736 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11737 break 2 11738 fi 11739 done 11740 done 11741 IFS=$as_save_IFS 11742 11743 ;; 11744 esac 11745 fi 11746 TOUCH=$ac_cv_path_TOUCH 11747 if test -n "$TOUCH"; then 11748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11749 $as_echo "$TOUCH" >&6; } 11750 else 11751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11752 $as_echo "no" >&6; } 11753 fi 11754 11755 11756 test -n "$TOUCH" && break 11757 done 11758 11759 else 11760 # The variable is set, but is it from the command line or the environment? 11761 11762 # Try to remove the string !TOUCH! from our list. 11763 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/} 11764 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11765 # If it failed, the variable was not from the command line. Ignore it, 11766 # but warn the user (except for BASH, which is always set by the calling BASH). 11767 if test "xTOUCH" != xBASH; then 11768 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5 11769 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;} 11770 fi 11771 # Try to locate tool using the code snippet 11772 for ac_prog in touch 11773 do 11774 # Extract the first word of "$ac_prog", so it can be a program name with args. 11775 set dummy $ac_prog; ac_word=$2 11776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11777 $as_echo_n "checking for $ac_word... " >&6; } 11778 if ${ac_cv_path_TOUCH+:} false; then : 11779 $as_echo_n "(cached) " >&6 11780 else 11781 case $TOUCH in 11782 [\\/]* | ?:[\\/]*) 11783 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11784 ;; 11785 *) 11786 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11787 for as_dir in $PATH 11788 do 11789 IFS=$as_save_IFS 11790 test -z "$as_dir" && as_dir=. 11791 for ac_exec_ext in '' $ac_executable_extensions; do 11792 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11793 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11794 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11795 break 2 11796 fi 11797 done 11798 done 11799 IFS=$as_save_IFS 11800 11801 ;; 11802 esac 11803 fi 11804 TOUCH=$ac_cv_path_TOUCH 11805 if test -n "$TOUCH"; then 11806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11807 $as_echo "$TOUCH" >&6; } 11808 else 11809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11810 $as_echo "no" >&6; } 11811 fi 11812 11813 11814 test -n "$TOUCH" && break 11815 done 11816 11817 else 11818 # If it succeeded, then it was overridden by the user. We will use it 11819 # for the tool. 11820 11821 # First remove it from the list of overridden variables, so we can test 11822 # for unknown variables in the end. 11823 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11824 11825 # Check if we try to supply an empty value 11826 if test "x$TOUCH" = x; then 11827 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TOUCH= (no value)" >&5 11828 $as_echo "$as_me: Setting user supplied tool TOUCH= (no value)" >&6;} 11829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11830 $as_echo_n "checking for TOUCH... " >&6; } 11831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11832 $as_echo "disabled" >&6; } 11833 else 11834 # Check if the provided tool contains a complete path. 11835 tool_specified="$TOUCH" 11836 tool_basename="${tool_specified##*/}" 11837 if test "x$tool_basename" = "x$tool_specified"; then 11838 # A command without a complete path is provided, search $PATH. 11839 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5 11840 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;} 11841 # Extract the first word of "$tool_basename", so it can be a program name with args. 11842 set dummy $tool_basename; ac_word=$2 11843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11844 $as_echo_n "checking for $ac_word... " >&6; } 11845 if ${ac_cv_path_TOUCH+:} false; then : 11846 $as_echo_n "(cached) " >&6 11847 else 11848 case $TOUCH in 11849 [\\/]* | ?:[\\/]*) 11850 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11851 ;; 11852 *) 11853 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11854 for as_dir in $PATH 11855 do 11856 IFS=$as_save_IFS 11857 test -z "$as_dir" && as_dir=. 11858 for ac_exec_ext in '' $ac_executable_extensions; do 11859 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11860 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11861 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11862 break 2 11863 fi 11864 done 11865 done 11866 IFS=$as_save_IFS 11867 11868 ;; 11869 esac 11870 fi 11871 TOUCH=$ac_cv_path_TOUCH 11872 if test -n "$TOUCH"; then 11873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11874 $as_echo "$TOUCH" >&6; } 11875 else 11876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11877 $as_echo "no" >&6; } 11878 fi 11879 11880 11881 if test "x$TOUCH" = x; then 11882 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11883 fi 11884 else 11885 # Otherwise we believe it is a complete path. Use it as it is. 11886 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5 11887 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;} 11888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11889 $as_echo_n "checking for TOUCH... " >&6; } 11890 if test ! -x "$tool_specified"; then 11891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11892 $as_echo "not found" >&6; } 11893 as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5 11894 fi 11895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11896 $as_echo "$tool_specified" >&6; } 11897 fi 11898 fi 11899 fi 11900 11901 fi 11902 11903 11904 11905 if test "x$TOUCH" = x; then 11906 as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5 11907 fi 11908 11909 11910 11911 11912 11913 # Publish this variable in the help. 11914 11915 11916 if [ -z "${TR+x}" ]; then 11917 # The variable is not set by user, try to locate tool using the code snippet 11918 for ac_prog in tr 11919 do 11920 # Extract the first word of "$ac_prog", so it can be a program name with args. 11921 set dummy $ac_prog; ac_word=$2 11922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11923 $as_echo_n "checking for $ac_word... " >&6; } 11924 if ${ac_cv_path_TR+:} false; then : 11925 $as_echo_n "(cached) " >&6 11926 else 11927 case $TR in 11928 [\\/]* | ?:[\\/]*) 11929 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11930 ;; 11931 *) 11932 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11933 for as_dir in $PATH 11934 do 11935 IFS=$as_save_IFS 11936 test -z "$as_dir" && as_dir=. 11937 for ac_exec_ext in '' $ac_executable_extensions; do 11938 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11939 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11940 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11941 break 2 11942 fi 11943 done 11944 done 11945 IFS=$as_save_IFS 11946 11947 ;; 11948 esac 11949 fi 11950 TR=$ac_cv_path_TR 11951 if test -n "$TR"; then 11952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11953 $as_echo "$TR" >&6; } 11954 else 11955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11956 $as_echo "no" >&6; } 11957 fi 11958 11959 11960 test -n "$TR" && break 11961 done 11962 11963 else 11964 # The variable is set, but is it from the command line or the environment? 11965 11966 # Try to remove the string !TR! from our list. 11967 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/} 11968 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11969 # If it failed, the variable was not from the command line. Ignore it, 11970 # but warn the user (except for BASH, which is always set by the calling BASH). 11971 if test "xTR" != xBASH; then 11972 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5 11973 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;} 11974 fi 11975 # Try to locate tool using the code snippet 11976 for ac_prog in tr 11977 do 11978 # Extract the first word of "$ac_prog", so it can be a program name with args. 11979 set dummy $ac_prog; ac_word=$2 11980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11981 $as_echo_n "checking for $ac_word... " >&6; } 11982 if ${ac_cv_path_TR+:} false; then : 11983 $as_echo_n "(cached) " >&6 11984 else 11985 case $TR in 11986 [\\/]* | ?:[\\/]*) 11987 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11988 ;; 11989 *) 11990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11991 for as_dir in $PATH 11992 do 11993 IFS=$as_save_IFS 11994 test -z "$as_dir" && as_dir=. 11995 for ac_exec_ext in '' $ac_executable_extensions; do 11996 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11997 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11999 break 2 12000 fi 12001 done 12002 done 12003 IFS=$as_save_IFS 12004 12005 ;; 12006 esac 12007 fi 12008 TR=$ac_cv_path_TR 12009 if test -n "$TR"; then 12010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12011 $as_echo "$TR" >&6; } 12012 else 12013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12014 $as_echo "no" >&6; } 12015 fi 12016 12017 12018 test -n "$TR" && break 12019 done 12020 12021 else 12022 # If it succeeded, then it was overridden by the user. We will use it 12023 # for the tool. 12024 12025 # First remove it from the list of overridden variables, so we can test 12026 # for unknown variables in the end. 12027 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12028 12029 # Check if we try to supply an empty value 12030 if test "x$TR" = x; then 12031 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TR= (no value)" >&5 12032 $as_echo "$as_me: Setting user supplied tool TR= (no value)" >&6;} 12033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12034 $as_echo_n "checking for TR... " >&6; } 12035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12036 $as_echo "disabled" >&6; } 12037 else 12038 # Check if the provided tool contains a complete path. 12039 tool_specified="$TR" 12040 tool_basename="${tool_specified##*/}" 12041 if test "x$tool_basename" = "x$tool_specified"; then 12042 # A command without a complete path is provided, search $PATH. 12043 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5 12044 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;} 12045 # Extract the first word of "$tool_basename", so it can be a program name with args. 12046 set dummy $tool_basename; ac_word=$2 12047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12048 $as_echo_n "checking for $ac_word... " >&6; } 12049 if ${ac_cv_path_TR+:} false; then : 12050 $as_echo_n "(cached) " >&6 12051 else 12052 case $TR in 12053 [\\/]* | ?:[\\/]*) 12054 ac_cv_path_TR="$TR" # Let the user override the test with a path. 12055 ;; 12056 *) 12057 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12058 for as_dir in $PATH 12059 do 12060 IFS=$as_save_IFS 12061 test -z "$as_dir" && as_dir=. 12062 for ac_exec_ext in '' $ac_executable_extensions; do 12063 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12064 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 12065 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12066 break 2 12067 fi 12068 done 12069 done 12070 IFS=$as_save_IFS 12071 12072 ;; 12073 esac 12074 fi 12075 TR=$ac_cv_path_TR 12076 if test -n "$TR"; then 12077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12078 $as_echo "$TR" >&6; } 12079 else 12080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12081 $as_echo "no" >&6; } 12082 fi 12083 12084 12085 if test "x$TR" = x; then 12086 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12087 fi 12088 else 12089 # Otherwise we believe it is a complete path. Use it as it is. 12090 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5 12091 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;} 12092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12093 $as_echo_n "checking for TR... " >&6; } 12094 if test ! -x "$tool_specified"; then 12095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12096 $as_echo "not found" >&6; } 12097 as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5 12098 fi 12099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12100 $as_echo "$tool_specified" >&6; } 12101 fi 12102 fi 12103 fi 12104 12105 fi 12106 12107 12108 12109 if test "x$TR" = x; then 12110 as_fn_error $? "Could not find required tool for TR" "$LINENO" 5 12111 fi 12112 12113 12114 12115 12116 12117 # Publish this variable in the help. 12118 12119 12120 if [ -z "${UNAME+x}" ]; then 12121 # The variable is not set by user, try to locate tool using the code snippet 12122 for ac_prog in uname 12123 do 12124 # Extract the first word of "$ac_prog", so it can be a program name with args. 12125 set dummy $ac_prog; ac_word=$2 12126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12127 $as_echo_n "checking for $ac_word... " >&6; } 12128 if ${ac_cv_path_UNAME+:} false; then : 12129 $as_echo_n "(cached) " >&6 12130 else 12131 case $UNAME in 12132 [\\/]* | ?:[\\/]*) 12133 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12134 ;; 12135 *) 12136 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12137 for as_dir in $PATH 12138 do 12139 IFS=$as_save_IFS 12140 test -z "$as_dir" && as_dir=. 12141 for ac_exec_ext in '' $ac_executable_extensions; do 12142 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12143 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12144 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12145 break 2 12146 fi 12147 done 12148 done 12149 IFS=$as_save_IFS 12150 12151 ;; 12152 esac 12153 fi 12154 UNAME=$ac_cv_path_UNAME 12155 if test -n "$UNAME"; then 12156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12157 $as_echo "$UNAME" >&6; } 12158 else 12159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12160 $as_echo "no" >&6; } 12161 fi 12162 12163 12164 test -n "$UNAME" && break 12165 done 12166 12167 else 12168 # The variable is set, but is it from the command line or the environment? 12169 12170 # Try to remove the string !UNAME! from our list. 12171 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/} 12172 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12173 # If it failed, the variable was not from the command line. Ignore it, 12174 # but warn the user (except for BASH, which is always set by the calling BASH). 12175 if test "xUNAME" != xBASH; then 12176 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5 12177 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;} 12178 fi 12179 # Try to locate tool using the code snippet 12180 for ac_prog in uname 12181 do 12182 # Extract the first word of "$ac_prog", so it can be a program name with args. 12183 set dummy $ac_prog; ac_word=$2 12184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12185 $as_echo_n "checking for $ac_word... " >&6; } 12186 if ${ac_cv_path_UNAME+:} false; then : 12187 $as_echo_n "(cached) " >&6 12188 else 12189 case $UNAME in 12190 [\\/]* | ?:[\\/]*) 12191 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12192 ;; 12193 *) 12194 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12195 for as_dir in $PATH 12196 do 12197 IFS=$as_save_IFS 12198 test -z "$as_dir" && as_dir=. 12199 for ac_exec_ext in '' $ac_executable_extensions; do 12200 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12201 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12202 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12203 break 2 12204 fi 12205 done 12206 done 12207 IFS=$as_save_IFS 12208 12209 ;; 12210 esac 12211 fi 12212 UNAME=$ac_cv_path_UNAME 12213 if test -n "$UNAME"; then 12214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12215 $as_echo "$UNAME" >&6; } 12216 else 12217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12218 $as_echo "no" >&6; } 12219 fi 12220 12221 12222 test -n "$UNAME" && break 12223 done 12224 12225 else 12226 # If it succeeded, then it was overridden by the user. We will use it 12227 # for the tool. 12228 12229 # First remove it from the list of overridden variables, so we can test 12230 # for unknown variables in the end. 12231 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12232 12233 # Check if we try to supply an empty value 12234 if test "x$UNAME" = x; then 12235 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNAME= (no value)" >&5 12236 $as_echo "$as_me: Setting user supplied tool UNAME= (no value)" >&6;} 12237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12238 $as_echo_n "checking for UNAME... " >&6; } 12239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12240 $as_echo "disabled" >&6; } 12241 else 12242 # Check if the provided tool contains a complete path. 12243 tool_specified="$UNAME" 12244 tool_basename="${tool_specified##*/}" 12245 if test "x$tool_basename" = "x$tool_specified"; then 12246 # A command without a complete path is provided, search $PATH. 12247 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5 12248 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;} 12249 # Extract the first word of "$tool_basename", so it can be a program name with args. 12250 set dummy $tool_basename; ac_word=$2 12251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12252 $as_echo_n "checking for $ac_word... " >&6; } 12253 if ${ac_cv_path_UNAME+:} false; then : 12254 $as_echo_n "(cached) " >&6 12255 else 12256 case $UNAME in 12257 [\\/]* | ?:[\\/]*) 12258 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12259 ;; 12260 *) 12261 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12262 for as_dir in $PATH 12263 do 12264 IFS=$as_save_IFS 12265 test -z "$as_dir" && as_dir=. 12266 for ac_exec_ext in '' $ac_executable_extensions; do 12267 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12268 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12269 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12270 break 2 12271 fi 12272 done 12273 done 12274 IFS=$as_save_IFS 12275 12276 ;; 12277 esac 12278 fi 12279 UNAME=$ac_cv_path_UNAME 12280 if test -n "$UNAME"; then 12281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12282 $as_echo "$UNAME" >&6; } 12283 else 12284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12285 $as_echo "no" >&6; } 12286 fi 12287 12288 12289 if test "x$UNAME" = x; then 12290 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12291 fi 12292 else 12293 # Otherwise we believe it is a complete path. Use it as it is. 12294 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5 12295 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;} 12296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12297 $as_echo_n "checking for UNAME... " >&6; } 12298 if test ! -x "$tool_specified"; then 12299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12300 $as_echo "not found" >&6; } 12301 as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 12302 fi 12303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12304 $as_echo "$tool_specified" >&6; } 12305 fi 12306 fi 12307 fi 12308 12309 fi 12310 12311 12312 12313 if test "x$UNAME" = x; then 12314 as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5 12315 fi 12316 12317 12318 12319 12320 12321 # Publish this variable in the help. 12322 12323 12324 if [ -z "${UNIQ+x}" ]; then 12325 # The variable is not set by user, try to locate tool using the code snippet 12326 for ac_prog in uniq 12327 do 12328 # Extract the first word of "$ac_prog", so it can be a program name with args. 12329 set dummy $ac_prog; ac_word=$2 12330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12331 $as_echo_n "checking for $ac_word... " >&6; } 12332 if ${ac_cv_path_UNIQ+:} false; then : 12333 $as_echo_n "(cached) " >&6 12334 else 12335 case $UNIQ in 12336 [\\/]* | ?:[\\/]*) 12337 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12338 ;; 12339 *) 12340 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12341 for as_dir in $PATH 12342 do 12343 IFS=$as_save_IFS 12344 test -z "$as_dir" && as_dir=. 12345 for ac_exec_ext in '' $ac_executable_extensions; do 12346 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12347 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12348 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12349 break 2 12350 fi 12351 done 12352 done 12353 IFS=$as_save_IFS 12354 12355 ;; 12356 esac 12357 fi 12358 UNIQ=$ac_cv_path_UNIQ 12359 if test -n "$UNIQ"; then 12360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12361 $as_echo "$UNIQ" >&6; } 12362 else 12363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12364 $as_echo "no" >&6; } 12365 fi 12366 12367 12368 test -n "$UNIQ" && break 12369 done 12370 12371 else 12372 # The variable is set, but is it from the command line or the environment? 12373 12374 # Try to remove the string !UNIQ! from our list. 12375 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/} 12376 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12377 # If it failed, the variable was not from the command line. Ignore it, 12378 # but warn the user (except for BASH, which is always set by the calling BASH). 12379 if test "xUNIQ" != xBASH; then 12380 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5 12381 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;} 12382 fi 12383 # Try to locate tool using the code snippet 12384 for ac_prog in uniq 12385 do 12386 # Extract the first word of "$ac_prog", so it can be a program name with args. 12387 set dummy $ac_prog; ac_word=$2 12388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12389 $as_echo_n "checking for $ac_word... " >&6; } 12390 if ${ac_cv_path_UNIQ+:} false; then : 12391 $as_echo_n "(cached) " >&6 12392 else 12393 case $UNIQ in 12394 [\\/]* | ?:[\\/]*) 12395 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12396 ;; 12397 *) 12398 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12399 for as_dir in $PATH 12400 do 12401 IFS=$as_save_IFS 12402 test -z "$as_dir" && as_dir=. 12403 for ac_exec_ext in '' $ac_executable_extensions; do 12404 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12405 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12406 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12407 break 2 12408 fi 12409 done 12410 done 12411 IFS=$as_save_IFS 12412 12413 ;; 12414 esac 12415 fi 12416 UNIQ=$ac_cv_path_UNIQ 12417 if test -n "$UNIQ"; then 12418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12419 $as_echo "$UNIQ" >&6; } 12420 else 12421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12422 $as_echo "no" >&6; } 12423 fi 12424 12425 12426 test -n "$UNIQ" && break 12427 done 12428 12429 else 12430 # If it succeeded, then it was overridden by the user. We will use it 12431 # for the tool. 12432 12433 # First remove it from the list of overridden variables, so we can test 12434 # for unknown variables in the end. 12435 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12436 12437 # Check if we try to supply an empty value 12438 if test "x$UNIQ" = x; then 12439 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNIQ= (no value)" >&5 12440 $as_echo "$as_me: Setting user supplied tool UNIQ= (no value)" >&6;} 12441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12442 $as_echo_n "checking for UNIQ... " >&6; } 12443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12444 $as_echo "disabled" >&6; } 12445 else 12446 # Check if the provided tool contains a complete path. 12447 tool_specified="$UNIQ" 12448 tool_basename="${tool_specified##*/}" 12449 if test "x$tool_basename" = "x$tool_specified"; then 12450 # A command without a complete path is provided, search $PATH. 12451 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5 12452 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;} 12453 # Extract the first word of "$tool_basename", so it can be a program name with args. 12454 set dummy $tool_basename; ac_word=$2 12455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12456 $as_echo_n "checking for $ac_word... " >&6; } 12457 if ${ac_cv_path_UNIQ+:} false; then : 12458 $as_echo_n "(cached) " >&6 12459 else 12460 case $UNIQ in 12461 [\\/]* | ?:[\\/]*) 12462 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12463 ;; 12464 *) 12465 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12466 for as_dir in $PATH 12467 do 12468 IFS=$as_save_IFS 12469 test -z "$as_dir" && as_dir=. 12470 for ac_exec_ext in '' $ac_executable_extensions; do 12471 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12472 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12473 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12474 break 2 12475 fi 12476 done 12477 done 12478 IFS=$as_save_IFS 12479 12480 ;; 12481 esac 12482 fi 12483 UNIQ=$ac_cv_path_UNIQ 12484 if test -n "$UNIQ"; then 12485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12486 $as_echo "$UNIQ" >&6; } 12487 else 12488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12489 $as_echo "no" >&6; } 12490 fi 12491 12492 12493 if test "x$UNIQ" = x; then 12494 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12495 fi 12496 else 12497 # Otherwise we believe it is a complete path. Use it as it is. 12498 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5 12499 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;} 12500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12501 $as_echo_n "checking for UNIQ... " >&6; } 12502 if test ! -x "$tool_specified"; then 12503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12504 $as_echo "not found" >&6; } 12505 as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5 12506 fi 12507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12508 $as_echo "$tool_specified" >&6; } 12509 fi 12510 fi 12511 fi 12512 12513 fi 12514 12515 12516 12517 if test "x$UNIQ" = x; then 12518 as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5 12519 fi 12520 12521 12522 12523 12524 12525 # Publish this variable in the help. 12526 12527 12528 if [ -z "${WC+x}" ]; then 12529 # The variable is not set by user, try to locate tool using the code snippet 12530 for ac_prog in wc 12531 do 12532 # Extract the first word of "$ac_prog", so it can be a program name with args. 12533 set dummy $ac_prog; ac_word=$2 12534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12535 $as_echo_n "checking for $ac_word... " >&6; } 12536 if ${ac_cv_path_WC+:} false; then : 12537 $as_echo_n "(cached) " >&6 12538 else 12539 case $WC in 12540 [\\/]* | ?:[\\/]*) 12541 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12542 ;; 12543 *) 12544 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12545 for as_dir in $PATH 12546 do 12547 IFS=$as_save_IFS 12548 test -z "$as_dir" && as_dir=. 12549 for ac_exec_ext in '' $ac_executable_extensions; do 12550 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12551 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12552 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12553 break 2 12554 fi 12555 done 12556 done 12557 IFS=$as_save_IFS 12558 12559 ;; 12560 esac 12561 fi 12562 WC=$ac_cv_path_WC 12563 if test -n "$WC"; then 12564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12565 $as_echo "$WC" >&6; } 12566 else 12567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12568 $as_echo "no" >&6; } 12569 fi 12570 12571 12572 test -n "$WC" && break 12573 done 12574 12575 else 12576 # The variable is set, but is it from the command line or the environment? 12577 12578 # Try to remove the string !WC! from our list. 12579 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/} 12580 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12581 # If it failed, the variable was not from the command line. Ignore it, 12582 # but warn the user (except for BASH, which is always set by the calling BASH). 12583 if test "xWC" != xBASH; then 12584 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5 12585 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;} 12586 fi 12587 # Try to locate tool using the code snippet 12588 for ac_prog in wc 12589 do 12590 # Extract the first word of "$ac_prog", so it can be a program name with args. 12591 set dummy $ac_prog; ac_word=$2 12592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12593 $as_echo_n "checking for $ac_word... " >&6; } 12594 if ${ac_cv_path_WC+:} false; then : 12595 $as_echo_n "(cached) " >&6 12596 else 12597 case $WC in 12598 [\\/]* | ?:[\\/]*) 12599 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12600 ;; 12601 *) 12602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12603 for as_dir in $PATH 12604 do 12605 IFS=$as_save_IFS 12606 test -z "$as_dir" && as_dir=. 12607 for ac_exec_ext in '' $ac_executable_extensions; do 12608 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12609 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12611 break 2 12612 fi 12613 done 12614 done 12615 IFS=$as_save_IFS 12616 12617 ;; 12618 esac 12619 fi 12620 WC=$ac_cv_path_WC 12621 if test -n "$WC"; then 12622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12623 $as_echo "$WC" >&6; } 12624 else 12625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12626 $as_echo "no" >&6; } 12627 fi 12628 12629 12630 test -n "$WC" && break 12631 done 12632 12633 else 12634 # If it succeeded, then it was overridden by the user. We will use it 12635 # for the tool. 12636 12637 # First remove it from the list of overridden variables, so we can test 12638 # for unknown variables in the end. 12639 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12640 12641 # Check if we try to supply an empty value 12642 if test "x$WC" = x; then 12643 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WC= (no value)" >&5 12644 $as_echo "$as_me: Setting user supplied tool WC= (no value)" >&6;} 12645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12646 $as_echo_n "checking for WC... " >&6; } 12647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12648 $as_echo "disabled" >&6; } 12649 else 12650 # Check if the provided tool contains a complete path. 12651 tool_specified="$WC" 12652 tool_basename="${tool_specified##*/}" 12653 if test "x$tool_basename" = "x$tool_specified"; then 12654 # A command without a complete path is provided, search $PATH. 12655 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5 12656 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;} 12657 # Extract the first word of "$tool_basename", so it can be a program name with args. 12658 set dummy $tool_basename; ac_word=$2 12659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12660 $as_echo_n "checking for $ac_word... " >&6; } 12661 if ${ac_cv_path_WC+:} false; then : 12662 $as_echo_n "(cached) " >&6 12663 else 12664 case $WC in 12665 [\\/]* | ?:[\\/]*) 12666 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12667 ;; 12668 *) 12669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12670 for as_dir in $PATH 12671 do 12672 IFS=$as_save_IFS 12673 test -z "$as_dir" && as_dir=. 12674 for ac_exec_ext in '' $ac_executable_extensions; do 12675 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12676 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12677 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12678 break 2 12679 fi 12680 done 12681 done 12682 IFS=$as_save_IFS 12683 12684 ;; 12685 esac 12686 fi 12687 WC=$ac_cv_path_WC 12688 if test -n "$WC"; then 12689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12690 $as_echo "$WC" >&6; } 12691 else 12692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12693 $as_echo "no" >&6; } 12694 fi 12695 12696 12697 if test "x$WC" = x; then 12698 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12699 fi 12700 else 12701 # Otherwise we believe it is a complete path. Use it as it is. 12702 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5 12703 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;} 12704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12705 $as_echo_n "checking for WC... " >&6; } 12706 if test ! -x "$tool_specified"; then 12707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12708 $as_echo "not found" >&6; } 12709 as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5 12710 fi 12711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12712 $as_echo "$tool_specified" >&6; } 12713 fi 12714 fi 12715 fi 12716 12717 fi 12718 12719 12720 12721 if test "x$WC" = x; then 12722 as_fn_error $? "Could not find required tool for WC" "$LINENO" 5 12723 fi 12724 12725 12726 12727 12728 12729 # Publish this variable in the help. 12730 12731 12732 if [ -z "${WHICH+x}" ]; then 12733 # The variable is not set by user, try to locate tool using the code snippet 12734 for ac_prog in which 12735 do 12736 # Extract the first word of "$ac_prog", so it can be a program name with args. 12737 set dummy $ac_prog; ac_word=$2 12738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12739 $as_echo_n "checking for $ac_word... " >&6; } 12740 if ${ac_cv_path_WHICH+:} false; then : 12741 $as_echo_n "(cached) " >&6 12742 else 12743 case $WHICH in 12744 [\\/]* | ?:[\\/]*) 12745 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12746 ;; 12747 *) 12748 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12749 for as_dir in $PATH 12750 do 12751 IFS=$as_save_IFS 12752 test -z "$as_dir" && as_dir=. 12753 for ac_exec_ext in '' $ac_executable_extensions; do 12754 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12755 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12756 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12757 break 2 12758 fi 12759 done 12760 done 12761 IFS=$as_save_IFS 12762 12763 ;; 12764 esac 12765 fi 12766 WHICH=$ac_cv_path_WHICH 12767 if test -n "$WHICH"; then 12768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12769 $as_echo "$WHICH" >&6; } 12770 else 12771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12772 $as_echo "no" >&6; } 12773 fi 12774 12775 12776 test -n "$WHICH" && break 12777 done 12778 12779 else 12780 # The variable is set, but is it from the command line or the environment? 12781 12782 # Try to remove the string !WHICH! from our list. 12783 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/} 12784 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12785 # If it failed, the variable was not from the command line. Ignore it, 12786 # but warn the user (except for BASH, which is always set by the calling BASH). 12787 if test "xWHICH" != xBASH; then 12788 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5 12789 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;} 12790 fi 12791 # Try to locate tool using the code snippet 12792 for ac_prog in which 12793 do 12794 # Extract the first word of "$ac_prog", so it can be a program name with args. 12795 set dummy $ac_prog; ac_word=$2 12796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12797 $as_echo_n "checking for $ac_word... " >&6; } 12798 if ${ac_cv_path_WHICH+:} false; then : 12799 $as_echo_n "(cached) " >&6 12800 else 12801 case $WHICH in 12802 [\\/]* | ?:[\\/]*) 12803 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12804 ;; 12805 *) 12806 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12807 for as_dir in $PATH 12808 do 12809 IFS=$as_save_IFS 12810 test -z "$as_dir" && as_dir=. 12811 for ac_exec_ext in '' $ac_executable_extensions; do 12812 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12813 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12814 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12815 break 2 12816 fi 12817 done 12818 done 12819 IFS=$as_save_IFS 12820 12821 ;; 12822 esac 12823 fi 12824 WHICH=$ac_cv_path_WHICH 12825 if test -n "$WHICH"; then 12826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12827 $as_echo "$WHICH" >&6; } 12828 else 12829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12830 $as_echo "no" >&6; } 12831 fi 12832 12833 12834 test -n "$WHICH" && break 12835 done 12836 12837 else 12838 # If it succeeded, then it was overridden by the user. We will use it 12839 # for the tool. 12840 12841 # First remove it from the list of overridden variables, so we can test 12842 # for unknown variables in the end. 12843 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12844 12845 # Check if we try to supply an empty value 12846 if test "x$WHICH" = x; then 12847 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WHICH= (no value)" >&5 12848 $as_echo "$as_me: Setting user supplied tool WHICH= (no value)" >&6;} 12849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12850 $as_echo_n "checking for WHICH... " >&6; } 12851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12852 $as_echo "disabled" >&6; } 12853 else 12854 # Check if the provided tool contains a complete path. 12855 tool_specified="$WHICH" 12856 tool_basename="${tool_specified##*/}" 12857 if test "x$tool_basename" = "x$tool_specified"; then 12858 # A command without a complete path is provided, search $PATH. 12859 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5 12860 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;} 12861 # Extract the first word of "$tool_basename", so it can be a program name with args. 12862 set dummy $tool_basename; ac_word=$2 12863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12864 $as_echo_n "checking for $ac_word... " >&6; } 12865 if ${ac_cv_path_WHICH+:} false; then : 12866 $as_echo_n "(cached) " >&6 12867 else 12868 case $WHICH in 12869 [\\/]* | ?:[\\/]*) 12870 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12871 ;; 12872 *) 12873 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12874 for as_dir in $PATH 12875 do 12876 IFS=$as_save_IFS 12877 test -z "$as_dir" && as_dir=. 12878 for ac_exec_ext in '' $ac_executable_extensions; do 12879 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12880 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12881 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12882 break 2 12883 fi 12884 done 12885 done 12886 IFS=$as_save_IFS 12887 12888 ;; 12889 esac 12890 fi 12891 WHICH=$ac_cv_path_WHICH 12892 if test -n "$WHICH"; then 12893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12894 $as_echo "$WHICH" >&6; } 12895 else 12896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12897 $as_echo "no" >&6; } 12898 fi 12899 12900 12901 if test "x$WHICH" = x; then 12902 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12903 fi 12904 else 12905 # Otherwise we believe it is a complete path. Use it as it is. 12906 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5 12907 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;} 12908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12909 $as_echo_n "checking for WHICH... " >&6; } 12910 if test ! -x "$tool_specified"; then 12911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12912 $as_echo "not found" >&6; } 12913 as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5 12914 fi 12915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12916 $as_echo "$tool_specified" >&6; } 12917 fi 12918 fi 12919 fi 12920 12921 fi 12922 12923 12924 12925 if test "x$WHICH" = x; then 12926 as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5 12927 fi 12928 12929 12930 12931 12932 12933 # Publish this variable in the help. 12934 12935 12936 if [ -z "${XARGS+x}" ]; then 12937 # The variable is not set by user, try to locate tool using the code snippet 12938 for ac_prog in xargs 12939 do 12940 # Extract the first word of "$ac_prog", so it can be a program name with args. 12941 set dummy $ac_prog; ac_word=$2 12942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12943 $as_echo_n "checking for $ac_word... " >&6; } 12944 if ${ac_cv_path_XARGS+:} false; then : 12945 $as_echo_n "(cached) " >&6 12946 else 12947 case $XARGS in 12948 [\\/]* | ?:[\\/]*) 12949 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12950 ;; 12951 *) 12952 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12953 for as_dir in $PATH 12954 do 12955 IFS=$as_save_IFS 12956 test -z "$as_dir" && as_dir=. 12957 for ac_exec_ext in '' $ac_executable_extensions; do 12958 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12959 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12960 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12961 break 2 12962 fi 12963 done 12964 done 12965 IFS=$as_save_IFS 12966 12967 ;; 12968 esac 12969 fi 12970 XARGS=$ac_cv_path_XARGS 12971 if test -n "$XARGS"; then 12972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 12973 $as_echo "$XARGS" >&6; } 12974 else 12975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12976 $as_echo "no" >&6; } 12977 fi 12978 12979 12980 test -n "$XARGS" && break 12981 done 12982 12983 else 12984 # The variable is set, but is it from the command line or the environment? 12985 12986 # Try to remove the string !XARGS! from our list. 12987 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/} 12988 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12989 # If it failed, the variable was not from the command line. Ignore it, 12990 # but warn the user (except for BASH, which is always set by the calling BASH). 12991 if test "xXARGS" != xBASH; then 12992 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5 12993 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;} 12994 fi 12995 # Try to locate tool using the code snippet 12996 for ac_prog in xargs 12997 do 12998 # Extract the first word of "$ac_prog", so it can be a program name with args. 12999 set dummy $ac_prog; ac_word=$2 13000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13001 $as_echo_n "checking for $ac_word... " >&6; } 13002 if ${ac_cv_path_XARGS+:} false; then : 13003 $as_echo_n "(cached) " >&6 13004 else 13005 case $XARGS in 13006 [\\/]* | ?:[\\/]*) 13007 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13008 ;; 13009 *) 13010 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13011 for as_dir in $PATH 13012 do 13013 IFS=$as_save_IFS 13014 test -z "$as_dir" && as_dir=. 13015 for ac_exec_ext in '' $ac_executable_extensions; do 13016 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13017 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13018 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13019 break 2 13020 fi 13021 done 13022 done 13023 IFS=$as_save_IFS 13024 13025 ;; 13026 esac 13027 fi 13028 XARGS=$ac_cv_path_XARGS 13029 if test -n "$XARGS"; then 13030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13031 $as_echo "$XARGS" >&6; } 13032 else 13033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13034 $as_echo "no" >&6; } 13035 fi 13036 13037 13038 test -n "$XARGS" && break 13039 done 13040 13041 else 13042 # If it succeeded, then it was overridden by the user. We will use it 13043 # for the tool. 13044 13045 # First remove it from the list of overridden variables, so we can test 13046 # for unknown variables in the end. 13047 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13048 13049 # Check if we try to supply an empty value 13050 if test "x$XARGS" = x; then 13051 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XARGS= (no value)" >&5 13052 $as_echo "$as_me: Setting user supplied tool XARGS= (no value)" >&6;} 13053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13054 $as_echo_n "checking for XARGS... " >&6; } 13055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13056 $as_echo "disabled" >&6; } 13057 else 13058 # Check if the provided tool contains a complete path. 13059 tool_specified="$XARGS" 13060 tool_basename="${tool_specified##*/}" 13061 if test "x$tool_basename" = "x$tool_specified"; then 13062 # A command without a complete path is provided, search $PATH. 13063 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5 13064 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;} 13065 # Extract the first word of "$tool_basename", so it can be a program name with args. 13066 set dummy $tool_basename; ac_word=$2 13067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13068 $as_echo_n "checking for $ac_word... " >&6; } 13069 if ${ac_cv_path_XARGS+:} false; then : 13070 $as_echo_n "(cached) " >&6 13071 else 13072 case $XARGS in 13073 [\\/]* | ?:[\\/]*) 13074 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13075 ;; 13076 *) 13077 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13078 for as_dir in $PATH 13079 do 13080 IFS=$as_save_IFS 13081 test -z "$as_dir" && as_dir=. 13082 for ac_exec_ext in '' $ac_executable_extensions; do 13083 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13084 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13085 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13086 break 2 13087 fi 13088 done 13089 done 13090 IFS=$as_save_IFS 13091 13092 ;; 13093 esac 13094 fi 13095 XARGS=$ac_cv_path_XARGS 13096 if test -n "$XARGS"; then 13097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13098 $as_echo "$XARGS" >&6; } 13099 else 13100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13101 $as_echo "no" >&6; } 13102 fi 13103 13104 13105 if test "x$XARGS" = x; then 13106 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13107 fi 13108 else 13109 # Otherwise we believe it is a complete path. Use it as it is. 13110 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5 13111 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;} 13112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13113 $as_echo_n "checking for XARGS... " >&6; } 13114 if test ! -x "$tool_specified"; then 13115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13116 $as_echo "not found" >&6; } 13117 as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5 13118 fi 13119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13120 $as_echo "$tool_specified" >&6; } 13121 fi 13122 fi 13123 fi 13124 13125 fi 13126 13127 13128 13129 if test "x$XARGS" = x; then 13130 as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5 13131 fi 13132 13133 13134 13135 # Then required tools that require some special treatment. 13136 13137 13138 # Publish this variable in the help. 13139 13140 13141 if [ -z "${AWK+x}" ]; then 13142 # The variable is not set by user, try to locate tool using the code snippet 13143 for ac_prog in gawk mawk nawk awk 13144 do 13145 # Extract the first word of "$ac_prog", so it can be a program name with args. 13146 set dummy $ac_prog; ac_word=$2 13147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13148 $as_echo_n "checking for $ac_word... " >&6; } 13149 if ${ac_cv_prog_AWK+:} false; then : 13150 $as_echo_n "(cached) " >&6 13151 else 13152 if test -n "$AWK"; then 13153 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13154 else 13155 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13156 for as_dir in $PATH 13157 do 13158 IFS=$as_save_IFS 13159 test -z "$as_dir" && as_dir=. 13160 for ac_exec_ext in '' $ac_executable_extensions; do 13161 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13162 ac_cv_prog_AWK="$ac_prog" 13163 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13164 break 2 13165 fi 13166 done 13167 done 13168 IFS=$as_save_IFS 13169 13170 fi 13171 fi 13172 AWK=$ac_cv_prog_AWK 13173 if test -n "$AWK"; then 13174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13175 $as_echo "$AWK" >&6; } 13176 else 13177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13178 $as_echo "no" >&6; } 13179 fi 13180 13181 13182 test -n "$AWK" && break 13183 done 13184 13185 else 13186 # The variable is set, but is it from the command line or the environment? 13187 13188 # Try to remove the string !AWK! from our list. 13189 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/} 13190 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13191 # If it failed, the variable was not from the command line. Ignore it, 13192 # but warn the user (except for BASH, which is always set by the calling BASH). 13193 if test "xAWK" != xBASH; then 13194 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5 13195 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;} 13196 fi 13197 # Try to locate tool using the code snippet 13198 for ac_prog in gawk mawk nawk awk 13199 do 13200 # Extract the first word of "$ac_prog", so it can be a program name with args. 13201 set dummy $ac_prog; ac_word=$2 13202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13203 $as_echo_n "checking for $ac_word... " >&6; } 13204 if ${ac_cv_prog_AWK+:} false; then : 13205 $as_echo_n "(cached) " >&6 13206 else 13207 if test -n "$AWK"; then 13208 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13209 else 13210 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13211 for as_dir in $PATH 13212 do 13213 IFS=$as_save_IFS 13214 test -z "$as_dir" && as_dir=. 13215 for ac_exec_ext in '' $ac_executable_extensions; do 13216 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13217 ac_cv_prog_AWK="$ac_prog" 13218 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13219 break 2 13220 fi 13221 done 13222 done 13223 IFS=$as_save_IFS 13224 13225 fi 13226 fi 13227 AWK=$ac_cv_prog_AWK 13228 if test -n "$AWK"; then 13229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13230 $as_echo "$AWK" >&6; } 13231 else 13232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13233 $as_echo "no" >&6; } 13234 fi 13235 13236 13237 test -n "$AWK" && break 13238 done 13239 13240 else 13241 # If it succeeded, then it was overridden by the user. We will use it 13242 # for the tool. 13243 13244 # First remove it from the list of overridden variables, so we can test 13245 # for unknown variables in the end. 13246 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13247 13248 # Check if we try to supply an empty value 13249 if test "x$AWK" = x; then 13250 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AWK= (no value)" >&5 13251 $as_echo "$as_me: Setting user supplied tool AWK= (no value)" >&6;} 13252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13253 $as_echo_n "checking for AWK... " >&6; } 13254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13255 $as_echo "disabled" >&6; } 13256 else 13257 # Check if the provided tool contains a complete path. 13258 tool_specified="$AWK" 13259 tool_basename="${tool_specified##*/}" 13260 if test "x$tool_basename" = "x$tool_specified"; then 13261 # A command without a complete path is provided, search $PATH. 13262 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5 13263 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;} 13264 # Extract the first word of "$tool_basename", so it can be a program name with args. 13265 set dummy $tool_basename; ac_word=$2 13266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13267 $as_echo_n "checking for $ac_word... " >&6; } 13268 if ${ac_cv_path_AWK+:} false; then : 13269 $as_echo_n "(cached) " >&6 13270 else 13271 case $AWK in 13272 [\\/]* | ?:[\\/]*) 13273 ac_cv_path_AWK="$AWK" # Let the user override the test with a path. 13274 ;; 13275 *) 13276 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13277 for as_dir in $PATH 13278 do 13279 IFS=$as_save_IFS 13280 test -z "$as_dir" && as_dir=. 13281 for ac_exec_ext in '' $ac_executable_extensions; do 13282 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13283 ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext" 13284 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13285 break 2 13286 fi 13287 done 13288 done 13289 IFS=$as_save_IFS 13290 13291 ;; 13292 esac 13293 fi 13294 AWK=$ac_cv_path_AWK 13295 if test -n "$AWK"; then 13296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13297 $as_echo "$AWK" >&6; } 13298 else 13299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13300 $as_echo "no" >&6; } 13301 fi 13302 13303 13304 if test "x$AWK" = x; then 13305 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13306 fi 13307 else 13308 # Otherwise we believe it is a complete path. Use it as it is. 13309 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5 13310 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;} 13311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13312 $as_echo_n "checking for AWK... " >&6; } 13313 if test ! -x "$tool_specified"; then 13314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13315 $as_echo "not found" >&6; } 13316 as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5 13317 fi 13318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13319 $as_echo "$tool_specified" >&6; } 13320 fi 13321 fi 13322 fi 13323 13324 fi 13325 13326 13327 if test "x$AWK" = x; then 13328 as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5 13329 fi 13330 13331 13332 13333 13334 # Publish this variable in the help. 13335 13336 13337 if [ -z "${GREP+x}" ]; then 13338 # The variable is not set by user, try to locate tool using the code snippet 13339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13340 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13341 if ${ac_cv_path_GREP+:} false; then : 13342 $as_echo_n "(cached) " >&6 13343 else 13344 if test -z "$GREP"; then 13345 ac_path_GREP_found=false 13346 # Loop through the user's path and test for each of PROGNAME-LIST 13347 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13348 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13349 do 13350 IFS=$as_save_IFS 13351 test -z "$as_dir" && as_dir=. 13352 for ac_prog in grep ggrep; do 13353 for ac_exec_ext in '' $ac_executable_extensions; do 13354 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13355 as_fn_executable_p "$ac_path_GREP" || continue 13356 # Check for GNU ac_path_GREP and select it if it is found. 13357 # Check for GNU $ac_path_GREP 13358 case `"$ac_path_GREP" --version 2>&1` in 13359 *GNU*) 13360 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13361 *) 13362 ac_count=0 13363 $as_echo_n 0123456789 >"conftest.in" 13364 while : 13365 do 13366 cat "conftest.in" "conftest.in" >"conftest.tmp" 13367 mv "conftest.tmp" "conftest.in" 13368 cp "conftest.in" "conftest.nl" 13369 $as_echo 'GREP' >> "conftest.nl" 13370 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13371 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13372 as_fn_arith $ac_count + 1 && ac_count=$as_val 13373 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13374 # Best one so far, save it but keep looking for a better one 13375 ac_cv_path_GREP="$ac_path_GREP" 13376 ac_path_GREP_max=$ac_count 13377 fi 13378 # 10*(2^10) chars as input seems more than enough 13379 test $ac_count -gt 10 && break 13380 done 13381 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13382 esac 13383 13384 $ac_path_GREP_found && break 3 13385 done 13386 done 13387 done 13388 IFS=$as_save_IFS 13389 if test -z "$ac_cv_path_GREP"; then 13390 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13391 fi 13392 else 13393 ac_cv_path_GREP=$GREP 13394 fi 13395 13396 fi 13397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13398 $as_echo "$ac_cv_path_GREP" >&6; } 13399 GREP="$ac_cv_path_GREP" 13400 13401 13402 else 13403 # The variable is set, but is it from the command line or the environment? 13404 13405 # Try to remove the string !GREP! from our list. 13406 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/} 13407 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13408 # If it failed, the variable was not from the command line. Ignore it, 13409 # but warn the user (except for BASH, which is always set by the calling BASH). 13410 if test "xGREP" != xBASH; then 13411 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5 13412 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;} 13413 fi 13414 # Try to locate tool using the code snippet 13415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13416 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13417 if ${ac_cv_path_GREP+:} false; then : 13418 $as_echo_n "(cached) " >&6 13419 else 13420 if test -z "$GREP"; then 13421 ac_path_GREP_found=false 13422 # Loop through the user's path and test for each of PROGNAME-LIST 13423 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13424 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13425 do 13426 IFS=$as_save_IFS 13427 test -z "$as_dir" && as_dir=. 13428 for ac_prog in grep ggrep; do 13429 for ac_exec_ext in '' $ac_executable_extensions; do 13430 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13431 as_fn_executable_p "$ac_path_GREP" || continue 13432 # Check for GNU ac_path_GREP and select it if it is found. 13433 # Check for GNU $ac_path_GREP 13434 case `"$ac_path_GREP" --version 2>&1` in 13435 *GNU*) 13436 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13437 *) 13438 ac_count=0 13439 $as_echo_n 0123456789 >"conftest.in" 13440 while : 13441 do 13442 cat "conftest.in" "conftest.in" >"conftest.tmp" 13443 mv "conftest.tmp" "conftest.in" 13444 cp "conftest.in" "conftest.nl" 13445 $as_echo 'GREP' >> "conftest.nl" 13446 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13447 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13448 as_fn_arith $ac_count + 1 && ac_count=$as_val 13449 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13450 # Best one so far, save it but keep looking for a better one 13451 ac_cv_path_GREP="$ac_path_GREP" 13452 ac_path_GREP_max=$ac_count 13453 fi 13454 # 10*(2^10) chars as input seems more than enough 13455 test $ac_count -gt 10 && break 13456 done 13457 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13458 esac 13459 13460 $ac_path_GREP_found && break 3 13461 done 13462 done 13463 done 13464 IFS=$as_save_IFS 13465 if test -z "$ac_cv_path_GREP"; then 13466 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13467 fi 13468 else 13469 ac_cv_path_GREP=$GREP 13470 fi 13471 13472 fi 13473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13474 $as_echo "$ac_cv_path_GREP" >&6; } 13475 GREP="$ac_cv_path_GREP" 13476 13477 13478 else 13479 # If it succeeded, then it was overridden by the user. We will use it 13480 # for the tool. 13481 13482 # First remove it from the list of overridden variables, so we can test 13483 # for unknown variables in the end. 13484 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13485 13486 # Check if we try to supply an empty value 13487 if test "x$GREP" = x; then 13488 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GREP= (no value)" >&5 13489 $as_echo "$as_me: Setting user supplied tool GREP= (no value)" >&6;} 13490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13491 $as_echo_n "checking for GREP... " >&6; } 13492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13493 $as_echo "disabled" >&6; } 13494 else 13495 # Check if the provided tool contains a complete path. 13496 tool_specified="$GREP" 13497 tool_basename="${tool_specified##*/}" 13498 if test "x$tool_basename" = "x$tool_specified"; then 13499 # A command without a complete path is provided, search $PATH. 13500 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5 13501 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;} 13502 # Extract the first word of "$tool_basename", so it can be a program name with args. 13503 set dummy $tool_basename; ac_word=$2 13504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13505 $as_echo_n "checking for $ac_word... " >&6; } 13506 if ${ac_cv_path_GREP+:} false; then : 13507 $as_echo_n "(cached) " >&6 13508 else 13509 case $GREP in 13510 [\\/]* | ?:[\\/]*) 13511 ac_cv_path_GREP="$GREP" # Let the user override the test with a path. 13512 ;; 13513 *) 13514 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13515 for as_dir in $PATH 13516 do 13517 IFS=$as_save_IFS 13518 test -z "$as_dir" && as_dir=. 13519 for ac_exec_ext in '' $ac_executable_extensions; do 13520 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13521 ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext" 13522 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13523 break 2 13524 fi 13525 done 13526 done 13527 IFS=$as_save_IFS 13528 13529 ;; 13530 esac 13531 fi 13532 GREP=$ac_cv_path_GREP 13533 if test -n "$GREP"; then 13534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5 13535 $as_echo "$GREP" >&6; } 13536 else 13537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13538 $as_echo "no" >&6; } 13539 fi 13540 13541 13542 if test "x$GREP" = x; then 13543 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13544 fi 13545 else 13546 # Otherwise we believe it is a complete path. Use it as it is. 13547 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5 13548 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;} 13549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13550 $as_echo_n "checking for GREP... " >&6; } 13551 if test ! -x "$tool_specified"; then 13552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13553 $as_echo "not found" >&6; } 13554 as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13555 fi 13556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13557 $as_echo "$tool_specified" >&6; } 13558 fi 13559 fi 13560 fi 13561 13562 fi 13563 13564 13565 if test "x$GREP" = x; then 13566 as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5 13567 fi 13568 13569 13570 13571 13572 # Publish this variable in the help. 13573 13574 13575 if [ -z "${EGREP+x}" ]; then 13576 # The variable is not set by user, try to locate tool using the code snippet 13577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13578 $as_echo_n "checking for egrep... " >&6; } 13579 if ${ac_cv_path_EGREP+:} false; then : 13580 $as_echo_n "(cached) " >&6 13581 else 13582 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13583 then ac_cv_path_EGREP="$GREP -E" 13584 else 13585 if test -z "$EGREP"; then 13586 ac_path_EGREP_found=false 13587 # Loop through the user's path and test for each of PROGNAME-LIST 13588 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13589 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13590 do 13591 IFS=$as_save_IFS 13592 test -z "$as_dir" && as_dir=. 13593 for ac_prog in egrep; do 13594 for ac_exec_ext in '' $ac_executable_extensions; do 13595 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13596 as_fn_executable_p "$ac_path_EGREP" || continue 13597 # Check for GNU ac_path_EGREP and select it if it is found. 13598 # Check for GNU $ac_path_EGREP 13599 case `"$ac_path_EGREP" --version 2>&1` in 13600 *GNU*) 13601 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13602 *) 13603 ac_count=0 13604 $as_echo_n 0123456789 >"conftest.in" 13605 while : 13606 do 13607 cat "conftest.in" "conftest.in" >"conftest.tmp" 13608 mv "conftest.tmp" "conftest.in" 13609 cp "conftest.in" "conftest.nl" 13610 $as_echo 'EGREP' >> "conftest.nl" 13611 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13612 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13613 as_fn_arith $ac_count + 1 && ac_count=$as_val 13614 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13615 # Best one so far, save it but keep looking for a better one 13616 ac_cv_path_EGREP="$ac_path_EGREP" 13617 ac_path_EGREP_max=$ac_count 13618 fi 13619 # 10*(2^10) chars as input seems more than enough 13620 test $ac_count -gt 10 && break 13621 done 13622 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13623 esac 13624 13625 $ac_path_EGREP_found && break 3 13626 done 13627 done 13628 done 13629 IFS=$as_save_IFS 13630 if test -z "$ac_cv_path_EGREP"; then 13631 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13632 fi 13633 else 13634 ac_cv_path_EGREP=$EGREP 13635 fi 13636 13637 fi 13638 fi 13639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13640 $as_echo "$ac_cv_path_EGREP" >&6; } 13641 EGREP="$ac_cv_path_EGREP" 13642 13643 13644 else 13645 # The variable is set, but is it from the command line or the environment? 13646 13647 # Try to remove the string !EGREP! from our list. 13648 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/} 13649 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13650 # If it failed, the variable was not from the command line. Ignore it, 13651 # but warn the user (except for BASH, which is always set by the calling BASH). 13652 if test "xEGREP" != xBASH; then 13653 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5 13654 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;} 13655 fi 13656 # Try to locate tool using the code snippet 13657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13658 $as_echo_n "checking for egrep... " >&6; } 13659 if ${ac_cv_path_EGREP+:} false; then : 13660 $as_echo_n "(cached) " >&6 13661 else 13662 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13663 then ac_cv_path_EGREP="$GREP -E" 13664 else 13665 if test -z "$EGREP"; then 13666 ac_path_EGREP_found=false 13667 # Loop through the user's path and test for each of PROGNAME-LIST 13668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13669 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13670 do 13671 IFS=$as_save_IFS 13672 test -z "$as_dir" && as_dir=. 13673 for ac_prog in egrep; do 13674 for ac_exec_ext in '' $ac_executable_extensions; do 13675 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13676 as_fn_executable_p "$ac_path_EGREP" || continue 13677 # Check for GNU ac_path_EGREP and select it if it is found. 13678 # Check for GNU $ac_path_EGREP 13679 case `"$ac_path_EGREP" --version 2>&1` in 13680 *GNU*) 13681 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13682 *) 13683 ac_count=0 13684 $as_echo_n 0123456789 >"conftest.in" 13685 while : 13686 do 13687 cat "conftest.in" "conftest.in" >"conftest.tmp" 13688 mv "conftest.tmp" "conftest.in" 13689 cp "conftest.in" "conftest.nl" 13690 $as_echo 'EGREP' >> "conftest.nl" 13691 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13692 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13693 as_fn_arith $ac_count + 1 && ac_count=$as_val 13694 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13695 # Best one so far, save it but keep looking for a better one 13696 ac_cv_path_EGREP="$ac_path_EGREP" 13697 ac_path_EGREP_max=$ac_count 13698 fi 13699 # 10*(2^10) chars as input seems more than enough 13700 test $ac_count -gt 10 && break 13701 done 13702 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13703 esac 13704 13705 $ac_path_EGREP_found && break 3 13706 done 13707 done 13708 done 13709 IFS=$as_save_IFS 13710 if test -z "$ac_cv_path_EGREP"; then 13711 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13712 fi 13713 else 13714 ac_cv_path_EGREP=$EGREP 13715 fi 13716 13717 fi 13718 fi 13719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13720 $as_echo "$ac_cv_path_EGREP" >&6; } 13721 EGREP="$ac_cv_path_EGREP" 13722 13723 13724 else 13725 # If it succeeded, then it was overridden by the user. We will use it 13726 # for the tool. 13727 13728 # First remove it from the list of overridden variables, so we can test 13729 # for unknown variables in the end. 13730 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13731 13732 # Check if we try to supply an empty value 13733 if test "x$EGREP" = x; then 13734 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EGREP= (no value)" >&5 13735 $as_echo "$as_me: Setting user supplied tool EGREP= (no value)" >&6;} 13736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13737 $as_echo_n "checking for EGREP... " >&6; } 13738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13739 $as_echo "disabled" >&6; } 13740 else 13741 # Check if the provided tool contains a complete path. 13742 tool_specified="$EGREP" 13743 tool_basename="${tool_specified##*/}" 13744 if test "x$tool_basename" = "x$tool_specified"; then 13745 # A command without a complete path is provided, search $PATH. 13746 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5 13747 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;} 13748 # Extract the first word of "$tool_basename", so it can be a program name with args. 13749 set dummy $tool_basename; ac_word=$2 13750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13751 $as_echo_n "checking for $ac_word... " >&6; } 13752 if ${ac_cv_path_EGREP+:} false; then : 13753 $as_echo_n "(cached) " >&6 13754 else 13755 case $EGREP in 13756 [\\/]* | ?:[\\/]*) 13757 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path. 13758 ;; 13759 *) 13760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13761 for as_dir in $PATH 13762 do 13763 IFS=$as_save_IFS 13764 test -z "$as_dir" && as_dir=. 13765 for ac_exec_ext in '' $ac_executable_extensions; do 13766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13767 ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext" 13768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13769 break 2 13770 fi 13771 done 13772 done 13773 IFS=$as_save_IFS 13774 13775 ;; 13776 esac 13777 fi 13778 EGREP=$ac_cv_path_EGREP 13779 if test -n "$EGREP"; then 13780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5 13781 $as_echo "$EGREP" >&6; } 13782 else 13783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13784 $as_echo "no" >&6; } 13785 fi 13786 13787 13788 if test "x$EGREP" = x; then 13789 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13790 fi 13791 else 13792 # Otherwise we believe it is a complete path. Use it as it is. 13793 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5 13794 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;} 13795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13796 $as_echo_n "checking for EGREP... " >&6; } 13797 if test ! -x "$tool_specified"; then 13798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13799 $as_echo "not found" >&6; } 13800 as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13801 fi 13802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13803 $as_echo "$tool_specified" >&6; } 13804 fi 13805 fi 13806 fi 13807 13808 fi 13809 13810 13811 if test "x$EGREP" = x; then 13812 as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5 13813 fi 13814 13815 13816 13817 13818 # Publish this variable in the help. 13819 13820 13821 if [ -z "${FGREP+x}" ]; then 13822 # The variable is not set by user, try to locate tool using the code snippet 13823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13824 $as_echo_n "checking for fgrep... " >&6; } 13825 if ${ac_cv_path_FGREP+:} false; then : 13826 $as_echo_n "(cached) " >&6 13827 else 13828 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13829 then ac_cv_path_FGREP="$GREP -F" 13830 else 13831 if test -z "$FGREP"; then 13832 ac_path_FGREP_found=false 13833 # Loop through the user's path and test for each of PROGNAME-LIST 13834 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13835 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13836 do 13837 IFS=$as_save_IFS 13838 test -z "$as_dir" && as_dir=. 13839 for ac_prog in fgrep; do 13840 for ac_exec_ext in '' $ac_executable_extensions; do 13841 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13842 as_fn_executable_p "$ac_path_FGREP" || continue 13843 # Check for GNU ac_path_FGREP and select it if it is found. 13844 # Check for GNU $ac_path_FGREP 13845 case `"$ac_path_FGREP" --version 2>&1` in 13846 *GNU*) 13847 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13848 *) 13849 ac_count=0 13850 $as_echo_n 0123456789 >"conftest.in" 13851 while : 13852 do 13853 cat "conftest.in" "conftest.in" >"conftest.tmp" 13854 mv "conftest.tmp" "conftest.in" 13855 cp "conftest.in" "conftest.nl" 13856 $as_echo 'FGREP' >> "conftest.nl" 13857 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13858 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13859 as_fn_arith $ac_count + 1 && ac_count=$as_val 13860 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13861 # Best one so far, save it but keep looking for a better one 13862 ac_cv_path_FGREP="$ac_path_FGREP" 13863 ac_path_FGREP_max=$ac_count 13864 fi 13865 # 10*(2^10) chars as input seems more than enough 13866 test $ac_count -gt 10 && break 13867 done 13868 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13869 esac 13870 13871 $ac_path_FGREP_found && break 3 13872 done 13873 done 13874 done 13875 IFS=$as_save_IFS 13876 if test -z "$ac_cv_path_FGREP"; then 13877 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13878 fi 13879 else 13880 ac_cv_path_FGREP=$FGREP 13881 fi 13882 13883 fi 13884 fi 13885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13886 $as_echo "$ac_cv_path_FGREP" >&6; } 13887 FGREP="$ac_cv_path_FGREP" 13888 13889 13890 else 13891 # The variable is set, but is it from the command line or the environment? 13892 13893 # Try to remove the string !FGREP! from our list. 13894 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/} 13895 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13896 # If it failed, the variable was not from the command line. Ignore it, 13897 # but warn the user (except for BASH, which is always set by the calling BASH). 13898 if test "xFGREP" != xBASH; then 13899 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5 13900 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;} 13901 fi 13902 # Try to locate tool using the code snippet 13903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13904 $as_echo_n "checking for fgrep... " >&6; } 13905 if ${ac_cv_path_FGREP+:} false; then : 13906 $as_echo_n "(cached) " >&6 13907 else 13908 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13909 then ac_cv_path_FGREP="$GREP -F" 13910 else 13911 if test -z "$FGREP"; then 13912 ac_path_FGREP_found=false 13913 # Loop through the user's path and test for each of PROGNAME-LIST 13914 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13915 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13916 do 13917 IFS=$as_save_IFS 13918 test -z "$as_dir" && as_dir=. 13919 for ac_prog in fgrep; do 13920 for ac_exec_ext in '' $ac_executable_extensions; do 13921 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13922 as_fn_executable_p "$ac_path_FGREP" || continue 13923 # Check for GNU ac_path_FGREP and select it if it is found. 13924 # Check for GNU $ac_path_FGREP 13925 case `"$ac_path_FGREP" --version 2>&1` in 13926 *GNU*) 13927 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13928 *) 13929 ac_count=0 13930 $as_echo_n 0123456789 >"conftest.in" 13931 while : 13932 do 13933 cat "conftest.in" "conftest.in" >"conftest.tmp" 13934 mv "conftest.tmp" "conftest.in" 13935 cp "conftest.in" "conftest.nl" 13936 $as_echo 'FGREP' >> "conftest.nl" 13937 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13938 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13939 as_fn_arith $ac_count + 1 && ac_count=$as_val 13940 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13941 # Best one so far, save it but keep looking for a better one 13942 ac_cv_path_FGREP="$ac_path_FGREP" 13943 ac_path_FGREP_max=$ac_count 13944 fi 13945 # 10*(2^10) chars as input seems more than enough 13946 test $ac_count -gt 10 && break 13947 done 13948 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13949 esac 13950 13951 $ac_path_FGREP_found && break 3 13952 done 13953 done 13954 done 13955 IFS=$as_save_IFS 13956 if test -z "$ac_cv_path_FGREP"; then 13957 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13958 fi 13959 else 13960 ac_cv_path_FGREP=$FGREP 13961 fi 13962 13963 fi 13964 fi 13965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13966 $as_echo "$ac_cv_path_FGREP" >&6; } 13967 FGREP="$ac_cv_path_FGREP" 13968 13969 13970 else 13971 # If it succeeded, then it was overridden by the user. We will use it 13972 # for the tool. 13973 13974 # First remove it from the list of overridden variables, so we can test 13975 # for unknown variables in the end. 13976 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13977 13978 # Check if we try to supply an empty value 13979 if test "x$FGREP" = x; then 13980 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FGREP= (no value)" >&5 13981 $as_echo "$as_me: Setting user supplied tool FGREP= (no value)" >&6;} 13982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 13983 $as_echo_n "checking for FGREP... " >&6; } 13984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13985 $as_echo "disabled" >&6; } 13986 else 13987 # Check if the provided tool contains a complete path. 13988 tool_specified="$FGREP" 13989 tool_basename="${tool_specified##*/}" 13990 if test "x$tool_basename" = "x$tool_specified"; then 13991 # A command without a complete path is provided, search $PATH. 13992 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5 13993 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;} 13994 # Extract the first word of "$tool_basename", so it can be a program name with args. 13995 set dummy $tool_basename; ac_word=$2 13996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13997 $as_echo_n "checking for $ac_word... " >&6; } 13998 if ${ac_cv_path_FGREP+:} false; then : 13999 $as_echo_n "(cached) " >&6 14000 else 14001 case $FGREP in 14002 [\\/]* | ?:[\\/]*) 14003 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path. 14004 ;; 14005 *) 14006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14007 for as_dir in $PATH 14008 do 14009 IFS=$as_save_IFS 14010 test -z "$as_dir" && as_dir=. 14011 for ac_exec_ext in '' $ac_executable_extensions; do 14012 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14013 ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext" 14014 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14015 break 2 14016 fi 14017 done 14018 done 14019 IFS=$as_save_IFS 14020 14021 ;; 14022 esac 14023 fi 14024 FGREP=$ac_cv_path_FGREP 14025 if test -n "$FGREP"; then 14026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5 14027 $as_echo "$FGREP" >&6; } 14028 else 14029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14030 $as_echo "no" >&6; } 14031 fi 14032 14033 14034 if test "x$FGREP" = x; then 14035 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14036 fi 14037 else 14038 # Otherwise we believe it is a complete path. Use it as it is. 14039 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5 14040 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;} 14041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 14042 $as_echo_n "checking for FGREP... " >&6; } 14043 if test ! -x "$tool_specified"; then 14044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14045 $as_echo "not found" >&6; } 14046 as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 14047 fi 14048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14049 $as_echo "$tool_specified" >&6; } 14050 fi 14051 fi 14052 fi 14053 14054 fi 14055 14056 14057 if test "x$FGREP" = x; then 14058 as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5 14059 fi 14060 14061 14062 14063 14064 # Publish this variable in the help. 14065 14066 14067 if [ -z "${SED+x}" ]; then 14068 # The variable is not set by user, try to locate tool using the code snippet 14069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14070 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14071 if ${ac_cv_path_SED+:} false; then : 14072 $as_echo_n "(cached) " >&6 14073 else 14074 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14075 for ac_i in 1 2 3 4 5 6 7; do 14076 ac_script="$ac_script$as_nl$ac_script" 14077 done 14078 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14079 { ac_script=; unset ac_script;} 14080 if test -z "$SED"; then 14081 ac_path_SED_found=false 14082 # Loop through the user's path and test for each of PROGNAME-LIST 14083 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14084 for as_dir in $PATH 14085 do 14086 IFS=$as_save_IFS 14087 test -z "$as_dir" && as_dir=. 14088 for ac_prog in sed gsed; do 14089 for ac_exec_ext in '' $ac_executable_extensions; do 14090 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14091 as_fn_executable_p "$ac_path_SED" || continue 14092 # Check for GNU ac_path_SED and select it if it is found. 14093 # Check for GNU $ac_path_SED 14094 case `"$ac_path_SED" --version 2>&1` in 14095 *GNU*) 14096 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14097 *) 14098 ac_count=0 14099 $as_echo_n 0123456789 >"conftest.in" 14100 while : 14101 do 14102 cat "conftest.in" "conftest.in" >"conftest.tmp" 14103 mv "conftest.tmp" "conftest.in" 14104 cp "conftest.in" "conftest.nl" 14105 $as_echo '' >> "conftest.nl" 14106 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14107 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14108 as_fn_arith $ac_count + 1 && ac_count=$as_val 14109 if test $ac_count -gt ${ac_path_SED_max-0}; then 14110 # Best one so far, save it but keep looking for a better one 14111 ac_cv_path_SED="$ac_path_SED" 14112 ac_path_SED_max=$ac_count 14113 fi 14114 # 10*(2^10) chars as input seems more than enough 14115 test $ac_count -gt 10 && break 14116 done 14117 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14118 esac 14119 14120 $ac_path_SED_found && break 3 14121 done 14122 done 14123 done 14124 IFS=$as_save_IFS 14125 if test -z "$ac_cv_path_SED"; then 14126 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14127 fi 14128 else 14129 ac_cv_path_SED=$SED 14130 fi 14131 14132 fi 14133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14134 $as_echo "$ac_cv_path_SED" >&6; } 14135 SED="$ac_cv_path_SED" 14136 rm -f conftest.sed 14137 14138 else 14139 # The variable is set, but is it from the command line or the environment? 14140 14141 # Try to remove the string !SED! from our list. 14142 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/} 14143 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14144 # If it failed, the variable was not from the command line. Ignore it, 14145 # but warn the user (except for BASH, which is always set by the calling BASH). 14146 if test "xSED" != xBASH; then 14147 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5 14148 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;} 14149 fi 14150 # Try to locate tool using the code snippet 14151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14152 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14153 if ${ac_cv_path_SED+:} false; then : 14154 $as_echo_n "(cached) " >&6 14155 else 14156 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14157 for ac_i in 1 2 3 4 5 6 7; do 14158 ac_script="$ac_script$as_nl$ac_script" 14159 done 14160 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14161 { ac_script=; unset ac_script;} 14162 if test -z "$SED"; then 14163 ac_path_SED_found=false 14164 # Loop through the user's path and test for each of PROGNAME-LIST 14165 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14166 for as_dir in $PATH 14167 do 14168 IFS=$as_save_IFS 14169 test -z "$as_dir" && as_dir=. 14170 for ac_prog in sed gsed; do 14171 for ac_exec_ext in '' $ac_executable_extensions; do 14172 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14173 as_fn_executable_p "$ac_path_SED" || continue 14174 # Check for GNU ac_path_SED and select it if it is found. 14175 # Check for GNU $ac_path_SED 14176 case `"$ac_path_SED" --version 2>&1` in 14177 *GNU*) 14178 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14179 *) 14180 ac_count=0 14181 $as_echo_n 0123456789 >"conftest.in" 14182 while : 14183 do 14184 cat "conftest.in" "conftest.in" >"conftest.tmp" 14185 mv "conftest.tmp" "conftest.in" 14186 cp "conftest.in" "conftest.nl" 14187 $as_echo '' >> "conftest.nl" 14188 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14189 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14190 as_fn_arith $ac_count + 1 && ac_count=$as_val 14191 if test $ac_count -gt ${ac_path_SED_max-0}; then 14192 # Best one so far, save it but keep looking for a better one 14193 ac_cv_path_SED="$ac_path_SED" 14194 ac_path_SED_max=$ac_count 14195 fi 14196 # 10*(2^10) chars as input seems more than enough 14197 test $ac_count -gt 10 && break 14198 done 14199 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14200 esac 14201 14202 $ac_path_SED_found && break 3 14203 done 14204 done 14205 done 14206 IFS=$as_save_IFS 14207 if test -z "$ac_cv_path_SED"; then 14208 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14209 fi 14210 else 14211 ac_cv_path_SED=$SED 14212 fi 14213 14214 fi 14215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14216 $as_echo "$ac_cv_path_SED" >&6; } 14217 SED="$ac_cv_path_SED" 14218 rm -f conftest.sed 14219 14220 else 14221 # If it succeeded, then it was overridden by the user. We will use it 14222 # for the tool. 14223 14224 # First remove it from the list of overridden variables, so we can test 14225 # for unknown variables in the end. 14226 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14227 14228 # Check if we try to supply an empty value 14229 if test "x$SED" = x; then 14230 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SED= (no value)" >&5 14231 $as_echo "$as_me: Setting user supplied tool SED= (no value)" >&6;} 14232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14233 $as_echo_n "checking for SED... " >&6; } 14234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14235 $as_echo "disabled" >&6; } 14236 else 14237 # Check if the provided tool contains a complete path. 14238 tool_specified="$SED" 14239 tool_basename="${tool_specified##*/}" 14240 if test "x$tool_basename" = "x$tool_specified"; then 14241 # A command without a complete path is provided, search $PATH. 14242 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5 14243 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;} 14244 # Extract the first word of "$tool_basename", so it can be a program name with args. 14245 set dummy $tool_basename; ac_word=$2 14246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14247 $as_echo_n "checking for $ac_word... " >&6; } 14248 if ${ac_cv_path_SED+:} false; then : 14249 $as_echo_n "(cached) " >&6 14250 else 14251 case $SED in 14252 [\\/]* | ?:[\\/]*) 14253 ac_cv_path_SED="$SED" # Let the user override the test with a path. 14254 ;; 14255 *) 14256 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14257 for as_dir in $PATH 14258 do 14259 IFS=$as_save_IFS 14260 test -z "$as_dir" && as_dir=. 14261 for ac_exec_ext in '' $ac_executable_extensions; do 14262 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14263 ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext" 14264 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14265 break 2 14266 fi 14267 done 14268 done 14269 IFS=$as_save_IFS 14270 14271 ;; 14272 esac 14273 fi 14274 SED=$ac_cv_path_SED 14275 if test -n "$SED"; then 14276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 14277 $as_echo "$SED" >&6; } 14278 else 14279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14280 $as_echo "no" >&6; } 14281 fi 14282 14283 14284 if test "x$SED" = x; then 14285 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14286 fi 14287 else 14288 # Otherwise we believe it is a complete path. Use it as it is. 14289 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5 14290 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;} 14291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14292 $as_echo_n "checking for SED... " >&6; } 14293 if test ! -x "$tool_specified"; then 14294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14295 $as_echo "not found" >&6; } 14296 as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5 14297 fi 14298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14299 $as_echo "$tool_specified" >&6; } 14300 fi 14301 fi 14302 fi 14303 14304 fi 14305 14306 14307 if test "x$SED" = x; then 14308 as_fn_error $? "Could not find required tool for SED" "$LINENO" 5 14309 fi 14310 14311 14312 14313 # Always force rm. 14314 RM="$RM -f" 14315 14316 # pwd behaves differently on various platforms and some don't support the -L flag. 14317 # Always use the bash builtin pwd to get uniform behavior. 14318 THEPWDCMD=pwd 14319 14320 # These are not required on all platforms 14321 14322 14323 # Publish this variable in the help. 14324 14325 14326 if [ -z "${CYGPATH+x}" ]; then 14327 # The variable is not set by user, try to locate tool using the code snippet 14328 for ac_prog in cygpath 14329 do 14330 # Extract the first word of "$ac_prog", so it can be a program name with args. 14331 set dummy $ac_prog; ac_word=$2 14332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14333 $as_echo_n "checking for $ac_word... " >&6; } 14334 if ${ac_cv_path_CYGPATH+:} false; then : 14335 $as_echo_n "(cached) " >&6 14336 else 14337 case $CYGPATH in 14338 [\\/]* | ?:[\\/]*) 14339 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14340 ;; 14341 *) 14342 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14343 for as_dir in $PATH 14344 do 14345 IFS=$as_save_IFS 14346 test -z "$as_dir" && as_dir=. 14347 for ac_exec_ext in '' $ac_executable_extensions; do 14348 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14349 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14350 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14351 break 2 14352 fi 14353 done 14354 done 14355 IFS=$as_save_IFS 14356 14357 ;; 14358 esac 14359 fi 14360 CYGPATH=$ac_cv_path_CYGPATH 14361 if test -n "$CYGPATH"; then 14362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14363 $as_echo "$CYGPATH" >&6; } 14364 else 14365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14366 $as_echo "no" >&6; } 14367 fi 14368 14369 14370 test -n "$CYGPATH" && break 14371 done 14372 14373 else 14374 # The variable is set, but is it from the command line or the environment? 14375 14376 # Try to remove the string !CYGPATH! from our list. 14377 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/} 14378 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14379 # If it failed, the variable was not from the command line. Ignore it, 14380 # but warn the user (except for BASH, which is always set by the calling BASH). 14381 if test "xCYGPATH" != xBASH; then 14382 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5 14383 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;} 14384 fi 14385 # Try to locate tool using the code snippet 14386 for ac_prog in cygpath 14387 do 14388 # Extract the first word of "$ac_prog", so it can be a program name with args. 14389 set dummy $ac_prog; ac_word=$2 14390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14391 $as_echo_n "checking for $ac_word... " >&6; } 14392 if ${ac_cv_path_CYGPATH+:} false; then : 14393 $as_echo_n "(cached) " >&6 14394 else 14395 case $CYGPATH in 14396 [\\/]* | ?:[\\/]*) 14397 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14398 ;; 14399 *) 14400 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14401 for as_dir in $PATH 14402 do 14403 IFS=$as_save_IFS 14404 test -z "$as_dir" && as_dir=. 14405 for ac_exec_ext in '' $ac_executable_extensions; do 14406 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14407 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14408 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14409 break 2 14410 fi 14411 done 14412 done 14413 IFS=$as_save_IFS 14414 14415 ;; 14416 esac 14417 fi 14418 CYGPATH=$ac_cv_path_CYGPATH 14419 if test -n "$CYGPATH"; then 14420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14421 $as_echo "$CYGPATH" >&6; } 14422 else 14423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14424 $as_echo "no" >&6; } 14425 fi 14426 14427 14428 test -n "$CYGPATH" && break 14429 done 14430 14431 else 14432 # If it succeeded, then it was overridden by the user. We will use it 14433 # for the tool. 14434 14435 # First remove it from the list of overridden variables, so we can test 14436 # for unknown variables in the end. 14437 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14438 14439 # Check if we try to supply an empty value 14440 if test "x$CYGPATH" = x; then 14441 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CYGPATH= (no value)" >&5 14442 $as_echo "$as_me: Setting user supplied tool CYGPATH= (no value)" >&6;} 14443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14444 $as_echo_n "checking for CYGPATH... " >&6; } 14445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14446 $as_echo "disabled" >&6; } 14447 else 14448 # Check if the provided tool contains a complete path. 14449 tool_specified="$CYGPATH" 14450 tool_basename="${tool_specified##*/}" 14451 if test "x$tool_basename" = "x$tool_specified"; then 14452 # A command without a complete path is provided, search $PATH. 14453 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5 14454 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;} 14455 # Extract the first word of "$tool_basename", so it can be a program name with args. 14456 set dummy $tool_basename; ac_word=$2 14457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14458 $as_echo_n "checking for $ac_word... " >&6; } 14459 if ${ac_cv_path_CYGPATH+:} false; then : 14460 $as_echo_n "(cached) " >&6 14461 else 14462 case $CYGPATH in 14463 [\\/]* | ?:[\\/]*) 14464 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14465 ;; 14466 *) 14467 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14468 for as_dir in $PATH 14469 do 14470 IFS=$as_save_IFS 14471 test -z "$as_dir" && as_dir=. 14472 for ac_exec_ext in '' $ac_executable_extensions; do 14473 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14474 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14475 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14476 break 2 14477 fi 14478 done 14479 done 14480 IFS=$as_save_IFS 14481 14482 ;; 14483 esac 14484 fi 14485 CYGPATH=$ac_cv_path_CYGPATH 14486 if test -n "$CYGPATH"; then 14487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14488 $as_echo "$CYGPATH" >&6; } 14489 else 14490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14491 $as_echo "no" >&6; } 14492 fi 14493 14494 14495 if test "x$CYGPATH" = x; then 14496 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14497 fi 14498 else 14499 # Otherwise we believe it is a complete path. Use it as it is. 14500 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5 14501 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;} 14502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14503 $as_echo_n "checking for CYGPATH... " >&6; } 14504 if test ! -x "$tool_specified"; then 14505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14506 $as_echo "not found" >&6; } 14507 as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5 14508 fi 14509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14510 $as_echo "$tool_specified" >&6; } 14511 fi 14512 fi 14513 fi 14514 14515 fi 14516 14517 14518 14519 14520 # Publish this variable in the help. 14521 14522 14523 if [ -z "${READLINK+x}" ]; then 14524 # The variable is not set by user, try to locate tool using the code snippet 14525 for ac_prog in greadlink readlink 14526 do 14527 # Extract the first word of "$ac_prog", so it can be a program name with args. 14528 set dummy $ac_prog; ac_word=$2 14529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14530 $as_echo_n "checking for $ac_word... " >&6; } 14531 if ${ac_cv_path_READLINK+:} false; then : 14532 $as_echo_n "(cached) " >&6 14533 else 14534 case $READLINK in 14535 [\\/]* | ?:[\\/]*) 14536 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14537 ;; 14538 *) 14539 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14540 for as_dir in $PATH 14541 do 14542 IFS=$as_save_IFS 14543 test -z "$as_dir" && as_dir=. 14544 for ac_exec_ext in '' $ac_executable_extensions; do 14545 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14546 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14547 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14548 break 2 14549 fi 14550 done 14551 done 14552 IFS=$as_save_IFS 14553 14554 ;; 14555 esac 14556 fi 14557 READLINK=$ac_cv_path_READLINK 14558 if test -n "$READLINK"; then 14559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14560 $as_echo "$READLINK" >&6; } 14561 else 14562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14563 $as_echo "no" >&6; } 14564 fi 14565 14566 14567 test -n "$READLINK" && break 14568 done 14569 14570 else 14571 # The variable is set, but is it from the command line or the environment? 14572 14573 # Try to remove the string !READLINK! from our list. 14574 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/} 14575 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14576 # If it failed, the variable was not from the command line. Ignore it, 14577 # but warn the user (except for BASH, which is always set by the calling BASH). 14578 if test "xREADLINK" != xBASH; then 14579 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5 14580 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;} 14581 fi 14582 # Try to locate tool using the code snippet 14583 for ac_prog in greadlink readlink 14584 do 14585 # Extract the first word of "$ac_prog", so it can be a program name with args. 14586 set dummy $ac_prog; ac_word=$2 14587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14588 $as_echo_n "checking for $ac_word... " >&6; } 14589 if ${ac_cv_path_READLINK+:} false; then : 14590 $as_echo_n "(cached) " >&6 14591 else 14592 case $READLINK in 14593 [\\/]* | ?:[\\/]*) 14594 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14595 ;; 14596 *) 14597 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14598 for as_dir in $PATH 14599 do 14600 IFS=$as_save_IFS 14601 test -z "$as_dir" && as_dir=. 14602 for ac_exec_ext in '' $ac_executable_extensions; do 14603 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14604 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14605 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14606 break 2 14607 fi 14608 done 14609 done 14610 IFS=$as_save_IFS 14611 14612 ;; 14613 esac 14614 fi 14615 READLINK=$ac_cv_path_READLINK 14616 if test -n "$READLINK"; then 14617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14618 $as_echo "$READLINK" >&6; } 14619 else 14620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14621 $as_echo "no" >&6; } 14622 fi 14623 14624 14625 test -n "$READLINK" && break 14626 done 14627 14628 else 14629 # If it succeeded, then it was overridden by the user. We will use it 14630 # for the tool. 14631 14632 # First remove it from the list of overridden variables, so we can test 14633 # for unknown variables in the end. 14634 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14635 14636 # Check if we try to supply an empty value 14637 if test "x$READLINK" = x; then 14638 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READLINK= (no value)" >&5 14639 $as_echo "$as_me: Setting user supplied tool READLINK= (no value)" >&6;} 14640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14641 $as_echo_n "checking for READLINK... " >&6; } 14642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14643 $as_echo "disabled" >&6; } 14644 else 14645 # Check if the provided tool contains a complete path. 14646 tool_specified="$READLINK" 14647 tool_basename="${tool_specified##*/}" 14648 if test "x$tool_basename" = "x$tool_specified"; then 14649 # A command without a complete path is provided, search $PATH. 14650 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5 14651 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;} 14652 # Extract the first word of "$tool_basename", so it can be a program name with args. 14653 set dummy $tool_basename; ac_word=$2 14654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14655 $as_echo_n "checking for $ac_word... " >&6; } 14656 if ${ac_cv_path_READLINK+:} false; then : 14657 $as_echo_n "(cached) " >&6 14658 else 14659 case $READLINK in 14660 [\\/]* | ?:[\\/]*) 14661 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14662 ;; 14663 *) 14664 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14665 for as_dir in $PATH 14666 do 14667 IFS=$as_save_IFS 14668 test -z "$as_dir" && as_dir=. 14669 for ac_exec_ext in '' $ac_executable_extensions; do 14670 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14671 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14672 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14673 break 2 14674 fi 14675 done 14676 done 14677 IFS=$as_save_IFS 14678 14679 ;; 14680 esac 14681 fi 14682 READLINK=$ac_cv_path_READLINK 14683 if test -n "$READLINK"; then 14684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14685 $as_echo "$READLINK" >&6; } 14686 else 14687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14688 $as_echo "no" >&6; } 14689 fi 14690 14691 14692 if test "x$READLINK" = x; then 14693 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14694 fi 14695 else 14696 # Otherwise we believe it is a complete path. Use it as it is. 14697 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5 14698 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;} 14699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14700 $as_echo_n "checking for READLINK... " >&6; } 14701 if test ! -x "$tool_specified"; then 14702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14703 $as_echo "not found" >&6; } 14704 as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5 14705 fi 14706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14707 $as_echo "$tool_specified" >&6; } 14708 fi 14709 fi 14710 fi 14711 14712 fi 14713 14714 14715 14716 14717 # Publish this variable in the help. 14718 14719 14720 if [ -z "${DF+x}" ]; then 14721 # The variable is not set by user, try to locate tool using the code snippet 14722 for ac_prog in df 14723 do 14724 # Extract the first word of "$ac_prog", so it can be a program name with args. 14725 set dummy $ac_prog; ac_word=$2 14726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14727 $as_echo_n "checking for $ac_word... " >&6; } 14728 if ${ac_cv_path_DF+:} false; then : 14729 $as_echo_n "(cached) " >&6 14730 else 14731 case $DF in 14732 [\\/]* | ?:[\\/]*) 14733 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14734 ;; 14735 *) 14736 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14737 for as_dir in $PATH 14738 do 14739 IFS=$as_save_IFS 14740 test -z "$as_dir" && as_dir=. 14741 for ac_exec_ext in '' $ac_executable_extensions; do 14742 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14743 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14744 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14745 break 2 14746 fi 14747 done 14748 done 14749 IFS=$as_save_IFS 14750 14751 ;; 14752 esac 14753 fi 14754 DF=$ac_cv_path_DF 14755 if test -n "$DF"; then 14756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14757 $as_echo "$DF" >&6; } 14758 else 14759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14760 $as_echo "no" >&6; } 14761 fi 14762 14763 14764 test -n "$DF" && break 14765 done 14766 14767 else 14768 # The variable is set, but is it from the command line or the environment? 14769 14770 # Try to remove the string !DF! from our list. 14771 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/} 14772 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14773 # If it failed, the variable was not from the command line. Ignore it, 14774 # but warn the user (except for BASH, which is always set by the calling BASH). 14775 if test "xDF" != xBASH; then 14776 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5 14777 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;} 14778 fi 14779 # Try to locate tool using the code snippet 14780 for ac_prog in df 14781 do 14782 # Extract the first word of "$ac_prog", so it can be a program name with args. 14783 set dummy $ac_prog; ac_word=$2 14784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14785 $as_echo_n "checking for $ac_word... " >&6; } 14786 if ${ac_cv_path_DF+:} false; then : 14787 $as_echo_n "(cached) " >&6 14788 else 14789 case $DF in 14790 [\\/]* | ?:[\\/]*) 14791 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14792 ;; 14793 *) 14794 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14795 for as_dir in $PATH 14796 do 14797 IFS=$as_save_IFS 14798 test -z "$as_dir" && as_dir=. 14799 for ac_exec_ext in '' $ac_executable_extensions; do 14800 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14801 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14802 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14803 break 2 14804 fi 14805 done 14806 done 14807 IFS=$as_save_IFS 14808 14809 ;; 14810 esac 14811 fi 14812 DF=$ac_cv_path_DF 14813 if test -n "$DF"; then 14814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14815 $as_echo "$DF" >&6; } 14816 else 14817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14818 $as_echo "no" >&6; } 14819 fi 14820 14821 14822 test -n "$DF" && break 14823 done 14824 14825 else 14826 # If it succeeded, then it was overridden by the user. We will use it 14827 # for the tool. 14828 14829 # First remove it from the list of overridden variables, so we can test 14830 # for unknown variables in the end. 14831 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14832 14833 # Check if we try to supply an empty value 14834 if test "x$DF" = x; then 14835 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DF= (no value)" >&5 14836 $as_echo "$as_me: Setting user supplied tool DF= (no value)" >&6;} 14837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14838 $as_echo_n "checking for DF... " >&6; } 14839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14840 $as_echo "disabled" >&6; } 14841 else 14842 # Check if the provided tool contains a complete path. 14843 tool_specified="$DF" 14844 tool_basename="${tool_specified##*/}" 14845 if test "x$tool_basename" = "x$tool_specified"; then 14846 # A command without a complete path is provided, search $PATH. 14847 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5 14848 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;} 14849 # Extract the first word of "$tool_basename", so it can be a program name with args. 14850 set dummy $tool_basename; ac_word=$2 14851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14852 $as_echo_n "checking for $ac_word... " >&6; } 14853 if ${ac_cv_path_DF+:} false; then : 14854 $as_echo_n "(cached) " >&6 14855 else 14856 case $DF in 14857 [\\/]* | ?:[\\/]*) 14858 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14859 ;; 14860 *) 14861 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14862 for as_dir in $PATH 14863 do 14864 IFS=$as_save_IFS 14865 test -z "$as_dir" && as_dir=. 14866 for ac_exec_ext in '' $ac_executable_extensions; do 14867 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14868 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14869 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14870 break 2 14871 fi 14872 done 14873 done 14874 IFS=$as_save_IFS 14875 14876 ;; 14877 esac 14878 fi 14879 DF=$ac_cv_path_DF 14880 if test -n "$DF"; then 14881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14882 $as_echo "$DF" >&6; } 14883 else 14884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14885 $as_echo "no" >&6; } 14886 fi 14887 14888 14889 if test "x$DF" = x; then 14890 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14891 fi 14892 else 14893 # Otherwise we believe it is a complete path. Use it as it is. 14894 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5 14895 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;} 14896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14897 $as_echo_n "checking for DF... " >&6; } 14898 if test ! -x "$tool_specified"; then 14899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14900 $as_echo "not found" >&6; } 14901 as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5 14902 fi 14903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14904 $as_echo "$tool_specified" >&6; } 14905 fi 14906 fi 14907 fi 14908 14909 fi 14910 14911 14912 14913 14914 # Publish this variable in the help. 14915 14916 14917 if [ -z "${CPIO+x}" ]; then 14918 # The variable is not set by user, try to locate tool using the code snippet 14919 for ac_prog in cpio bsdcpio 14920 do 14921 # Extract the first word of "$ac_prog", so it can be a program name with args. 14922 set dummy $ac_prog; ac_word=$2 14923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14924 $as_echo_n "checking for $ac_word... " >&6; } 14925 if ${ac_cv_path_CPIO+:} false; then : 14926 $as_echo_n "(cached) " >&6 14927 else 14928 case $CPIO in 14929 [\\/]* | ?:[\\/]*) 14930 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14931 ;; 14932 *) 14933 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14934 for as_dir in $PATH 14935 do 14936 IFS=$as_save_IFS 14937 test -z "$as_dir" && as_dir=. 14938 for ac_exec_ext in '' $ac_executable_extensions; do 14939 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14940 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14941 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14942 break 2 14943 fi 14944 done 14945 done 14946 IFS=$as_save_IFS 14947 14948 ;; 14949 esac 14950 fi 14951 CPIO=$ac_cv_path_CPIO 14952 if test -n "$CPIO"; then 14953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14954 $as_echo "$CPIO" >&6; } 14955 else 14956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14957 $as_echo "no" >&6; } 14958 fi 14959 14960 14961 test -n "$CPIO" && break 14962 done 14963 14964 else 14965 # The variable is set, but is it from the command line or the environment? 14966 14967 # Try to remove the string !CPIO! from our list. 14968 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/} 14969 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14970 # If it failed, the variable was not from the command line. Ignore it, 14971 # but warn the user (except for BASH, which is always set by the calling BASH). 14972 if test "xCPIO" != xBASH; then 14973 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5 14974 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;} 14975 fi 14976 # Try to locate tool using the code snippet 14977 for ac_prog in cpio bsdcpio 14978 do 14979 # Extract the first word of "$ac_prog", so it can be a program name with args. 14980 set dummy $ac_prog; ac_word=$2 14981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14982 $as_echo_n "checking for $ac_word... " >&6; } 14983 if ${ac_cv_path_CPIO+:} false; then : 14984 $as_echo_n "(cached) " >&6 14985 else 14986 case $CPIO in 14987 [\\/]* | ?:[\\/]*) 14988 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14989 ;; 14990 *) 14991 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14992 for as_dir in $PATH 14993 do 14994 IFS=$as_save_IFS 14995 test -z "$as_dir" && as_dir=. 14996 for ac_exec_ext in '' $ac_executable_extensions; do 14997 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14998 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14999 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15000 break 2 15001 fi 15002 done 15003 done 15004 IFS=$as_save_IFS 15005 15006 ;; 15007 esac 15008 fi 15009 CPIO=$ac_cv_path_CPIO 15010 if test -n "$CPIO"; then 15011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15012 $as_echo "$CPIO" >&6; } 15013 else 15014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15015 $as_echo "no" >&6; } 15016 fi 15017 15018 15019 test -n "$CPIO" && break 15020 done 15021 15022 else 15023 # If it succeeded, then it was overridden by the user. We will use it 15024 # for the tool. 15025 15026 # First remove it from the list of overridden variables, so we can test 15027 # for unknown variables in the end. 15028 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15029 15030 # Check if we try to supply an empty value 15031 if test "x$CPIO" = x; then 15032 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CPIO= (no value)" >&5 15033 $as_echo "$as_me: Setting user supplied tool CPIO= (no value)" >&6;} 15034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15035 $as_echo_n "checking for CPIO... " >&6; } 15036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15037 $as_echo "disabled" >&6; } 15038 else 15039 # Check if the provided tool contains a complete path. 15040 tool_specified="$CPIO" 15041 tool_basename="${tool_specified##*/}" 15042 if test "x$tool_basename" = "x$tool_specified"; then 15043 # A command without a complete path is provided, search $PATH. 15044 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5 15045 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;} 15046 # Extract the first word of "$tool_basename", so it can be a program name with args. 15047 set dummy $tool_basename; ac_word=$2 15048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15049 $as_echo_n "checking for $ac_word... " >&6; } 15050 if ${ac_cv_path_CPIO+:} false; then : 15051 $as_echo_n "(cached) " >&6 15052 else 15053 case $CPIO in 15054 [\\/]* | ?:[\\/]*) 15055 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 15056 ;; 15057 *) 15058 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15059 for as_dir in $PATH 15060 do 15061 IFS=$as_save_IFS 15062 test -z "$as_dir" && as_dir=. 15063 for ac_exec_ext in '' $ac_executable_extensions; do 15064 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15065 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 15066 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15067 break 2 15068 fi 15069 done 15070 done 15071 IFS=$as_save_IFS 15072 15073 ;; 15074 esac 15075 fi 15076 CPIO=$ac_cv_path_CPIO 15077 if test -n "$CPIO"; then 15078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15079 $as_echo "$CPIO" >&6; } 15080 else 15081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15082 $as_echo "no" >&6; } 15083 fi 15084 15085 15086 if test "x$CPIO" = x; then 15087 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15088 fi 15089 else 15090 # Otherwise we believe it is a complete path. Use it as it is. 15091 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5 15092 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;} 15093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15094 $as_echo_n "checking for CPIO... " >&6; } 15095 if test ! -x "$tool_specified"; then 15096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15097 $as_echo "not found" >&6; } 15098 as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5 15099 fi 15100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15101 $as_echo "$tool_specified" >&6; } 15102 fi 15103 fi 15104 fi 15105 15106 fi 15107 15108 15109 15110 15111 # Publish this variable in the help. 15112 15113 15114 if [ -z "${NICE+x}" ]; then 15115 # The variable is not set by user, try to locate tool using the code snippet 15116 for ac_prog in nice 15117 do 15118 # Extract the first word of "$ac_prog", so it can be a program name with args. 15119 set dummy $ac_prog; ac_word=$2 15120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15121 $as_echo_n "checking for $ac_word... " >&6; } 15122 if ${ac_cv_path_NICE+:} false; then : 15123 $as_echo_n "(cached) " >&6 15124 else 15125 case $NICE in 15126 [\\/]* | ?:[\\/]*) 15127 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15128 ;; 15129 *) 15130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15131 for as_dir in $PATH 15132 do 15133 IFS=$as_save_IFS 15134 test -z "$as_dir" && as_dir=. 15135 for ac_exec_ext in '' $ac_executable_extensions; do 15136 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15137 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15139 break 2 15140 fi 15141 done 15142 done 15143 IFS=$as_save_IFS 15144 15145 ;; 15146 esac 15147 fi 15148 NICE=$ac_cv_path_NICE 15149 if test -n "$NICE"; then 15150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15151 $as_echo "$NICE" >&6; } 15152 else 15153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15154 $as_echo "no" >&6; } 15155 fi 15156 15157 15158 test -n "$NICE" && break 15159 done 15160 15161 else 15162 # The variable is set, but is it from the command line or the environment? 15163 15164 # Try to remove the string !NICE! from our list. 15165 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NICE!/} 15166 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15167 # If it failed, the variable was not from the command line. Ignore it, 15168 # but warn the user (except for BASH, which is always set by the calling BASH). 15169 if test "xNICE" != xBASH; then 15170 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&5 15171 $as_echo "$as_me: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&2;} 15172 fi 15173 # Try to locate tool using the code snippet 15174 for ac_prog in nice 15175 do 15176 # Extract the first word of "$ac_prog", so it can be a program name with args. 15177 set dummy $ac_prog; ac_word=$2 15178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15179 $as_echo_n "checking for $ac_word... " >&6; } 15180 if ${ac_cv_path_NICE+:} false; then : 15181 $as_echo_n "(cached) " >&6 15182 else 15183 case $NICE in 15184 [\\/]* | ?:[\\/]*) 15185 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15186 ;; 15187 *) 15188 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15189 for as_dir in $PATH 15190 do 15191 IFS=$as_save_IFS 15192 test -z "$as_dir" && as_dir=. 15193 for ac_exec_ext in '' $ac_executable_extensions; do 15194 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15195 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15196 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15197 break 2 15198 fi 15199 done 15200 done 15201 IFS=$as_save_IFS 15202 15203 ;; 15204 esac 15205 fi 15206 NICE=$ac_cv_path_NICE 15207 if test -n "$NICE"; then 15208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15209 $as_echo "$NICE" >&6; } 15210 else 15211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15212 $as_echo "no" >&6; } 15213 fi 15214 15215 15216 test -n "$NICE" && break 15217 done 15218 15219 else 15220 # If it succeeded, then it was overridden by the user. We will use it 15221 # for the tool. 15222 15223 # First remove it from the list of overridden variables, so we can test 15224 # for unknown variables in the end. 15225 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15226 15227 # Check if we try to supply an empty value 15228 if test "x$NICE" = x; then 15229 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NICE= (no value)" >&5 15230 $as_echo "$as_me: Setting user supplied tool NICE= (no value)" >&6;} 15231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15232 $as_echo_n "checking for NICE... " >&6; } 15233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15234 $as_echo "disabled" >&6; } 15235 else 15236 # Check if the provided tool contains a complete path. 15237 tool_specified="$NICE" 15238 tool_basename="${tool_specified##*/}" 15239 if test "x$tool_basename" = "x$tool_specified"; then 15240 # A command without a complete path is provided, search $PATH. 15241 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NICE=$tool_basename" >&5 15242 $as_echo "$as_me: Will search for user supplied tool NICE=$tool_basename" >&6;} 15243 # Extract the first word of "$tool_basename", so it can be a program name with args. 15244 set dummy $tool_basename; ac_word=$2 15245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15246 $as_echo_n "checking for $ac_word... " >&6; } 15247 if ${ac_cv_path_NICE+:} false; then : 15248 $as_echo_n "(cached) " >&6 15249 else 15250 case $NICE in 15251 [\\/]* | ?:[\\/]*) 15252 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15253 ;; 15254 *) 15255 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15256 for as_dir in $PATH 15257 do 15258 IFS=$as_save_IFS 15259 test -z "$as_dir" && as_dir=. 15260 for ac_exec_ext in '' $ac_executable_extensions; do 15261 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15262 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15263 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15264 break 2 15265 fi 15266 done 15267 done 15268 IFS=$as_save_IFS 15269 15270 ;; 15271 esac 15272 fi 15273 NICE=$ac_cv_path_NICE 15274 if test -n "$NICE"; then 15275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15276 $as_echo "$NICE" >&6; } 15277 else 15278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15279 $as_echo "no" >&6; } 15280 fi 15281 15282 15283 if test "x$NICE" = x; then 15284 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15285 fi 15286 else 15287 # Otherwise we believe it is a complete path. Use it as it is. 15288 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NICE=$tool_specified" >&5 15289 $as_echo "$as_me: Will use user supplied tool NICE=$tool_specified" >&6;} 15290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15291 $as_echo_n "checking for NICE... " >&6; } 15292 if test ! -x "$tool_specified"; then 15293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15294 $as_echo "not found" >&6; } 15295 as_fn_error $? "User supplied tool NICE=$tool_specified does not exist or is not executable" "$LINENO" 5 15296 fi 15297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15298 $as_echo "$tool_specified" >&6; } 15299 fi 15300 fi 15301 fi 15302 15303 fi 15304 15305 15306 15307 15308 # Publish this variable in the help. 15309 15310 15311 if [ -z "${PANDOC+x}" ]; then 15312 # The variable is not set by user, try to locate tool using the code snippet 15313 for ac_prog in pandoc 15314 do 15315 # Extract the first word of "$ac_prog", so it can be a program name with args. 15316 set dummy $ac_prog; ac_word=$2 15317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15318 $as_echo_n "checking for $ac_word... " >&6; } 15319 if ${ac_cv_path_PANDOC+:} false; then : 15320 $as_echo_n "(cached) " >&6 15321 else 15322 case $PANDOC in 15323 [\\/]* | ?:[\\/]*) 15324 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15325 ;; 15326 *) 15327 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15328 for as_dir in $PATH 15329 do 15330 IFS=$as_save_IFS 15331 test -z "$as_dir" && as_dir=. 15332 for ac_exec_ext in '' $ac_executable_extensions; do 15333 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15334 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15335 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15336 break 2 15337 fi 15338 done 15339 done 15340 IFS=$as_save_IFS 15341 15342 ;; 15343 esac 15344 fi 15345 PANDOC=$ac_cv_path_PANDOC 15346 if test -n "$PANDOC"; then 15347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15348 $as_echo "$PANDOC" >&6; } 15349 else 15350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15351 $as_echo "no" >&6; } 15352 fi 15353 15354 15355 test -n "$PANDOC" && break 15356 done 15357 15358 else 15359 # The variable is set, but is it from the command line or the environment? 15360 15361 # Try to remove the string !PANDOC! from our list. 15362 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PANDOC!/} 15363 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15364 # If it failed, the variable was not from the command line. Ignore it, 15365 # but warn the user (except for BASH, which is always set by the calling BASH). 15366 if test "xPANDOC" != xBASH; then 15367 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PANDOC from the environment. Use command line variables instead." >&5 15368 $as_echo "$as_me: WARNING: Ignoring value of PANDOC from the environment. Use command line variables instead." >&2;} 15369 fi 15370 # Try to locate tool using the code snippet 15371 for ac_prog in pandoc 15372 do 15373 # Extract the first word of "$ac_prog", so it can be a program name with args. 15374 set dummy $ac_prog; ac_word=$2 15375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15376 $as_echo_n "checking for $ac_word... " >&6; } 15377 if ${ac_cv_path_PANDOC+:} false; then : 15378 $as_echo_n "(cached) " >&6 15379 else 15380 case $PANDOC in 15381 [\\/]* | ?:[\\/]*) 15382 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15383 ;; 15384 *) 15385 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15386 for as_dir in $PATH 15387 do 15388 IFS=$as_save_IFS 15389 test -z "$as_dir" && as_dir=. 15390 for ac_exec_ext in '' $ac_executable_extensions; do 15391 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15392 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15393 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15394 break 2 15395 fi 15396 done 15397 done 15398 IFS=$as_save_IFS 15399 15400 ;; 15401 esac 15402 fi 15403 PANDOC=$ac_cv_path_PANDOC 15404 if test -n "$PANDOC"; then 15405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15406 $as_echo "$PANDOC" >&6; } 15407 else 15408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15409 $as_echo "no" >&6; } 15410 fi 15411 15412 15413 test -n "$PANDOC" && break 15414 done 15415 15416 else 15417 # If it succeeded, then it was overridden by the user. We will use it 15418 # for the tool. 15419 15420 # First remove it from the list of overridden variables, so we can test 15421 # for unknown variables in the end. 15422 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15423 15424 # Check if we try to supply an empty value 15425 if test "x$PANDOC" = x; then 15426 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PANDOC= (no value)" >&5 15427 $as_echo "$as_me: Setting user supplied tool PANDOC= (no value)" >&6;} 15428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANDOC" >&5 15429 $as_echo_n "checking for PANDOC... " >&6; } 15430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15431 $as_echo "disabled" >&6; } 15432 else 15433 # Check if the provided tool contains a complete path. 15434 tool_specified="$PANDOC" 15435 tool_basename="${tool_specified##*/}" 15436 if test "x$tool_basename" = "x$tool_specified"; then 15437 # A command without a complete path is provided, search $PATH. 15438 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PANDOC=$tool_basename" >&5 15439 $as_echo "$as_me: Will search for user supplied tool PANDOC=$tool_basename" >&6;} 15440 # Extract the first word of "$tool_basename", so it can be a program name with args. 15441 set dummy $tool_basename; ac_word=$2 15442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15443 $as_echo_n "checking for $ac_word... " >&6; } 15444 if ${ac_cv_path_PANDOC+:} false; then : 15445 $as_echo_n "(cached) " >&6 15446 else 15447 case $PANDOC in 15448 [\\/]* | ?:[\\/]*) 15449 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15450 ;; 15451 *) 15452 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15453 for as_dir in $PATH 15454 do 15455 IFS=$as_save_IFS 15456 test -z "$as_dir" && as_dir=. 15457 for ac_exec_ext in '' $ac_executable_extensions; do 15458 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15459 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15460 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15461 break 2 15462 fi 15463 done 15464 done 15465 IFS=$as_save_IFS 15466 15467 ;; 15468 esac 15469 fi 15470 PANDOC=$ac_cv_path_PANDOC 15471 if test -n "$PANDOC"; then 15472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15473 $as_echo "$PANDOC" >&6; } 15474 else 15475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15476 $as_echo "no" >&6; } 15477 fi 15478 15479 15480 if test "x$PANDOC" = x; then 15481 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15482 fi 15483 else 15484 # Otherwise we believe it is a complete path. Use it as it is. 15485 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PANDOC=$tool_specified" >&5 15486 $as_echo "$as_me: Will use user supplied tool PANDOC=$tool_specified" >&6;} 15487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANDOC" >&5 15488 $as_echo_n "checking for PANDOC... " >&6; } 15489 if test ! -x "$tool_specified"; then 15490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15491 $as_echo "not found" >&6; } 15492 as_fn_error $? "User supplied tool PANDOC=$tool_specified does not exist or is not executable" "$LINENO" 5 15493 fi 15494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15495 $as_echo "$tool_specified" >&6; } 15496 fi 15497 fi 15498 fi 15499 15500 fi 15501 15502 15503 15504 15505 # Now we can determine OpenJDK build and target platforms. This is required to 15506 # have early on. 15507 # Make sure we can run config.sub. 15508 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 15509 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 15510 15511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 15512 $as_echo_n "checking build system type... " >&6; } 15513 if ${ac_cv_build+:} false; then : 15514 $as_echo_n "(cached) " >&6 15515 else 15516 ac_build_alias=$build_alias 15517 test "x$ac_build_alias" = x && 15518 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 15519 test "x$ac_build_alias" = x && 15520 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 15521 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 15522 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 15523 15524 fi 15525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 15526 $as_echo "$ac_cv_build" >&6; } 15527 case $ac_cv_build in 15528 *-*-*) ;; 15529 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 15530 esac 15531 build=$ac_cv_build 15532 ac_save_IFS=$IFS; IFS='-' 15533 set x $ac_cv_build 15534 shift 15535 build_cpu=$1 15536 build_vendor=$2 15537 shift; shift 15538 # Remember, the first character of IFS is used to create $*, 15539 # except with old shells: 15540 build_os=$* 15541 IFS=$ac_save_IFS 15542 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 15543 15544 15545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 15546 $as_echo_n "checking host system type... " >&6; } 15547 if ${ac_cv_host+:} false; then : 15548 $as_echo_n "(cached) " >&6 15549 else 15550 if test "x$host_alias" = x; then 15551 ac_cv_host=$ac_cv_build 15552 else 15553 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 15554 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 15555 fi 15556 15557 fi 15558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 15559 $as_echo "$ac_cv_host" >&6; } 15560 case $ac_cv_host in 15561 *-*-*) ;; 15562 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 15563 esac 15564 host=$ac_cv_host 15565 ac_save_IFS=$IFS; IFS='-' 15566 set x $ac_cv_host 15567 shift 15568 host_cpu=$1 15569 host_vendor=$2 15570 shift; shift 15571 # Remember, the first character of IFS is used to create $*, 15572 # except with old shells: 15573 host_os=$* 15574 IFS=$ac_save_IFS 15575 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 15576 15577 15578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 15579 $as_echo_n "checking target system type... " >&6; } 15580 if ${ac_cv_target+:} false; then : 15581 $as_echo_n "(cached) " >&6 15582 else 15583 if test "x$target_alias" = x; then 15584 ac_cv_target=$ac_cv_host 15585 else 15586 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 15587 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 15588 fi 15589 15590 fi 15591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 15592 $as_echo "$ac_cv_target" >&6; } 15593 case $ac_cv_target in 15594 *-*-*) ;; 15595 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 15596 esac 15597 target=$ac_cv_target 15598 ac_save_IFS=$IFS; IFS='-' 15599 set x $ac_cv_target 15600 shift 15601 target_cpu=$1 15602 target_vendor=$2 15603 shift; shift 15604 # Remember, the first character of IFS is used to create $*, 15605 # except with old shells: 15606 target_os=$* 15607 IFS=$ac_save_IFS 15608 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac 15609 15610 15611 # The aliases save the names the user supplied, while $host etc. 15612 # will get canonicalized. 15613 test -n "$target_alias" && 15614 test "$program_prefix$program_suffix$program_transform_name" = \ 15615 NONENONEs,x,x, && 15616 program_prefix=${target_alias}- 15617 15618 # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target" 15619 # is confusing; it assumes you are cross-compiling a cross-compiler (!) and "target" is thus the target of the 15620 # product you're building. The target of this build is called "host". Since this is confusing to most people, we 15621 # have not adopted that system, but use "target" as the platform we are building for. In some places though we need 15622 # to use the configure naming style. 15623 15624 15625 15626 15627 15628 # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME 15629 # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME 15630 # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build, 15631 # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME. 15632 OPENJDK_TARGET_AUTOCONF_NAME="$host" 15633 OPENJDK_BUILD_AUTOCONF_NAME="$build" 15634 15635 15636 15637 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15638 15639 case "$build_os" in 15640 *linux*) 15641 VAR_OS=linux 15642 VAR_OS_TYPE=unix 15643 ;; 15644 *solaris*) 15645 VAR_OS=solaris 15646 VAR_OS_TYPE=unix 15647 ;; 15648 *darwin*) 15649 VAR_OS=macosx 15650 VAR_OS_TYPE=unix 15651 ;; 15652 *bsd*) 15653 VAR_OS=bsd 15654 VAR_OS_TYPE=unix 15655 ;; 15656 *cygwin*) 15657 VAR_OS=windows 15658 VAR_OS_ENV=windows.cygwin 15659 ;; 15660 *mingw*) 15661 VAR_OS=windows 15662 VAR_OS_ENV=windows.msys 15663 ;; 15664 *aix*) 15665 VAR_OS=aix 15666 VAR_OS_TYPE=unix 15667 ;; 15668 *) 15669 as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5 15670 ;; 15671 esac 15672 15673 15674 # First argument is the cpu name from the trip/quad 15675 case "$build_cpu" in 15676 x86_64) 15677 VAR_CPU=x86_64 15678 VAR_CPU_ARCH=x86 15679 VAR_CPU_BITS=64 15680 VAR_CPU_ENDIAN=little 15681 ;; 15682 i?86) 15683 VAR_CPU=x86 15684 VAR_CPU_ARCH=x86 15685 VAR_CPU_BITS=32 15686 VAR_CPU_ENDIAN=little 15687 ;; 15688 alpha*) 15689 VAR_CPU=alpha 15690 VAR_CPU_ARCH=alpha 15691 VAR_CPU_BITS=64 15692 VAR_CPU_ENDIAN=little 15693 ;; 15694 arm*) 15695 VAR_CPU=arm 15696 VAR_CPU_ARCH=arm 15697 VAR_CPU_BITS=32 15698 VAR_CPU_ENDIAN=little 15699 ;; 15700 aarch64) 15701 VAR_CPU=aarch64 15702 VAR_CPU_ARCH=aarch64 15703 VAR_CPU_BITS=64 15704 VAR_CPU_ENDIAN=little 15705 ;; 15706 m68k) 15707 VAR_CPU=m68k 15708 VAR_CPU_ARCH=m68k 15709 VAR_CPU_BITS=32 15710 VAR_CPU_ENDIAN=big 15711 ;; 15712 mips) 15713 VAR_CPU=mips 15714 VAR_CPU_ARCH=mips 15715 VAR_CPU_BITS=32 15716 VAR_CPU_ENDIAN=big 15717 ;; 15718 mipsel) 15719 VAR_CPU=mipsel 15720 VAR_CPU_ARCH=mipsel 15721 VAR_CPU_BITS=32 15722 VAR_CPU_ENDIAN=little 15723 ;; 15724 mips64) 15725 VAR_CPU=mips64 15726 VAR_CPU_ARCH=mips64 15727 VAR_CPU_BITS=64 15728 VAR_CPU_ENDIAN=big 15729 ;; 15730 mips64el) 15731 VAR_CPU=mips64el 15732 VAR_CPU_ARCH=mips64el 15733 VAR_CPU_BITS=64 15734 VAR_CPU_ENDIAN=little 15735 ;; 15736 powerpc) 15737 VAR_CPU=ppc 15738 VAR_CPU_ARCH=ppc 15739 VAR_CPU_BITS=32 15740 VAR_CPU_ENDIAN=big 15741 ;; 15742 powerpc64) 15743 VAR_CPU=ppc64 15744 VAR_CPU_ARCH=ppc 15745 VAR_CPU_BITS=64 15746 VAR_CPU_ENDIAN=big 15747 ;; 15748 powerpc64le) 15749 VAR_CPU=ppc64le 15750 VAR_CPU_ARCH=ppc 15751 VAR_CPU_BITS=64 15752 VAR_CPU_ENDIAN=little 15753 ;; 15754 s390) 15755 VAR_CPU=s390 15756 VAR_CPU_ARCH=s390 15757 VAR_CPU_BITS=32 15758 VAR_CPU_ENDIAN=big 15759 ;; 15760 s390x) 15761 VAR_CPU=s390x 15762 VAR_CPU_ARCH=s390 15763 VAR_CPU_BITS=64 15764 VAR_CPU_ENDIAN=big 15765 ;; 15766 sh*eb) 15767 VAR_CPU=sh 15768 VAR_CPU_ARCH=sh 15769 VAR_CPU_BITS=32 15770 VAR_CPU_ENDIAN=big 15771 ;; 15772 sh*) 15773 VAR_CPU=sh 15774 VAR_CPU_ARCH=sh 15775 VAR_CPU_BITS=32 15776 VAR_CPU_ENDIAN=little 15777 ;; 15778 sparc) 15779 VAR_CPU=sparc 15780 VAR_CPU_ARCH=sparc 15781 VAR_CPU_BITS=32 15782 VAR_CPU_ENDIAN=big 15783 ;; 15784 sparcv9|sparc64) 15785 VAR_CPU=sparcv9 15786 VAR_CPU_ARCH=sparc 15787 VAR_CPU_BITS=64 15788 VAR_CPU_ENDIAN=big 15789 ;; 15790 *) 15791 as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5 15792 ;; 15793 esac 15794 15795 # ..and setup our own variables. (Do this explicitly to facilitate searching) 15796 OPENJDK_BUILD_OS="$VAR_OS" 15797 if test "x$VAR_OS_TYPE" != x; then 15798 OPENJDK_BUILD_OS_TYPE="$VAR_OS_TYPE" 15799 else 15800 OPENJDK_BUILD_OS_TYPE="$VAR_OS" 15801 fi 15802 if test "x$VAR_OS_ENV" != x; then 15803 OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV" 15804 else 15805 OPENJDK_BUILD_OS_ENV="$VAR_OS" 15806 fi 15807 OPENJDK_BUILD_CPU="$VAR_CPU" 15808 OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH" 15809 OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS" 15810 OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15811 15812 15813 15814 15815 15816 15817 15818 15819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5 15820 $as_echo_n "checking openjdk-build os-cpu... " >&6; } 15821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5 15822 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; } 15823 15824 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15825 15826 case "$host_os" in 15827 *linux*) 15828 VAR_OS=linux 15829 VAR_OS_TYPE=unix 15830 ;; 15831 *solaris*) 15832 VAR_OS=solaris 15833 VAR_OS_TYPE=unix 15834 ;; 15835 *darwin*) 15836 VAR_OS=macosx 15837 VAR_OS_TYPE=unix 15838 ;; 15839 *bsd*) 15840 VAR_OS=bsd 15841 VAR_OS_TYPE=unix 15842 ;; 15843 *cygwin*) 15844 VAR_OS=windows 15845 VAR_OS_ENV=windows.cygwin 15846 ;; 15847 *mingw*) 15848 VAR_OS=windows 15849 VAR_OS_ENV=windows.msys 15850 ;; 15851 *aix*) 15852 VAR_OS=aix 15853 VAR_OS_TYPE=unix 15854 ;; 15855 *) 15856 as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5 15857 ;; 15858 esac 15859 15860 15861 # First argument is the cpu name from the trip/quad 15862 case "$host_cpu" in 15863 x86_64) 15864 VAR_CPU=x86_64 15865 VAR_CPU_ARCH=x86 15866 VAR_CPU_BITS=64 15867 VAR_CPU_ENDIAN=little 15868 ;; 15869 i?86) 15870 VAR_CPU=x86 15871 VAR_CPU_ARCH=x86 15872 VAR_CPU_BITS=32 15873 VAR_CPU_ENDIAN=little 15874 ;; 15875 alpha*) 15876 VAR_CPU=alpha 15877 VAR_CPU_ARCH=alpha 15878 VAR_CPU_BITS=64 15879 VAR_CPU_ENDIAN=little 15880 ;; 15881 arm*) 15882 VAR_CPU=arm 15883 VAR_CPU_ARCH=arm 15884 VAR_CPU_BITS=32 15885 VAR_CPU_ENDIAN=little 15886 ;; 15887 aarch64) 15888 VAR_CPU=aarch64 15889 VAR_CPU_ARCH=aarch64 15890 VAR_CPU_BITS=64 15891 VAR_CPU_ENDIAN=little 15892 ;; 15893 m68k) 15894 VAR_CPU=m68k 15895 VAR_CPU_ARCH=m68k 15896 VAR_CPU_BITS=32 15897 VAR_CPU_ENDIAN=big 15898 ;; 15899 mips) 15900 VAR_CPU=mips 15901 VAR_CPU_ARCH=mips 15902 VAR_CPU_BITS=32 15903 VAR_CPU_ENDIAN=big 15904 ;; 15905 mipsel) 15906 VAR_CPU=mipsel 15907 VAR_CPU_ARCH=mipsel 15908 VAR_CPU_BITS=32 15909 VAR_CPU_ENDIAN=little 15910 ;; 15911 mips64) 15912 VAR_CPU=mips64 15913 VAR_CPU_ARCH=mips64 15914 VAR_CPU_BITS=64 15915 VAR_CPU_ENDIAN=big 15916 ;; 15917 mips64el) 15918 VAR_CPU=mips64el 15919 VAR_CPU_ARCH=mips64el 15920 VAR_CPU_BITS=64 15921 VAR_CPU_ENDIAN=little 15922 ;; 15923 powerpc) 15924 VAR_CPU=ppc 15925 VAR_CPU_ARCH=ppc 15926 VAR_CPU_BITS=32 15927 VAR_CPU_ENDIAN=big 15928 ;; 15929 powerpc64) 15930 VAR_CPU=ppc64 15931 VAR_CPU_ARCH=ppc 15932 VAR_CPU_BITS=64 15933 VAR_CPU_ENDIAN=big 15934 ;; 15935 powerpc64le) 15936 VAR_CPU=ppc64le 15937 VAR_CPU_ARCH=ppc 15938 VAR_CPU_BITS=64 15939 VAR_CPU_ENDIAN=little 15940 ;; 15941 s390) 15942 VAR_CPU=s390 15943 VAR_CPU_ARCH=s390 15944 VAR_CPU_BITS=32 15945 VAR_CPU_ENDIAN=big 15946 ;; 15947 s390x) 15948 VAR_CPU=s390x 15949 VAR_CPU_ARCH=s390 15950 VAR_CPU_BITS=64 15951 VAR_CPU_ENDIAN=big 15952 ;; 15953 sh*eb) 15954 VAR_CPU=sh 15955 VAR_CPU_ARCH=sh 15956 VAR_CPU_BITS=32 15957 VAR_CPU_ENDIAN=big 15958 ;; 15959 sh*) 15960 VAR_CPU=sh 15961 VAR_CPU_ARCH=sh 15962 VAR_CPU_BITS=32 15963 VAR_CPU_ENDIAN=little 15964 ;; 15965 sparc) 15966 VAR_CPU=sparc 15967 VAR_CPU_ARCH=sparc 15968 VAR_CPU_BITS=32 15969 VAR_CPU_ENDIAN=big 15970 ;; 15971 sparcv9|sparc64) 15972 VAR_CPU=sparcv9 15973 VAR_CPU_ARCH=sparc 15974 VAR_CPU_BITS=64 15975 VAR_CPU_ENDIAN=big 15976 ;; 15977 *) 15978 as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5 15979 ;; 15980 esac 15981 15982 # ... and setup our own variables. (Do this explicitly to facilitate searching) 15983 OPENJDK_TARGET_OS="$VAR_OS" 15984 if test "x$VAR_OS_TYPE" != x; then 15985 OPENJDK_TARGET_OS_TYPE="$VAR_OS_TYPE" 15986 else 15987 OPENJDK_TARGET_OS_TYPE="$VAR_OS" 15988 fi 15989 if test "x$VAR_OS_ENV" != x; then 15990 OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV" 15991 else 15992 OPENJDK_TARGET_OS_ENV="$VAR_OS" 15993 fi 15994 OPENJDK_TARGET_CPU="$VAR_CPU" 15995 OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH" 15996 OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS" 15997 OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15998 15999 16000 16001 16002 16003 16004 16005 16006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5 16007 $as_echo_n "checking openjdk-target os-cpu... " >&6; } 16008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5 16009 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; } 16010 16011 16012 16013 # Check whether --with-target-bits was given. 16014 if test "${with_target_bits+set}" = set; then : 16015 withval=$with_target_bits; 16016 fi 16017 16018 16019 # We have three types of compiles: 16020 # native == normal compilation, target system == build system 16021 # cross == traditional cross compilation, target system != build system; special toolchain needed 16022 # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines 16023 # 16024 if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then 16025 # We're doing a proper cross-compilation 16026 COMPILE_TYPE="cross" 16027 else 16028 COMPILE_TYPE="native" 16029 fi 16030 16031 if test "x$with_target_bits" != x; then 16032 if test "x$COMPILE_TYPE" = "xcross"; then 16033 as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5 16034 fi 16035 16036 if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 16037 # A reduced build is requested 16038 COMPILE_TYPE="reduced" 16039 OPENJDK_TARGET_CPU_BITS=32 16040 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 16041 OPENJDK_TARGET_CPU=x86 16042 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 16043 OPENJDK_TARGET_CPU=sparc 16044 else 16045 as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5 16046 fi 16047 elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 16048 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 16049 elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then 16050 { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5 16051 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;} 16052 else 16053 as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5 16054 fi 16055 fi 16056 16057 16058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5 16059 $as_echo_n "checking compilation type... " >&6; } 16060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5 16061 $as_echo "$COMPILE_TYPE" >&6; } 16062 16063 16064 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16065 OPENJDK_MODULE_TARGET_OS_NAME="macos" 16066 else 16067 OPENJDK_MODULE_TARGET_OS_NAME="$OPENJDK_TARGET_OS" 16068 fi 16069 16070 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16071 OPENJDK_MODULE_TARGET_OS_ARCH="amd64" 16072 else 16073 OPENJDK_MODULE_TARGET_OS_ARCH="$OPENJDK_TARGET_CPU" 16074 fi 16075 16076 OPENJDK_MODULE_TARGET_PLATFORM="${OPENJDK_MODULE_TARGET_OS_NAME}-${OPENJDK_MODULE_TARGET_OS_ARCH}" 16077 16078 16079 16080 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 16081 RELEASE_FILE_OS_NAME=SunOS 16082 fi 16083 if test "x$OPENJDK_TARGET_OS" = "xlinux"; then 16084 RELEASE_FILE_OS_NAME=Linux 16085 fi 16086 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16087 RELEASE_FILE_OS_NAME=Windows 16088 fi 16089 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16090 RELEASE_FILE_OS_NAME="Darwin" 16091 fi 16092 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 16093 RELEASE_FILE_OS_NAME="AIX" 16094 fi 16095 RELEASE_FILE_OS_ARCH=${OPENJDK_TARGET_CPU} 16096 16097 16098 16099 16100 16101 16102 # Also store the legacy naming of the cpu. 16103 # Ie i586 and amd64 instead of x86 and x86_64 16104 OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU" 16105 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16106 OPENJDK_TARGET_CPU_LEGACY="i586" 16107 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16108 # On all platforms except MacOSX replace x86_64 with amd64. 16109 OPENJDK_TARGET_CPU_LEGACY="amd64" 16110 elif test "x$OPENJDK_TARGET_CPU" = xalpha; then 16111 # Avoid name collisions with variables named alpha 16112 OPENJDK_TARGET_CPU_LEGACY="_alpha_" 16113 elif test "x$OPENJDK_TARGET_CPU" = xsh; then 16114 # Avoid name collisions with variables named sh 16115 OPENJDK_TARGET_CPU_LEGACY="_sh_" 16116 fi 16117 16118 16119 # And the second legacy naming of the cpu. 16120 # Ie i386 and amd64 instead of x86 and x86_64. 16121 OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU" 16122 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16123 OPENJDK_TARGET_CPU_LEGACY_LIB="i386" 16124 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16125 OPENJDK_TARGET_CPU_LEGACY_LIB="amd64" 16126 fi 16127 16128 16129 # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 16130 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 16131 # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so 16132 OPENJDK_TARGET_CPU_ISADIR="" 16133 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 16134 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16135 OPENJDK_TARGET_CPU_ISADIR="/amd64" 16136 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16137 OPENJDK_TARGET_CPU_ISADIR="/sparcv9" 16138 fi 16139 fi 16140 16141 16142 # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property 16143 OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU" 16144 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then 16145 # On linux only, we replace x86 with i386. 16146 OPENJDK_TARGET_CPU_OSARCH="i386" 16147 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16148 # On all platforms except macosx, we replace x86_64 with amd64. 16149 OPENJDK_TARGET_CPU_OSARCH="amd64" 16150 fi 16151 16152 16153 OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU" 16154 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16155 OPENJDK_TARGET_CPU_JLI="i386" 16156 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16157 # On all platforms except macosx, we replace x86_64 with amd64. 16158 OPENJDK_TARGET_CPU_JLI="amd64" 16159 fi 16160 16161 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16162 OPENJDK_TARGET_OS_EXPORT_DIR=macosx 16163 else 16164 OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_TYPE} 16165 fi 16166 16167 16168 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16169 # Macosx is osx and x86_64 is x64 16170 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16171 OPENJDK_TARGET_OS_BUNDLE="osx" 16172 else 16173 OPENJDK_TARGET_OS_BUNDLE="$OPENJDK_TARGET_OS" 16174 fi 16175 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16176 OPENJDK_TARGET_CPU_BUNDLE="x64" 16177 else 16178 OPENJDK_TARGET_CPU_BUNDLE="$OPENJDK_TARGET_CPU" 16179 fi 16180 OPENJDK_TARGET_BUNDLE_PLATFORM="${OPENJDK_TARGET_OS_BUNDLE}-${OPENJDK_TARGET_CPU_BUNDLE}" 16181 16182 16183 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 16184 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16185 # unpack200.exe. This variable is used in 16186 # FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER. 16187 if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then 16188 OPENJDK_TARGET_ADD_LP64="-D_LP64=1" 16189 fi 16190 fi 16191 16192 if test "x$COMPILE_TYPE" = "xcross"; then 16193 # FIXME: ... or should this include reduced builds..? 16194 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY" 16195 else 16196 DEFINE_CROSS_COMPILE_ARCH="" 16197 fi 16198 16199 16200 # Convert openjdk platform names to hotspot names 16201 16202 HOTSPOT_TARGET_OS=${OPENJDK_TARGET_OS} 16203 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16204 HOTSPOT_TARGET_OS=bsd 16205 fi 16206 16207 16208 HOTSPOT_TARGET_OS_TYPE=${OPENJDK_TARGET_OS_TYPE} 16209 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 16210 HOTSPOT_TARGET_OS_TYPE=posix 16211 fi 16212 16213 16214 HOTSPOT_TARGET_CPU=${OPENJDK_TARGET_CPU} 16215 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16216 HOTSPOT_TARGET_CPU=x86_32 16217 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16218 HOTSPOT_TARGET_CPU=sparc 16219 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 16220 HOTSPOT_TARGET_CPU=ppc_64 16221 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 16222 HOTSPOT_TARGET_CPU=ppc_64 16223 fi 16224 16225 16226 # This is identical with OPENJDK_*, but define anyway for consistency. 16227 HOTSPOT_TARGET_CPU_ARCH=${OPENJDK_TARGET_CPU_ARCH} 16228 16229 16230 # Setup HOTSPOT_TARGET_CPU_DEFINE 16231 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16232 HOTSPOT_TARGET_CPU_DEFINE=IA32 16233 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16234 HOTSPOT_TARGET_CPU_DEFINE=AMD64 16235 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16236 HOTSPOT_TARGET_CPU_DEFINE=SPARC 16237 elif test "x$OPENJDK_TARGET_CPU" = xaarch64; then 16238 HOTSPOT_TARGET_CPU_DEFINE=AARCH64 16239 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 16240 HOTSPOT_TARGET_CPU_DEFINE=PPC64 16241 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 16242 HOTSPOT_TARGET_CPU_DEFINE=PPC64 16243 16244 # The cpu defines below are for zero, we don't support them directly. 16245 elif test "x$OPENJDK_TARGET_CPU" = xsparc; then 16246 HOTSPOT_TARGET_CPU_DEFINE=SPARC 16247 elif test "x$OPENJDK_TARGET_CPU" = xppc; then 16248 HOTSPOT_TARGET_CPU_DEFINE=PPC32 16249 elif test "x$OPENJDK_TARGET_CPU" = xs390; then 16250 HOTSPOT_TARGET_CPU_DEFINE=S390 16251 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 16252 HOTSPOT_TARGET_CPU_DEFINE=S390 16253 elif test "x$OPENJDK_TARGET_CPU" != x; then 16254 HOTSPOT_TARGET_CPU_DEFINE=$(echo $OPENJDK_TARGET_CPU | tr a-z A-Z) 16255 fi 16256 16257 16258 16259 16260 # Also store the legacy naming of the cpu. 16261 # Ie i586 and amd64 instead of x86 and x86_64 16262 OPENJDK_BUILD_CPU_LEGACY="$OPENJDK_BUILD_CPU" 16263 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16264 OPENJDK_BUILD_CPU_LEGACY="i586" 16265 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16266 # On all platforms except MacOSX replace x86_64 with amd64. 16267 OPENJDK_BUILD_CPU_LEGACY="amd64" 16268 elif test "x$OPENJDK_BUILD_CPU" = xalpha; then 16269 # Avoid name collisions with variables named alpha 16270 OPENJDK_BUILD_CPU_LEGACY="_alpha_" 16271 elif test "x$OPENJDK_BUILD_CPU" = xsh; then 16272 # Avoid name collisions with variables named sh 16273 OPENJDK_BUILD_CPU_LEGACY="_sh_" 16274 fi 16275 16276 16277 # And the second legacy naming of the cpu. 16278 # Ie i386 and amd64 instead of x86 and x86_64. 16279 OPENJDK_BUILD_CPU_LEGACY_LIB="$OPENJDK_BUILD_CPU" 16280 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16281 OPENJDK_BUILD_CPU_LEGACY_LIB="i386" 16282 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16283 OPENJDK_BUILD_CPU_LEGACY_LIB="amd64" 16284 fi 16285 16286 16287 # OPENJDK_BUILD_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 16288 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 16289 # /usr/lib${OPENJDK_BUILD_CPU_ISADIR}/libexample.so 16290 OPENJDK_BUILD_CPU_ISADIR="" 16291 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 16292 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16293 OPENJDK_BUILD_CPU_ISADIR="/amd64" 16294 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16295 OPENJDK_BUILD_CPU_ISADIR="/sparcv9" 16296 fi 16297 fi 16298 16299 16300 # Setup OPENJDK_BUILD_CPU_OSARCH, which is used to set the os.arch Java system property 16301 OPENJDK_BUILD_CPU_OSARCH="$OPENJDK_BUILD_CPU" 16302 if test "x$OPENJDK_BUILD_OS" = xlinux && test "x$OPENJDK_BUILD_CPU" = xx86; then 16303 # On linux only, we replace x86 with i386. 16304 OPENJDK_BUILD_CPU_OSARCH="i386" 16305 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16306 # On all platforms except macosx, we replace x86_64 with amd64. 16307 OPENJDK_BUILD_CPU_OSARCH="amd64" 16308 fi 16309 16310 16311 OPENJDK_BUILD_CPU_JLI="$OPENJDK_BUILD_CPU" 16312 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16313 OPENJDK_BUILD_CPU_JLI="i386" 16314 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16315 # On all platforms except macosx, we replace x86_64 with amd64. 16316 OPENJDK_BUILD_CPU_JLI="amd64" 16317 fi 16318 16319 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16320 OPENJDK_BUILD_OS_EXPORT_DIR=macosx 16321 else 16322 OPENJDK_BUILD_OS_EXPORT_DIR=${OPENJDK_BUILD_OS_TYPE} 16323 fi 16324 16325 16326 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16327 # Macosx is osx and x86_64 is x64 16328 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16329 OPENJDK_BUILD_OS_BUNDLE="osx" 16330 else 16331 OPENJDK_BUILD_OS_BUNDLE="$OPENJDK_TARGET_OS" 16332 fi 16333 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16334 OPENJDK_BUILD_CPU_BUNDLE="x64" 16335 else 16336 OPENJDK_BUILD_CPU_BUNDLE="$OPENJDK_BUILD_CPU" 16337 fi 16338 OPENJDK_BUILD_BUNDLE_PLATFORM="${OPENJDK_BUILD_OS_BUNDLE}-${OPENJDK_BUILD_CPU_BUNDLE}" 16339 16340 16341 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 16342 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16343 # unpack200.exe. This variable is used in 16344 # FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER. 16345 if test "x$OPENJDK_BUILD_OS" = xlinux || test "x$OPENJDK_BUILD_OS" = xmacosx; then 16346 OPENJDK_BUILD_ADD_LP64="-D_LP64=1" 16347 fi 16348 fi 16349 16350 if test "x$COMPILE_TYPE" = "xcross"; then 16351 # FIXME: ... or should this include reduced builds..? 16352 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_BUILD_CPU_LEGACY" 16353 else 16354 DEFINE_CROSS_COMPILE_ARCH="" 16355 fi 16356 16357 16358 # Convert openjdk platform names to hotspot names 16359 16360 HOTSPOT_BUILD_OS=${OPENJDK_BUILD_OS} 16361 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16362 HOTSPOT_BUILD_OS=bsd 16363 fi 16364 16365 16366 HOTSPOT_BUILD_OS_TYPE=${OPENJDK_BUILD_OS_TYPE} 16367 if test "x$OPENJDK_BUILD_OS_TYPE" = xunix; then 16368 HOTSPOT_BUILD_OS_TYPE=posix 16369 fi 16370 16371 16372 HOTSPOT_BUILD_CPU=${OPENJDK_BUILD_CPU} 16373 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16374 HOTSPOT_BUILD_CPU=x86_32 16375 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16376 HOTSPOT_BUILD_CPU=sparc 16377 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16378 HOTSPOT_BUILD_CPU=ppc_64 16379 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16380 HOTSPOT_BUILD_CPU=ppc_64 16381 fi 16382 16383 16384 # This is identical with OPENJDK_*, but define anyway for consistency. 16385 HOTSPOT_BUILD_CPU_ARCH=${OPENJDK_BUILD_CPU_ARCH} 16386 16387 16388 # Setup HOTSPOT_BUILD_CPU_DEFINE 16389 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16390 HOTSPOT_BUILD_CPU_DEFINE=IA32 16391 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16392 HOTSPOT_BUILD_CPU_DEFINE=AMD64 16393 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16394 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16395 elif test "x$OPENJDK_BUILD_CPU" = xaarch64; then 16396 HOTSPOT_BUILD_CPU_DEFINE=AARCH64 16397 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16398 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16399 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16400 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16401 16402 # The cpu defines below are for zero, we don't support them directly. 16403 elif test "x$OPENJDK_BUILD_CPU" = xsparc; then 16404 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16405 elif test "x$OPENJDK_BUILD_CPU" = xppc; then 16406 HOTSPOT_BUILD_CPU_DEFINE=PPC32 16407 elif test "x$OPENJDK_BUILD_CPU" = xs390; then 16408 HOTSPOT_BUILD_CPU_DEFINE=S390 16409 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 16410 HOTSPOT_BUILD_CPU_DEFINE=S390 16411 elif test "x$OPENJDK_BUILD_CPU" != x; then 16412 HOTSPOT_BUILD_CPU_DEFINE=$(echo $OPENJDK_BUILD_CPU | tr a-z A-Z) 16413 fi 16414 16415 16416 16417 16418 16419 16420 # Continue setting up basic stuff. Most remaining code require fundamental tools. 16421 16422 # Save the current directory this script was started from 16423 CURDIR="$PWD" 16424 16425 # We might need to rewrite ORIGINAL_PATH, if it includes "#", to quote them 16426 # for make. We couldn't do this when we retrieved ORIGINAL_PATH, since SED 16427 # was not available at that time. 16428 REWRITTEN_PATH=`$ECHO "$ORIGINAL_PATH" | $SED -e 's/#/\\\\#/g'` 16429 if test "x$REWRITTEN_PATH" != "x$ORIGINAL_PATH"; then 16430 ORIGINAL_PATH="$REWRITTEN_PATH" 16431 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&5 16432 $as_echo "$as_me: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&6;} 16433 fi 16434 16435 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16436 PATH_SEP=";" 16437 16438 SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m` 16439 if test $SRC_ROOT_LENGTH -gt 100; then 16440 as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5 16441 fi 16442 16443 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5 16445 $as_echo_n "checking cygwin release... " >&6; } 16446 CYGWIN_VERSION=`$UNAME -r` 16447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5 16448 $as_echo "$CYGWIN_VERSION" >&6; } 16449 WINDOWS_ENV_VENDOR='cygwin' 16450 WINDOWS_ENV_VERSION="$CYGWIN_VERSION" 16451 16452 CYGWIN_VERSION_OLD=`$ECHO $CYGWIN_VERSION | $GREP -e '^1\.0-6'` 16453 if test "x$CYGWIN_VERSION_OLD" != x; then 16454 { $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 16455 $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;} 16456 as_fn_error $? "Cannot continue" "$LINENO" 5 16457 fi 16458 if test "x$CYGPATH" = x; then 16459 as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5 16460 fi 16461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 16462 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } 16463 # The cmd output ends with Windows line endings (CR/LF) 16464 cygwin_winpath_root=`cd / ; cmd /c cd | $TR -d '\r\n'` 16465 # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. 16466 CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` 16467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 16468 $as_echo "$CYGWIN_ROOT_PATH" >&6; } 16469 WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH" 16470 test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/` 16471 if test "x$test_cygdrive_prefix" = x; then 16472 as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5 16473 fi 16474 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5 16476 $as_echo_n "checking msys release... " >&6; } 16477 MSYS_VERSION=`$UNAME -r` 16478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5 16479 $as_echo "$MSYS_VERSION" >&6; } 16480 16481 WINDOWS_ENV_VENDOR='msys' 16482 WINDOWS_ENV_VERSION="$MSYS_VERSION" 16483 16484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5 16485 $as_echo_n "checking msys root directory as unix-style path... " >&6; } 16486 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 16487 MSYS_ROOT_PATH=`cd / ; cmd /c cd | $GREP ".*"` 16488 16489 windows_path="$MSYS_ROOT_PATH" 16490 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16491 unix_path=`$CYGPATH -u "$windows_path"` 16492 MSYS_ROOT_PATH="$unix_path" 16493 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16494 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16495 MSYS_ROOT_PATH="$unix_path" 16496 fi 16497 16498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5 16499 $as_echo "$MSYS_ROOT_PATH" >&6; } 16500 WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH" 16501 else 16502 as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5 16503 fi 16504 16505 # Test if windows or unix (cygwin/msys) find is first in path. 16506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5 16507 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; } 16508 FIND_BINARY_OUTPUT=`find --version 2>&1` 16509 if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then 16510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5 16511 $as_echo "unix style" >&6; } 16512 elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then 16513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5 16514 $as_echo "Windows" >&6; } 16515 { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5 16516 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;} 16517 { $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 16518 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;} 16519 as_fn_error $? "Cannot continue" "$LINENO" 5 16520 else 16521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 16522 $as_echo "unknown" >&6; } 16523 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5 16524 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;} 16525 fi 16526 16527 else 16528 PATH_SEP=":" 16529 fi 16530 16531 16532 # We get the top-level directory from the supporting wrappers. 16533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5 16534 $as_echo_n "checking for top-level directory... " >&6; } 16535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5 16536 $as_echo "$TOPDIR" >&6; } 16537 16538 16539 # Save the original version of TOPDIR for string comparisons 16540 ORIGINAL_TOPDIR="$TOPDIR" 16541 16542 16543 # We can only call BASIC_FIXUP_PATH after BASIC_CHECK_PATHS_WINDOWS. 16544 16545 # Only process if variable expands to non-empty 16546 16547 if test "x$CURDIR" != x; then 16548 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16549 16550 # Input might be given as Windows format, start by converting to 16551 # unix format. 16552 path="$CURDIR" 16553 new_path=`$CYGPATH -u "$path"` 16554 16555 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16556 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16557 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16558 # "foo.exe" is OK but "foo" is an error. 16559 # 16560 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16561 # It is also a way to make sure we got the proper file name for the real test later on. 16562 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16563 if test "x$test_shortpath" = x; then 16564 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16565 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16566 as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5 16567 fi 16568 16569 # Call helper function which possibly converts this using DOS-style short mode. 16570 # If so, the updated path is stored in $new_path. 16571 16572 input_path="$new_path" 16573 # Check if we need to convert this using DOS-style short mode. If the path 16574 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16575 # take no chances and rewrite it. 16576 # Note: m4 eats our [], so we need to use [ and ] instead. 16577 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16578 if test "x$has_forbidden_chars" != x; then 16579 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16580 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16581 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16582 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16583 # Going to short mode and back again did indeed matter. Since short mode is 16584 # case insensitive, let's make it lowercase to improve readability. 16585 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16586 # Now convert it back to Unix-style (cygpath) 16587 input_path=`$CYGPATH -u "$shortmode_path"` 16588 new_path="$input_path" 16589 fi 16590 fi 16591 16592 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16593 if test "x$test_cygdrive_prefix" = x; then 16594 # As a simple fix, exclude /usr/bin since it's not a real path. 16595 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16596 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16597 # a path prefixed by /cygdrive for fixpath to work. 16598 new_path="$CYGWIN_ROOT_PATH$input_path" 16599 fi 16600 fi 16601 16602 16603 if test "x$path" != "x$new_path"; then 16604 CURDIR="$new_path" 16605 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16606 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16607 fi 16608 16609 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16610 16611 path="$CURDIR" 16612 has_colon=`$ECHO $path | $GREP ^.:` 16613 new_path="$path" 16614 if test "x$has_colon" = x; then 16615 # Not in mixed or Windows style, start by that. 16616 new_path=`cmd //c echo $path` 16617 fi 16618 16619 16620 input_path="$new_path" 16621 # Check if we need to convert this using DOS-style short mode. If the path 16622 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16623 # take no chances and rewrite it. 16624 # Note: m4 eats our [], so we need to use [ and ] instead. 16625 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16626 if test "x$has_forbidden_chars" != x; then 16627 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16628 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16629 fi 16630 16631 16632 windows_path="$new_path" 16633 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16634 unix_path=`$CYGPATH -u "$windows_path"` 16635 new_path="$unix_path" 16636 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16637 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16638 new_path="$unix_path" 16639 fi 16640 16641 if test "x$path" != "x$new_path"; then 16642 CURDIR="$new_path" 16643 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16644 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16645 fi 16646 16647 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16648 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16649 16650 else 16651 # We're on a unix platform. Hooray! :) 16652 path="$CURDIR" 16653 has_space=`$ECHO "$path" | $GREP " "` 16654 if test "x$has_space" != x; then 16655 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16656 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16657 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16658 fi 16659 16660 # Use eval to expand a potential ~ 16661 eval path="$path" 16662 if test ! -f "$path" && test ! -d "$path"; then 16663 as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16664 fi 16665 16666 if test -d "$path"; then 16667 CURDIR="`cd "$path"; $THEPWDCMD -L`" 16668 else 16669 dir="`$DIRNAME "$path"`" 16670 base="`$BASENAME "$path"`" 16671 CURDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16672 fi 16673 fi 16674 fi 16675 16676 16677 # Only process if variable expands to non-empty 16678 16679 if test "x$TOPDIR" != x; then 16680 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16681 16682 # Input might be given as Windows format, start by converting to 16683 # unix format. 16684 path="$TOPDIR" 16685 new_path=`$CYGPATH -u "$path"` 16686 16687 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16688 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16689 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16690 # "foo.exe" is OK but "foo" is an error. 16691 # 16692 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16693 # It is also a way to make sure we got the proper file name for the real test later on. 16694 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16695 if test "x$test_shortpath" = x; then 16696 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16697 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16698 as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5 16699 fi 16700 16701 # Call helper function which possibly converts this using DOS-style short mode. 16702 # If so, the updated path is stored in $new_path. 16703 16704 input_path="$new_path" 16705 # Check if we need to convert this using DOS-style short mode. If the path 16706 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16707 # take no chances and rewrite it. 16708 # Note: m4 eats our [], so we need to use [ and ] instead. 16709 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16710 if test "x$has_forbidden_chars" != x; then 16711 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16712 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16713 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16714 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16715 # Going to short mode and back again did indeed matter. Since short mode is 16716 # case insensitive, let's make it lowercase to improve readability. 16717 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16718 # Now convert it back to Unix-style (cygpath) 16719 input_path=`$CYGPATH -u "$shortmode_path"` 16720 new_path="$input_path" 16721 fi 16722 fi 16723 16724 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16725 if test "x$test_cygdrive_prefix" = x; then 16726 # As a simple fix, exclude /usr/bin since it's not a real path. 16727 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16728 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16729 # a path prefixed by /cygdrive for fixpath to work. 16730 new_path="$CYGWIN_ROOT_PATH$input_path" 16731 fi 16732 fi 16733 16734 16735 if test "x$path" != "x$new_path"; then 16736 TOPDIR="$new_path" 16737 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16738 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16739 fi 16740 16741 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16742 16743 path="$TOPDIR" 16744 has_colon=`$ECHO $path | $GREP ^.:` 16745 new_path="$path" 16746 if test "x$has_colon" = x; then 16747 # Not in mixed or Windows style, start by that. 16748 new_path=`cmd //c echo $path` 16749 fi 16750 16751 16752 input_path="$new_path" 16753 # Check if we need to convert this using DOS-style short mode. If the path 16754 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16755 # take no chances and rewrite it. 16756 # Note: m4 eats our [], so we need to use [ and ] instead. 16757 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16758 if test "x$has_forbidden_chars" != x; then 16759 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16760 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16761 fi 16762 16763 16764 windows_path="$new_path" 16765 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16766 unix_path=`$CYGPATH -u "$windows_path"` 16767 new_path="$unix_path" 16768 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16769 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16770 new_path="$unix_path" 16771 fi 16772 16773 if test "x$path" != "x$new_path"; then 16774 TOPDIR="$new_path" 16775 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16776 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16777 fi 16778 16779 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16780 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16781 16782 else 16783 # We're on a unix platform. Hooray! :) 16784 path="$TOPDIR" 16785 has_space=`$ECHO "$path" | $GREP " "` 16786 if test "x$has_space" != x; then 16787 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16788 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16789 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16790 fi 16791 16792 # Use eval to expand a potential ~ 16793 eval path="$path" 16794 if test ! -f "$path" && test ! -d "$path"; then 16795 as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16796 fi 16797 16798 if test -d "$path"; then 16799 TOPDIR="`cd "$path"; $THEPWDCMD -L`" 16800 else 16801 dir="`$DIRNAME "$path"`" 16802 base="`$BASENAME "$path"`" 16803 TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16804 fi 16805 fi 16806 fi 16807 16808 16809 # Calculate a canonical version of TOPDIR for string comparisons 16810 CANONICAL_TOPDIR=$TOPDIR 16811 16812 if test "x$OPENJDK_BUILD_OS" != xwindows; then 16813 # Follow a chain of symbolic links. Use readlink 16814 # where it exists, else fall back to horribly 16815 # complicated shell code. 16816 if test "x$READLINK_TESTED" != yes; then 16817 # On MacOSX there is a readlink tool with a different 16818 # purpose than the GNU readlink tool. Check the found readlink. 16819 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 16820 if test "x$ISGNU" = x; then 16821 # A readlink that we do not know how to use. 16822 # Are there other non-GNU readlinks out there? 16823 READLINK_TESTED=yes 16824 READLINK= 16825 fi 16826 fi 16827 16828 if test "x$READLINK" != x; then 16829 CANONICAL_TOPDIR=`$READLINK -f $CANONICAL_TOPDIR` 16830 else 16831 # Save the current directory for restoring afterwards 16832 STARTDIR=$PWD 16833 COUNTER=0 16834 sym_link_dir=`$DIRNAME $CANONICAL_TOPDIR` 16835 sym_link_file=`$BASENAME $CANONICAL_TOPDIR` 16836 cd $sym_link_dir 16837 # Use -P flag to resolve symlinks in directories. 16838 cd `$THEPWDCMD -P` 16839 sym_link_dir=`$THEPWDCMD -P` 16840 # Resolve file symlinks 16841 while test $COUNTER -lt 20; do 16842 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 16843 if test "x$ISLINK" == x; then 16844 # This is not a symbolic link! We are done! 16845 break 16846 fi 16847 # Again resolve directory symlinks since the target of the just found 16848 # link could be in a different directory 16849 cd `$DIRNAME $ISLINK` 16850 sym_link_dir=`$THEPWDCMD -P` 16851 sym_link_file=`$BASENAME $ISLINK` 16852 let COUNTER=COUNTER+1 16853 done 16854 cd $STARTDIR 16855 CANONICAL_TOPDIR=$sym_link_dir/$sym_link_file 16856 fi 16857 fi 16858 16859 16860 16861 # Locate the directory of this script. 16862 AUTOCONF_DIR=$TOPDIR/make/autoconf 16863 16864 # Setup username (for use in adhoc version strings etc) 16865 # Outer [ ] to quote m4. 16866 USERNAME=`$ECHO "$USER" | $TR -d -c '[a-z][A-Z][0-9]'` 16867 16868 16869 16870 # Check if it's a pure open build or if custom sources are to be used. 16871 16872 # Check whether --enable-openjdk-only was given. 16873 if test "${enable_openjdk_only+set}" = set; then : 16874 enableval=$enable_openjdk_only; 16875 else 16876 enable_openjdk_only="no" 16877 fi 16878 16879 16880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if custom source is suppressed (openjdk-only)" >&5 16881 $as_echo_n "checking if custom source is suppressed (openjdk-only)... " >&6; } 16882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_openjdk_only" >&5 16883 $as_echo "$enable_openjdk_only" >&6; } 16884 if test "x$enable_openjdk_only" = "xyes"; then 16885 SUPPRESS_CUSTOM_EXTENSIONS="true" 16886 elif test "x$enable_openjdk_only" = "xno"; then 16887 SUPPRESS_CUSTOM_EXTENSIONS="false" 16888 else 16889 as_fn_error $? "Invalid value for --enable-openjdk-only: $enable_openjdk_only" "$LINENO" 5 16890 fi 16891 16892 # custom-make-dir is deprecated. Please use your custom-hook.m4 to override 16893 # the IncludeCustomExtension macro. 16894 16895 16896 # Check whether --with-custom-make-dir was given. 16897 if test "${with_custom_make_dir+set}" = set; then : 16898 withval=$with_custom_make_dir; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&5 16899 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;} 16900 fi 16901 16902 16903 16904 16905 # These are needed to be able to create a configuration name (and thus the output directory) 16906 16907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5 16908 $as_echo_n "checking which variant of the JDK to build... " >&6; } 16909 16910 # Check whether --with-jdk-variant was given. 16911 if test "${with_jdk_variant+set}" = set; then : 16912 withval=$with_jdk_variant; 16913 fi 16914 16915 16916 if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then 16917 JDK_VARIANT="normal" 16918 else 16919 as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5 16920 fi 16921 16922 16923 16924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5 16925 $as_echo "$JDK_VARIANT" >&6; } 16926 16927 16928 DEBUG_LEVEL="release" 16929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5 16930 $as_echo_n "checking which debug level to use... " >&6; } 16931 # Check whether --enable-debug was given. 16932 if test "${enable_debug+set}" = set; then : 16933 enableval=$enable_debug; 16934 ENABLE_DEBUG="${enableval}" 16935 DEBUG_LEVEL="fastdebug" 16936 16937 else 16938 ENABLE_DEBUG="no" 16939 fi 16940 16941 16942 16943 # Check whether --with-debug-level was given. 16944 if test "${with_debug_level+set}" = set; then : 16945 withval=$with_debug_level; 16946 DEBUG_LEVEL="${withval}" 16947 if test "x$ENABLE_DEBUG" = xyes; then 16948 as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5 16949 fi 16950 16951 fi 16952 16953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5 16954 $as_echo "$DEBUG_LEVEL" >&6; } 16955 16956 if test "x$DEBUG_LEVEL" != xrelease && \ 16957 test "x$DEBUG_LEVEL" != xoptimized && \ 16958 test "x$DEBUG_LEVEL" != xfastdebug && \ 16959 test "x$DEBUG_LEVEL" != xslowdebug; then 16960 as_fn_error $? "Allowed debug levels are: release, fastdebug, slowdebug and optimized" "$LINENO" 5 16961 fi 16962 16963 # Translate DEBUG_LEVEL to debug level used by Hotspot 16964 HOTSPOT_DEBUG_LEVEL="$DEBUG_LEVEL" 16965 if test "x$DEBUG_LEVEL" = xrelease; then 16966 HOTSPOT_DEBUG_LEVEL="product" 16967 elif test "x$DEBUG_LEVEL" = xslowdebug; then 16968 HOTSPOT_DEBUG_LEVEL="debug" 16969 fi 16970 16971 if test "x$DEBUG_LEVEL" = xoptimized; then 16972 # The debug level 'optimized' is a little special because it is currently only 16973 # applicable to the HotSpot build where it means to build a completely 16974 # optimized version of the VM without any debugging code (like for the 16975 # 'release' debug level which is called 'product' in the HotSpot build) but 16976 # with the exception that it can contain additional code which is otherwise 16977 # protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to 16978 # test new and/or experimental features which are not intended for customer 16979 # shipment. Because these new features need to be tested and benchmarked in 16980 # real world scenarios, we want to build the containing JDK at the 'release' 16981 # debug level. 16982 DEBUG_LEVEL="release" 16983 fi 16984 16985 16986 16987 16988 16989 16990 # Check whether --with-jvm-variants was given. 16991 if test "${with_jvm_variants+set}" = set; then : 16992 withval=$with_jvm_variants; 16993 fi 16994 16995 16996 16997 16998 # Check whether --with-cpu-port was given. 16999 if test "${with_cpu_port+set}" = set; then : 17000 withval=$with_cpu_port; 17001 fi 17002 17003 17004 if test "x$with_cpu_port" != x; then 17005 if test "x$OPENJDK_TARGET_CPU" != xaarch64; then 17006 as_fn_error $? "--with-cpu-port only available on aarch64" "$LINENO" 5 17007 fi 17008 if test "x$with_cpu_port" != xarm64 && \ 17009 test "x$with_cpu_port" != xaarch64; then 17010 as_fn_error $? "--with-cpu-port must specify arm64 or aarch64" "$LINENO" 5 17011 fi 17012 HOTSPOT_TARGET_CPU_PORT="$with_cpu_port" 17013 fi 17014 17015 17016 if test "x$with_jvm_variants" = x; then 17017 with_jvm_variants="server" 17018 fi 17019 JVM_VARIANTS_OPT="$with_jvm_variants" 17020 17021 # Has the user listed more than one variant? 17022 # Additional [] needed to keep m4 from mangling shell constructs. 17023 if [[ "$JVM_VARIANTS_OPT" =~ "," ]] ; then 17024 BUILDING_MULTIPLE_JVM_VARIANTS=true 17025 else 17026 BUILDING_MULTIPLE_JVM_VARIANTS=false 17027 fi 17028 # Replace the commas with AND for use in the build directory name. 17029 JVM_VARIANTS_WITH_AND=`$ECHO "$JVM_VARIANTS_OPT" | $SED -e 's/,/AND/g'` 17030 17031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5 17032 $as_echo_n "checking which variants of the JVM to build... " >&6; } 17033 # JVM_VARIANTS is a space-separated list. 17034 # Also use minimal, not minimal1 (which is kept for backwards compatibility). 17035 JVM_VARIANTS=`$ECHO $JVM_VARIANTS_OPT | $SED -e 's/,/ /g' -e 's/minimal1/minimal/'` 17036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_VARIANTS" >&5 17037 $as_echo "$JVM_VARIANTS" >&6; } 17038 17039 # Check that the selected variants are valid 17040 17041 # grep filter function inspired by a comment to http://stackoverflow.com/a/1617326 17042 # Notice that the original variant failes on SLES 10 and 11 17043 NEEDLE=${VALID_JVM_VARIANTS// /$'\n'} 17044 STACK=${JVM_VARIANTS// /$'\n'} 17045 INVALID_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 17046 if test "x$INVALID_VARIANTS" != x; then 17047 { $as_echo "$as_me:${as_lineno-$LINENO}: Unknown variant(s) specified: $INVALID_VARIANTS" >&5 17048 $as_echo "$as_me: Unknown variant(s) specified: $INVALID_VARIANTS" >&6;} 17049 as_fn_error $? "The available JVM variants are: $VALID_JVM_VARIANTS" "$LINENO" 5 17050 fi 17051 17052 # All "special" variants share the same output directory ("server") 17053 VALID_MULTIPLE_JVM_VARIANTS="server client minimal" 17054 NEEDLE=${VALID_MULTIPLE_JVM_VARIANTS// /$'\n'} 17055 STACK=${JVM_VARIANTS// /$'\n'} 17056 INVALID_MULTIPLE_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 17057 if test "x$INVALID_MULTIPLE_VARIANTS" != x && test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = xtrue; then 17058 as_fn_error $? "You cannot build multiple variants with anything else than $VALID_MULTIPLE_JVM_VARIANTS." "$LINENO" 5 17059 fi 17060 17061 # The "main" variant is the one used by other libs to link against during the 17062 # build. 17063 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 17064 MAIN_VARIANT_PRIO_ORDER="server client minimal" 17065 for variant in $MAIN_VARIANT_PRIO_ORDER; do 17066 if [[ " $JVM_VARIANTS " =~ " $variant " ]] ; then 17067 JVM_VARIANT_MAIN="$variant" 17068 break 17069 fi 17070 done 17071 else 17072 JVM_VARIANT_MAIN="$JVM_VARIANTS" 17073 fi 17074 17075 17076 17077 17078 17079 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 17080 # zero behaves as a platform and rewrites these values. This is really weird. :( 17081 # We are guaranteed that we do not build any other variants when building zero. 17082 HOTSPOT_TARGET_CPU=zero 17083 HOTSPOT_TARGET_CPU_ARCH=zero 17084 fi 17085 17086 17087 # With basic setup done, call the custom early hook. 17088 17089 17090 # Check if we have devkits, extra paths or sysroot set. 17091 17092 17093 # Check whether --with-devkit was given. 17094 if test "${with_devkit+set}" = set; then : 17095 withval=$with_devkit; 17096 17097 # Only process if variable expands to non-empty 17098 17099 if test "x$with_devkit" != x; then 17100 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17101 17102 # Input might be given as Windows format, start by converting to 17103 # unix format. 17104 path="$with_devkit" 17105 new_path=`$CYGPATH -u "$path"` 17106 17107 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17108 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17109 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17110 # "foo.exe" is OK but "foo" is an error. 17111 # 17112 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17113 # It is also a way to make sure we got the proper file name for the real test later on. 17114 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17115 if test "x$test_shortpath" = x; then 17116 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 17117 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 17118 as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5 17119 fi 17120 17121 # Call helper function which possibly converts this using DOS-style short mode. 17122 # If so, the updated path is stored in $new_path. 17123 17124 input_path="$new_path" 17125 # Check if we need to convert this using DOS-style short mode. If the path 17126 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17127 # take no chances and rewrite it. 17128 # Note: m4 eats our [], so we need to use [ and ] instead. 17129 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17130 if test "x$has_forbidden_chars" != x; then 17131 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17132 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17133 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17134 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17135 # Going to short mode and back again did indeed matter. Since short mode is 17136 # case insensitive, let's make it lowercase to improve readability. 17137 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17138 # Now convert it back to Unix-style (cygpath) 17139 input_path=`$CYGPATH -u "$shortmode_path"` 17140 new_path="$input_path" 17141 fi 17142 fi 17143 17144 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17145 if test "x$test_cygdrive_prefix" = x; then 17146 # As a simple fix, exclude /usr/bin since it's not a real path. 17147 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17148 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17149 # a path prefixed by /cygdrive for fixpath to work. 17150 new_path="$CYGWIN_ROOT_PATH$input_path" 17151 fi 17152 fi 17153 17154 17155 if test "x$path" != "x$new_path"; then 17156 with_devkit="$new_path" 17157 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 17158 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 17159 fi 17160 17161 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17162 17163 path="$with_devkit" 17164 has_colon=`$ECHO $path | $GREP ^.:` 17165 new_path="$path" 17166 if test "x$has_colon" = x; then 17167 # Not in mixed or Windows style, start by that. 17168 new_path=`cmd //c echo $path` 17169 fi 17170 17171 17172 input_path="$new_path" 17173 # Check if we need to convert this using DOS-style short mode. If the path 17174 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17175 # take no chances and rewrite it. 17176 # Note: m4 eats our [], so we need to use [ and ] instead. 17177 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17178 if test "x$has_forbidden_chars" != x; then 17179 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17180 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17181 fi 17182 17183 17184 windows_path="$new_path" 17185 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17186 unix_path=`$CYGPATH -u "$windows_path"` 17187 new_path="$unix_path" 17188 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17189 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17190 new_path="$unix_path" 17191 fi 17192 17193 if test "x$path" != "x$new_path"; then 17194 with_devkit="$new_path" 17195 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 17196 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 17197 fi 17198 17199 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17200 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17201 17202 else 17203 # We're on a unix platform. Hooray! :) 17204 path="$with_devkit" 17205 has_space=`$ECHO "$path" | $GREP " "` 17206 if test "x$has_space" != x; then 17207 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 17208 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 17209 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17210 fi 17211 17212 # Use eval to expand a potential ~ 17213 eval path="$path" 17214 if test ! -f "$path" && test ! -d "$path"; then 17215 as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 17216 fi 17217 17218 if test -d "$path"; then 17219 with_devkit="`cd "$path"; $THEPWDCMD -L`" 17220 else 17221 dir="`$DIRNAME "$path"`" 17222 base="`$BASENAME "$path"`" 17223 with_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 17224 fi 17225 fi 17226 fi 17227 17228 DEVKIT_ROOT="$with_devkit" 17229 # Check for a meta data info file in the root of the devkit 17230 if test -f "$DEVKIT_ROOT/devkit.info"; then 17231 . $DEVKIT_ROOT/devkit.info 17232 # This potentially sets the following: 17233 # A descriptive name of the devkit 17234 17235 if test "x$DEVKIT_NAME" = x; then 17236 eval DEVKIT_NAME="\${DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 17237 fi 17238 17239 # Corresponds to --with-extra-path 17240 17241 if test "x$DEVKIT_EXTRA_PATH" = x; then 17242 eval DEVKIT_EXTRA_PATH="\${DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 17243 fi 17244 17245 # Corresponds to --with-toolchain-path 17246 17247 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 17248 eval DEVKIT_TOOLCHAIN_PATH="\${DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 17249 fi 17250 17251 # Corresponds to --with-sysroot 17252 17253 if test "x$DEVKIT_SYSROOT" = x; then 17254 eval DEVKIT_SYSROOT="\${DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 17255 fi 17256 17257 17258 # Identifies the Visual Studio version in the devkit 17259 17260 if test "x$DEVKIT_VS_VERSION" = x; then 17261 eval DEVKIT_VS_VERSION="\${DEVKIT_VS_VERSION_${OPENJDK_TARGET_CPU}}" 17262 fi 17263 17264 # The Visual Studio include environment variable 17265 17266 if test "x$DEVKIT_VS_INCLUDE" = x; then 17267 eval DEVKIT_VS_INCLUDE="\${DEVKIT_VS_INCLUDE_${OPENJDK_TARGET_CPU}}" 17268 fi 17269 17270 # The Visual Studio lib environment variable 17271 17272 if test "x$DEVKIT_VS_LIB" = x; then 17273 eval DEVKIT_VS_LIB="\${DEVKIT_VS_LIB_${OPENJDK_TARGET_CPU}}" 17274 fi 17275 17276 # Corresponds to --with-msvcr-dll 17277 17278 if test "x$DEVKIT_MSVCR_DLL" = x; then 17279 eval DEVKIT_MSVCR_DLL="\${DEVKIT_MSVCR_DLL_${OPENJDK_TARGET_CPU}}" 17280 fi 17281 17282 # Corresponds to --with-msvcp-dll 17283 17284 if test "x$DEVKIT_MSVCP_DLL" = x; then 17285 eval DEVKIT_MSVCP_DLL="\${DEVKIT_MSVCP_DLL_${OPENJDK_TARGET_CPU}}" 17286 fi 17287 17288 fi 17289 17290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5 17291 $as_echo_n "checking for devkit... " >&6; } 17292 if test "x$DEVKIT_NAME" != x; then 17293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5 17294 $as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; } 17295 else 17296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5 17297 $as_echo "$DEVKIT_ROOT" >&6; } 17298 fi 17299 17300 17301 if test "x$DEVKIT_EXTRA_PATH" != x; then 17302 if test "x$EXTRA_PATH" = x; then 17303 EXTRA_PATH="$DEVKIT_EXTRA_PATH" 17304 else 17305 EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH" 17306 fi 17307 fi 17308 17309 17310 # Fallback default of just /bin if DEVKIT_PATH is not defined 17311 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 17312 DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin" 17313 fi 17314 17315 if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then 17316 if test "x$TOOLCHAIN_PATH" = x; then 17317 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH" 17318 else 17319 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH" 17320 fi 17321 fi 17322 17323 17324 # If DEVKIT_SYSROOT is set, use that, otherwise try a couple of known 17325 # places for backwards compatiblity. 17326 if test "x$DEVKIT_SYSROOT" != x; then 17327 SYSROOT="$DEVKIT_SYSROOT" 17328 elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then 17329 SYSROOT="$DEVKIT_ROOT/$host_alias/libc" 17330 elif test -d "$DEVKIT_ROOT/$host/sys-root"; then 17331 SYSROOT="$DEVKIT_ROOT/$host/sys-root" 17332 fi 17333 17334 17335 fi 17336 17337 17338 # You can force the sysroot if the sysroot encoded into the compiler tools 17339 # is not correct. 17340 17341 # Check whether --with-sys-root was given. 17342 if test "${with_sys_root+set}" = set; then : 17343 withval=$with_sys_root; SYSROOT=$with_sys_root 17344 17345 fi 17346 17347 17348 17349 # Check whether --with-sysroot was given. 17350 if test "${with_sysroot+set}" = set; then : 17351 withval=$with_sysroot; SYSROOT=$with_sysroot 17352 17353 fi 17354 17355 17356 17357 # Check whether --with-tools-dir was given. 17358 if test "${with_tools_dir+set}" = set; then : 17359 withval=$with_tools_dir; 17360 if test "x$with_tools_dir" != x; then 17361 if test "x$TOOLCHAIN_PATH" = x; then 17362 TOOLCHAIN_PATH="$with_tools_dir" 17363 else 17364 TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH" 17365 fi 17366 fi 17367 17368 17369 fi 17370 17371 17372 17373 # Check whether --with-toolchain-path was given. 17374 if test "${with_toolchain_path+set}" = set; then : 17375 withval=$with_toolchain_path; 17376 if test "x$with_toolchain_path" != x; then 17377 if test "x$TOOLCHAIN_PATH" = x; then 17378 TOOLCHAIN_PATH="$with_toolchain_path" 17379 else 17380 TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH" 17381 fi 17382 fi 17383 17384 17385 fi 17386 17387 17388 17389 # Check whether --with-extra-path was given. 17390 if test "${with_extra_path+set}" = set; then : 17391 withval=$with_extra_path; 17392 if test "x$with_extra_path" != x; then 17393 if test "x$EXTRA_PATH" = x; then 17394 EXTRA_PATH="$with_extra_path" 17395 else 17396 EXTRA_PATH="$with_extra_path:$EXTRA_PATH" 17397 fi 17398 fi 17399 17400 17401 fi 17402 17403 17404 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 17405 # If a devkit has been supplied, find xcodebuild in the toolchain_path. 17406 # If not, detect if Xcode is installed by running xcodebuild -version 17407 # if no Xcode installed, xcodebuild exits with 1 17408 # if Xcode is installed, even if xcode-select is misconfigured, then it exits with 0 17409 if test "x$DEVKIT_ROOT" != x || /usr/bin/xcodebuild -version >/dev/null 2>&1; then 17410 # We need to use xcodebuild in the toolchain dir provided by the user, this will 17411 # fall back on the stub binary in /usr/bin/xcodebuild 17412 # Extract the first word of "xcodebuild", so it can be a program name with args. 17413 set dummy xcodebuild; ac_word=$2 17414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17415 $as_echo_n "checking for $ac_word... " >&6; } 17416 if ${ac_cv_path_XCODEBUILD+:} false; then : 17417 $as_echo_n "(cached) " >&6 17418 else 17419 case $XCODEBUILD in 17420 [\\/]* | ?:[\\/]*) 17421 ac_cv_path_XCODEBUILD="$XCODEBUILD" # Let the user override the test with a path. 17422 ;; 17423 *) 17424 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17425 for as_dir in $TOOLCHAIN_PATH 17426 do 17427 IFS=$as_save_IFS 17428 test -z "$as_dir" && as_dir=. 17429 for ac_exec_ext in '' $ac_executable_extensions; do 17430 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17431 ac_cv_path_XCODEBUILD="$as_dir/$ac_word$ac_exec_ext" 17432 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17433 break 2 17434 fi 17435 done 17436 done 17437 IFS=$as_save_IFS 17438 17439 test -z "$ac_cv_path_XCODEBUILD" && ac_cv_path_XCODEBUILD="/usr/bin/xcodebuild" 17440 ;; 17441 esac 17442 fi 17443 XCODEBUILD=$ac_cv_path_XCODEBUILD 17444 if test -n "$XCODEBUILD"; then 17445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCODEBUILD" >&5 17446 $as_echo "$XCODEBUILD" >&6; } 17447 else 17448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17449 $as_echo "no" >&6; } 17450 fi 17451 17452 17453 else 17454 # this should result in SYSROOT being empty, unless --with-sysroot is provided 17455 # when only the command line tools are installed there are no SDKs, so headers 17456 # are copied into the system frameworks 17457 XCODEBUILD= 17458 17459 fi 17460 17461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sdk name" >&5 17462 $as_echo_n "checking for sdk name... " >&6; } 17463 17464 # Check whether --with-sdk-name was given. 17465 if test "${with_sdk_name+set}" = set; then : 17466 withval=$with_sdk_name; SDKNAME=$with_sdk_name 17467 17468 fi 17469 17470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SDKNAME" >&5 17471 $as_echo "$SDKNAME" >&6; } 17472 17473 # if toolchain path is specified then don't rely on system headers, they may not compile 17474 HAVE_SYSTEM_FRAMEWORK_HEADERS=0 17475 test -z "$TOOLCHAIN_PATH" && \ 17476 HAVE_SYSTEM_FRAMEWORK_HEADERS=`test ! -f /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h; echo $?` 17477 17478 if test -z "$SYSROOT"; then 17479 if test -n "$XCODEBUILD"; then 17480 # if we don't have system headers, use default SDK name (last resort) 17481 if test -z "$SDKNAME" -a $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17482 SDKNAME=${SDKNAME:-macosx} 17483 fi 17484 17485 if test -n "$SDKNAME"; then 17486 # Call xcodebuild to determine SYSROOT 17487 SYSROOT=`"$XCODEBUILD" -sdk $SDKNAME -version | $GREP '^Path: ' | $SED 's/Path: //'` 17488 fi 17489 else 17490 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17491 as_fn_error $? "No xcodebuild tool and no system framework headers found, use --with-sysroot or --with-sdk-name to provide a path to a valid SDK" "$LINENO" 5 17492 fi 17493 fi 17494 else 17495 # warn user if --with-sdk-name was also set 17496 if test -n "$with_sdk_name"; then 17497 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&5 17498 $as_echo "$as_me: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&2;} 17499 fi 17500 fi 17501 17502 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0 -a -z "$SYSROOT"; then 17503 # If no system framework headers, then SYSROOT must be set, or we won't build 17504 as_fn_error $? "Unable to determine SYSROOT and no headers found in /System/Library/Frameworks. Check Xcode configuration, --with-sysroot or --with-sdk-name arguments." "$LINENO" 5 17505 fi 17506 17507 # Perform a basic sanity test 17508 if test ! -f "$SYSROOT/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h"; then 17509 if test -z "$SYSROOT"; then 17510 as_fn_error $? "Unable to find required framework headers, provide a path to an SDK via --with-sysroot or --with-sdk-name and be sure Xcode is installed properly" "$LINENO" 5 17511 else 17512 as_fn_error $? "Invalid SDK or SYSROOT path, dependent framework headers not found" "$LINENO" 5 17513 fi 17514 fi 17515 17516 # set SDKROOT too, Xcode tools will pick it up 17517 SDKROOT="$SYSROOT" 17518 17519 fi 17520 17521 # Prepend the extra path to the global path 17522 17523 if test "x$EXTRA_PATH" != x; then 17524 if test "x$PATH" = x; then 17525 PATH="$EXTRA_PATH" 17526 else 17527 PATH="$EXTRA_PATH:$PATH" 17528 fi 17529 fi 17530 17531 17532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 17533 $as_echo_n "checking for sysroot... " >&6; } 17534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5 17535 $as_echo "$SYSROOT" >&6; } 17536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5 17537 $as_echo_n "checking for toolchain path... " >&6; } 17538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5 17539 $as_echo "$TOOLCHAIN_PATH" >&6; } 17540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5 17541 $as_echo_n "checking for extra path... " >&6; } 17542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5 17543 $as_echo "$EXTRA_PATH" >&6; } 17544 17545 17546 # To properly create a configuration name, we need to have the OpenJDK target 17547 # and options (variants and debug level) parsed. 17548 17549 17550 17551 # Check whether --with-conf-name was given. 17552 if test "${with_conf_name+set}" = set; then : 17553 withval=$with_conf_name; CONF_NAME=${with_conf_name} 17554 fi 17555 17556 17557 # Check whether --with-output-base-dir was given. 17558 if test "${with_output_base_dir+set}" = set; then : 17559 withval=$with_output_base_dir; OUTPUT_BASE=${with_output_base_dir} 17560 else 17561 OUTPUT_BASE="$TOPDIR/build" 17562 fi 17563 17564 17565 # Test from where we are running configure, in or outside of src root. 17566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5 17567 $as_echo_n "checking where to store configuration... " >&6; } 17568 if test "x$CURDIR" = "x$TOPDIR" || test "x$CURDIR" = "x$TOPDIR/common" \ 17569 || test "x$CURDIR" = "x$TOPDIR/make/autoconf" \ 17570 || test "x$CURDIR" = "x$TOPDIR/make" ; then 17571 # We are running configure from the src root. 17572 # Create a default ./build/target-variant-debuglevel output root. 17573 if test "x${CONF_NAME}" = x; then 17574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5 17575 $as_echo "in default location" >&6; } 17576 CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${JVM_VARIANTS_WITH_AND}-${DEBUG_LEVEL}" 17577 else 17578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5 17579 $as_echo "in build directory with custom name" >&6; } 17580 fi 17581 OUTPUTDIR="${OUTPUT_BASE}/${CONF_NAME}" 17582 $MKDIR -p "$OUTPUTDIR" 17583 if test ! -d "$OUTPUTDIR"; then 17584 as_fn_error $? "Could not create build directory $OUTPUTDIR" "$LINENO" 5 17585 fi 17586 else 17587 # We are running configure from outside of the src dir. 17588 # Then use the current directory as output dir! 17589 # If configuration is situated in normal build directory, just use the build 17590 # directory name as configuration name, otherwise use the complete path. 17591 if test "x${CONF_NAME}" = x; then 17592 CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${TOPDIR}/build/!!"` 17593 fi 17594 OUTPUTDIR="$CURDIR" 17595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5 17596 $as_echo "in current directory" >&6; } 17597 17598 # WARNING: This might be a bad thing to do. You need to be sure you want to 17599 # have a configuration in this directory. Do some sanity checks! 17600 17601 if test ! -e "$OUTPUTDIR/spec.gmk"; then 17602 # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for 17603 # other files 17604 files_present=`$LS $OUTPUTDIR` 17605 # Configure has already touched config.log and confdefs.h in the current dir when this check 17606 # is performed. 17607 filtered_files=`$ECHO "$files_present" \ 17608 | $SED -e 's/config.log//g' \ 17609 -e 's/configure.log//g' \ 17610 -e 's/confdefs.h//g' \ 17611 -e 's/ //g' \ 17612 | $TR -d '\n'` 17613 if test "x$filtered_files" != x; then 17614 { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5 17615 $as_echo "$as_me: Current directory is $CURDIR." >&6;} 17616 { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5 17617 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;} 17618 { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5 17619 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;} 17620 { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5 17621 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;} 17622 { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5 17623 $as_echo "$as_me: seriously mess up just about everything." >&6;} 17624 { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $TOPDIR' and restart configure" >&5 17625 $as_echo "$as_me: Try 'cd $TOPDIR' and restart configure" >&6;} 17626 { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5 17627 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;} 17628 as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5 17629 fi 17630 fi 17631 fi 17632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5 17633 $as_echo_n "checking what configuration name to use... " >&6; } 17634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5 17635 $as_echo "$CONF_NAME" >&6; } 17636 17637 17638 # Only process if variable expands to non-empty 17639 17640 if test "x$OUTPUTDIR" != x; then 17641 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17642 17643 # Input might be given as Windows format, start by converting to 17644 # unix format. 17645 path="$OUTPUTDIR" 17646 new_path=`$CYGPATH -u "$path"` 17647 17648 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17649 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17650 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17651 # "foo.exe" is OK but "foo" is an error. 17652 # 17653 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17654 # It is also a way to make sure we got the proper file name for the real test later on. 17655 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17656 if test "x$test_shortpath" = x; then 17657 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUTDIR, which resolves as \"$path\", is invalid." >&5 17658 $as_echo "$as_me: The path of OUTPUTDIR, which resolves as \"$path\", is invalid." >&6;} 17659 as_fn_error $? "Cannot locate the the path of OUTPUTDIR" "$LINENO" 5 17660 fi 17661 17662 # Call helper function which possibly converts this using DOS-style short mode. 17663 # If so, the updated path is stored in $new_path. 17664 17665 input_path="$new_path" 17666 # Check if we need to convert this using DOS-style short mode. If the path 17667 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17668 # take no chances and rewrite it. 17669 # Note: m4 eats our [], so we need to use [ and ] instead. 17670 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17671 if test "x$has_forbidden_chars" != x; then 17672 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17673 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17674 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17675 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17676 # Going to short mode and back again did indeed matter. Since short mode is 17677 # case insensitive, let's make it lowercase to improve readability. 17678 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17679 # Now convert it back to Unix-style (cygpath) 17680 input_path=`$CYGPATH -u "$shortmode_path"` 17681 new_path="$input_path" 17682 fi 17683 fi 17684 17685 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17686 if test "x$test_cygdrive_prefix" = x; then 17687 # As a simple fix, exclude /usr/bin since it's not a real path. 17688 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17689 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17690 # a path prefixed by /cygdrive for fixpath to work. 17691 new_path="$CYGWIN_ROOT_PATH$input_path" 17692 fi 17693 fi 17694 17695 17696 if test "x$path" != "x$new_path"; then 17697 OUTPUTDIR="$new_path" 17698 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUTDIR to \"$new_path\"" >&5 17699 $as_echo "$as_me: Rewriting OUTPUTDIR to \"$new_path\"" >&6;} 17700 fi 17701 17702 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17703 17704 path="$OUTPUTDIR" 17705 has_colon=`$ECHO $path | $GREP ^.:` 17706 new_path="$path" 17707 if test "x$has_colon" = x; then 17708 # Not in mixed or Windows style, start by that. 17709 new_path=`cmd //c echo $path` 17710 fi 17711 17712 17713 input_path="$new_path" 17714 # Check if we need to convert this using DOS-style short mode. If the path 17715 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17716 # take no chances and rewrite it. 17717 # Note: m4 eats our [], so we need to use [ and ] instead. 17718 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17719 if test "x$has_forbidden_chars" != x; then 17720 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17721 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17722 fi 17723 17724 17725 windows_path="$new_path" 17726 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17727 unix_path=`$CYGPATH -u "$windows_path"` 17728 new_path="$unix_path" 17729 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17730 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17731 new_path="$unix_path" 17732 fi 17733 17734 if test "x$path" != "x$new_path"; then 17735 OUTPUTDIR="$new_path" 17736 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUTDIR to \"$new_path\"" >&5 17737 $as_echo "$as_me: Rewriting OUTPUTDIR to \"$new_path\"" >&6;} 17738 fi 17739 17740 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17741 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17742 17743 else 17744 # We're on a unix platform. Hooray! :) 17745 path="$OUTPUTDIR" 17746 has_space=`$ECHO "$path" | $GREP " "` 17747 if test "x$has_space" != x; then 17748 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUTDIR, which resolves as \"$path\", is invalid." >&5 17749 $as_echo "$as_me: The path of OUTPUTDIR, which resolves as \"$path\", is invalid." >&6;} 17750 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17751 fi 17752 17753 # Use eval to expand a potential ~ 17754 eval path="$path" 17755 if test ! -f "$path" && test ! -d "$path"; then 17756 as_fn_error $? "The path of OUTPUTDIR, which resolves as \"$path\", is not found." "$LINENO" 5 17757 fi 17758 17759 if test -d "$path"; then 17760 OUTPUTDIR="`cd "$path"; $THEPWDCMD -L`" 17761 else 17762 dir="`$DIRNAME "$path"`" 17763 base="`$BASENAME "$path"`" 17764 OUTPUTDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 17765 fi 17766 fi 17767 fi 17768 17769 17770 CONFIGURESUPPORT_OUTPUTDIR="$OUTPUTDIR/configure-support" 17771 $MKDIR -p "$CONFIGURESUPPORT_OUTPUTDIR" 17772 17773 SPEC="$OUTPUTDIR/spec.gmk" 17774 17775 17776 17777 17778 17779 # The spec.gmk file contains all variables for the make system. 17780 ac_config_files="$ac_config_files $OUTPUTDIR/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" 17781 17782 # The bootcycle-spec.gmk file contains support for boot cycle builds. 17783 ac_config_files="$ac_config_files $OUTPUTDIR/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" 17784 17785 # The buildjdk-spec.gmk file contains support for building a buildjdk when cross compiling. 17786 ac_config_files="$ac_config_files $OUTPUTDIR/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" 17787 17788 # The compare.sh is used to compare the build output to other builds. 17789 ac_config_files="$ac_config_files $OUTPUTDIR/compare.sh:$AUTOCONF_DIR/compare.sh.in" 17790 17791 # The generated Makefile knows where the spec.gmk is and where the source is. 17792 # You can run make from the OUTPUTDIR, or from the top-level Makefile 17793 # which will look for generated configurations 17794 ac_config_files="$ac_config_files $OUTPUTDIR/Makefile:$AUTOCONF_DIR/Makefile.in" 17795 17796 17797 17798 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY. 17799 17800 for ac_prog in apt-get yum brew port pkgutil pkgadd 17801 do 17802 # Extract the first word of "$ac_prog", so it can be a program name with args. 17803 set dummy $ac_prog; ac_word=$2 17804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17805 $as_echo_n "checking for $ac_word... " >&6; } 17806 if ${ac_cv_prog_PKGHANDLER+:} false; then : 17807 $as_echo_n "(cached) " >&6 17808 else 17809 if test -n "$PKGHANDLER"; then 17810 ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test. 17811 else 17812 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17813 for as_dir in $PATH 17814 do 17815 IFS=$as_save_IFS 17816 test -z "$as_dir" && as_dir=. 17817 for ac_exec_ext in '' $ac_executable_extensions; do 17818 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17819 ac_cv_prog_PKGHANDLER="$ac_prog" 17820 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17821 break 2 17822 fi 17823 done 17824 done 17825 IFS=$as_save_IFS 17826 17827 fi 17828 fi 17829 PKGHANDLER=$ac_cv_prog_PKGHANDLER 17830 if test -n "$PKGHANDLER"; then 17831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5 17832 $as_echo "$PKGHANDLER" >&6; } 17833 else 17834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17835 $as_echo "no" >&6; } 17836 fi 17837 17838 17839 test -n "$PKGHANDLER" && break 17840 done 17841 17842 17843 17844 # Setup tools that requires more complex handling, or that is not needed by the configure script. 17845 17846 17847 17848 # Publish this variable in the help. 17849 17850 17851 if [ -z "${MAKE+x}" ]; then 17852 # The variable is not set by user, try to locate tool using the code snippet 17853 17854 # Try our hardest to locate a correct version of GNU make 17855 for ac_prog in gmake 17856 do 17857 # Extract the first word of "$ac_prog", so it can be a program name with args. 17858 set dummy $ac_prog; ac_word=$2 17859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17860 $as_echo_n "checking for $ac_word... " >&6; } 17861 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 17862 $as_echo_n "(cached) " >&6 17863 else 17864 case $CHECK_GMAKE in 17865 [\\/]* | ?:[\\/]*) 17866 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 17867 ;; 17868 *) 17869 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17870 for as_dir in $PATH 17871 do 17872 IFS=$as_save_IFS 17873 test -z "$as_dir" && as_dir=. 17874 for ac_exec_ext in '' $ac_executable_extensions; do 17875 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17876 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 17877 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17878 break 2 17879 fi 17880 done 17881 done 17882 IFS=$as_save_IFS 17883 17884 ;; 17885 esac 17886 fi 17887 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 17888 if test -n "$CHECK_GMAKE"; then 17889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 17890 $as_echo "$CHECK_GMAKE" >&6; } 17891 else 17892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17893 $as_echo "no" >&6; } 17894 fi 17895 17896 17897 test -n "$CHECK_GMAKE" && break 17898 done 17899 17900 17901 MAKE_CANDIDATE=""$CHECK_GMAKE"" 17902 DESCRIPTION="gmake in PATH" 17903 17904 # On Cygwin, we require a newer version of make than on other platforms 17905 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17906 MAKE_VERSION_EXPR="-e 4\." 17907 MAKE_REQUIRED_VERSION="4.0" 17908 else 17909 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17910 MAKE_REQUIRED_VERSION="3.81" 17911 fi 17912 17913 if test "x$MAKE_CANDIDATE" != x; then 17914 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17915 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17916 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17917 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17918 if test "x$IS_GNU_MAKE" = x; then 17919 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17920 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17921 else 17922 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17923 if test "x$IS_MODERN_MAKE" = x; then 17924 { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5 17925 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;} 17926 else 17927 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17928 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17929 MAKE_EXPECTED_ENV='cygwin' 17930 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17931 MAKE_EXPECTED_ENV='msys' 17932 else 17933 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17934 fi 17935 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17936 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17937 else 17938 # Not relevant for non-Windows 17939 IS_MAKE_CORRECT_ENV=true 17940 fi 17941 if test "x$IS_MAKE_CORRECT_ENV" = x; then 17942 { $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 17943 $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;} 17944 else 17945 FOUND_MAKE=$MAKE_CANDIDATE 17946 17947 # Only process if variable expands to non-empty 17948 17949 if test "x$FOUND_MAKE" != x; then 17950 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17951 17952 # First separate the path from the arguments. This will split at the first 17953 # space. 17954 complete="$FOUND_MAKE" 17955 path="${complete%% *}" 17956 tmp="$complete EOL" 17957 arguments="${tmp#* }" 17958 17959 # Input might be given as Windows format, start by converting to 17960 # unix format. 17961 new_path=`$CYGPATH -u "$path"` 17962 17963 # Now try to locate executable using which 17964 new_path=`$WHICH "$new_path" 2> /dev/null` 17965 # bat and cmd files are not always considered executable in cygwin causing which 17966 # to not find them 17967 if test "x$new_path" = x \ 17968 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17969 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17970 new_path=`$CYGPATH -u "$path"` 17971 fi 17972 if test "x$new_path" = x; then 17973 # Oops. Which didn't find the executable. 17974 # The splitting of arguments from the executable at a space might have been incorrect, 17975 # since paths with space are more likely in Windows. Give it another try with the whole 17976 # argument. 17977 path="$complete" 17978 arguments="EOL" 17979 new_path=`$CYGPATH -u "$path"` 17980 new_path=`$WHICH "$new_path" 2> /dev/null` 17981 # bat and cmd files are not always considered executable in cygwin causing which 17982 # to not find them 17983 if test "x$new_path" = x \ 17984 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17985 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17986 new_path=`$CYGPATH -u "$path"` 17987 fi 17988 if test "x$new_path" = x; then 17989 # It's still not found. Now this is an unrecoverable error. 17990 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17991 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17992 has_space=`$ECHO "$complete" | $GREP " "` 17993 if test "x$has_space" != x; then 17994 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17995 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17996 fi 17997 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17998 fi 17999 fi 18000 18001 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18002 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18003 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18004 # "foo.exe" is OK but "foo" is an error. 18005 # 18006 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18007 # It is also a way to make sure we got the proper file name for the real test later on. 18008 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18009 if test "x$test_shortpath" = x; then 18010 # Short path failed, file does not exist as specified. 18011 # Try adding .exe or .cmd 18012 if test -f "${new_path}.exe"; then 18013 input_to_shortpath="${new_path}.exe" 18014 elif test -f "${new_path}.cmd"; then 18015 input_to_shortpath="${new_path}.cmd" 18016 else 18017 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18018 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18019 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18020 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18021 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18022 fi 18023 else 18024 input_to_shortpath="$new_path" 18025 fi 18026 18027 # Call helper function which possibly converts this using DOS-style short mode. 18028 # If so, the updated path is stored in $new_path. 18029 new_path="$input_to_shortpath" 18030 18031 input_path="$input_to_shortpath" 18032 # Check if we need to convert this using DOS-style short mode. If the path 18033 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18034 # take no chances and rewrite it. 18035 # Note: m4 eats our [], so we need to use [ and ] instead. 18036 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18037 if test "x$has_forbidden_chars" != x; then 18038 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18039 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18040 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18041 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18042 # Going to short mode and back again did indeed matter. Since short mode is 18043 # case insensitive, let's make it lowercase to improve readability. 18044 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18045 # Now convert it back to Unix-style (cygpath) 18046 input_path=`$CYGPATH -u "$shortmode_path"` 18047 new_path="$input_path" 18048 fi 18049 fi 18050 18051 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18052 if test "x$test_cygdrive_prefix" = x; then 18053 # As a simple fix, exclude /usr/bin since it's not a real path. 18054 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18055 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18056 # a path prefixed by /cygdrive for fixpath to work. 18057 new_path="$CYGWIN_ROOT_PATH$input_path" 18058 fi 18059 fi 18060 18061 # remove trailing .exe if any 18062 new_path="${new_path/%.exe/}" 18063 18064 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18065 18066 # First separate the path from the arguments. This will split at the first 18067 # space. 18068 complete="$FOUND_MAKE" 18069 path="${complete%% *}" 18070 tmp="$complete EOL" 18071 arguments="${tmp#* }" 18072 18073 # Input might be given as Windows format, start by converting to 18074 # unix format. 18075 new_path="$path" 18076 18077 windows_path="$new_path" 18078 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18079 unix_path=`$CYGPATH -u "$windows_path"` 18080 new_path="$unix_path" 18081 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18082 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18083 new_path="$unix_path" 18084 fi 18085 18086 18087 # Now try to locate executable using which 18088 new_path=`$WHICH "$new_path" 2> /dev/null` 18089 18090 if test "x$new_path" = x; then 18091 # Oops. Which didn't find the executable. 18092 # The splitting of arguments from the executable at a space might have been incorrect, 18093 # since paths with space are more likely in Windows. Give it another try with the whole 18094 # argument. 18095 path="$complete" 18096 arguments="EOL" 18097 new_path="$path" 18098 18099 windows_path="$new_path" 18100 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18101 unix_path=`$CYGPATH -u "$windows_path"` 18102 new_path="$unix_path" 18103 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18104 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18105 new_path="$unix_path" 18106 fi 18107 18108 18109 new_path=`$WHICH "$new_path" 2> /dev/null` 18110 # bat and cmd files are not always considered executable in MSYS causing which 18111 # to not find them 18112 if test "x$new_path" = x \ 18113 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18114 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18115 new_path="$path" 18116 18117 windows_path="$new_path" 18118 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18119 unix_path=`$CYGPATH -u "$windows_path"` 18120 new_path="$unix_path" 18121 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18122 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18123 new_path="$unix_path" 18124 fi 18125 18126 fi 18127 18128 if test "x$new_path" = x; then 18129 # It's still not found. Now this is an unrecoverable error. 18130 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18131 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18132 has_space=`$ECHO "$complete" | $GREP " "` 18133 if test "x$has_space" != x; then 18134 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18135 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18136 fi 18137 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18138 fi 18139 fi 18140 18141 # Now new_path has a complete unix path to the binary 18142 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18143 # Keep paths in /bin as-is, but remove trailing .exe if any 18144 new_path="${new_path/%.exe/}" 18145 # Do not save /bin paths to all_fixpath_prefixes! 18146 else 18147 # Not in mixed or Windows style, start by that. 18148 new_path=`cmd //c echo $new_path` 18149 18150 input_path="$new_path" 18151 # Check if we need to convert this using DOS-style short mode. If the path 18152 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18153 # take no chances and rewrite it. 18154 # Note: m4 eats our [], so we need to use [ and ] instead. 18155 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18156 if test "x$has_forbidden_chars" != x; then 18157 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18158 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18159 fi 18160 18161 # Output is in $new_path 18162 18163 windows_path="$new_path" 18164 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18165 unix_path=`$CYGPATH -u "$windows_path"` 18166 new_path="$unix_path" 18167 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18168 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18169 new_path="$unix_path" 18170 fi 18171 18172 # remove trailing .exe if any 18173 new_path="${new_path/%.exe/}" 18174 18175 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18176 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18177 fi 18178 18179 else 18180 # We're on a unix platform. Hooray! :) 18181 # First separate the path from the arguments. This will split at the first 18182 # space. 18183 complete="$FOUND_MAKE" 18184 path="${complete%% *}" 18185 tmp="$complete EOL" 18186 arguments="${tmp#* }" 18187 18188 # Cannot rely on the command "which" here since it doesn't always work. 18189 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18190 if test -z "$is_absolute_path"; then 18191 # Path to executable is not absolute. Find it. 18192 IFS_save="$IFS" 18193 IFS=: 18194 for p in $PATH; do 18195 if test -f "$p/$path" && test -x "$p/$path"; then 18196 new_path="$p/$path" 18197 break 18198 fi 18199 done 18200 IFS="$IFS_save" 18201 else 18202 # This is an absolute path, we can use it without further modifications. 18203 new_path="$path" 18204 fi 18205 18206 if test "x$new_path" = x; then 18207 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18208 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18209 has_space=`$ECHO "$complete" | $GREP " "` 18210 if test "x$has_space" != x; then 18211 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18212 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18213 fi 18214 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18215 fi 18216 fi 18217 18218 # Now join together the path and the arguments once again 18219 if test "x$arguments" != xEOL; then 18220 new_complete="$new_path ${arguments% *}" 18221 else 18222 new_complete="$new_path" 18223 fi 18224 18225 if test "x$complete" != "x$new_complete"; then 18226 FOUND_MAKE="$new_complete" 18227 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18228 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18229 fi 18230 fi 18231 18232 fi 18233 fi 18234 fi 18235 fi 18236 18237 18238 if test "x$FOUND_MAKE" = x; then 18239 for ac_prog in make 18240 do 18241 # Extract the first word of "$ac_prog", so it can be a program name with args. 18242 set dummy $ac_prog; ac_word=$2 18243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18244 $as_echo_n "checking for $ac_word... " >&6; } 18245 if ${ac_cv_path_CHECK_MAKE+:} false; then : 18246 $as_echo_n "(cached) " >&6 18247 else 18248 case $CHECK_MAKE in 18249 [\\/]* | ?:[\\/]*) 18250 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 18251 ;; 18252 *) 18253 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18254 for as_dir in $PATH 18255 do 18256 IFS=$as_save_IFS 18257 test -z "$as_dir" && as_dir=. 18258 for ac_exec_ext in '' $ac_executable_extensions; do 18259 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18260 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 18261 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18262 break 2 18263 fi 18264 done 18265 done 18266 IFS=$as_save_IFS 18267 18268 ;; 18269 esac 18270 fi 18271 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 18272 if test -n "$CHECK_MAKE"; then 18273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 18274 $as_echo "$CHECK_MAKE" >&6; } 18275 else 18276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18277 $as_echo "no" >&6; } 18278 fi 18279 18280 18281 test -n "$CHECK_MAKE" && break 18282 done 18283 18284 18285 MAKE_CANDIDATE=""$CHECK_MAKE"" 18286 DESCRIPTION="make in PATH" 18287 18288 # On Cygwin, we require a newer version of make than on other platforms 18289 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18290 MAKE_VERSION_EXPR="-e 4\." 18291 MAKE_REQUIRED_VERSION="4.0" 18292 else 18293 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18294 MAKE_REQUIRED_VERSION="3.81" 18295 fi 18296 18297 if test "x$MAKE_CANDIDATE" != x; then 18298 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18299 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18300 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18301 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18302 if test "x$IS_GNU_MAKE" = x; then 18303 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18304 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18305 else 18306 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18307 if test "x$IS_MODERN_MAKE" = x; then 18308 { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5 18309 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;} 18310 else 18311 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18312 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18313 MAKE_EXPECTED_ENV='cygwin' 18314 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18315 MAKE_EXPECTED_ENV='msys' 18316 else 18317 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18318 fi 18319 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18320 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18321 else 18322 # Not relevant for non-Windows 18323 IS_MAKE_CORRECT_ENV=true 18324 fi 18325 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18326 { $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 18327 $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;} 18328 else 18329 FOUND_MAKE=$MAKE_CANDIDATE 18330 18331 # Only process if variable expands to non-empty 18332 18333 if test "x$FOUND_MAKE" != x; then 18334 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18335 18336 # First separate the path from the arguments. This will split at the first 18337 # space. 18338 complete="$FOUND_MAKE" 18339 path="${complete%% *}" 18340 tmp="$complete EOL" 18341 arguments="${tmp#* }" 18342 18343 # Input might be given as Windows format, start by converting to 18344 # unix format. 18345 new_path=`$CYGPATH -u "$path"` 18346 18347 # Now try to locate executable using which 18348 new_path=`$WHICH "$new_path" 2> /dev/null` 18349 # bat and cmd files are not always considered executable in cygwin causing which 18350 # to not find them 18351 if test "x$new_path" = x \ 18352 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18353 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18354 new_path=`$CYGPATH -u "$path"` 18355 fi 18356 if test "x$new_path" = x; then 18357 # Oops. Which didn't find the executable. 18358 # The splitting of arguments from the executable at a space might have been incorrect, 18359 # since paths with space are more likely in Windows. Give it another try with the whole 18360 # argument. 18361 path="$complete" 18362 arguments="EOL" 18363 new_path=`$CYGPATH -u "$path"` 18364 new_path=`$WHICH "$new_path" 2> /dev/null` 18365 # bat and cmd files are not always considered executable in cygwin causing which 18366 # to not find them 18367 if test "x$new_path" = x \ 18368 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18369 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18370 new_path=`$CYGPATH -u "$path"` 18371 fi 18372 if test "x$new_path" = x; then 18373 # It's still not found. Now this is an unrecoverable error. 18374 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18375 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18376 has_space=`$ECHO "$complete" | $GREP " "` 18377 if test "x$has_space" != x; then 18378 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18379 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18380 fi 18381 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18382 fi 18383 fi 18384 18385 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18386 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18387 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18388 # "foo.exe" is OK but "foo" is an error. 18389 # 18390 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18391 # It is also a way to make sure we got the proper file name for the real test later on. 18392 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18393 if test "x$test_shortpath" = x; then 18394 # Short path failed, file does not exist as specified. 18395 # Try adding .exe or .cmd 18396 if test -f "${new_path}.exe"; then 18397 input_to_shortpath="${new_path}.exe" 18398 elif test -f "${new_path}.cmd"; then 18399 input_to_shortpath="${new_path}.cmd" 18400 else 18401 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18402 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18403 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18404 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18405 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18406 fi 18407 else 18408 input_to_shortpath="$new_path" 18409 fi 18410 18411 # Call helper function which possibly converts this using DOS-style short mode. 18412 # If so, the updated path is stored in $new_path. 18413 new_path="$input_to_shortpath" 18414 18415 input_path="$input_to_shortpath" 18416 # Check if we need to convert this using DOS-style short mode. If the path 18417 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18418 # take no chances and rewrite it. 18419 # Note: m4 eats our [], so we need to use [ and ] instead. 18420 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18421 if test "x$has_forbidden_chars" != x; then 18422 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18423 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18424 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18425 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18426 # Going to short mode and back again did indeed matter. Since short mode is 18427 # case insensitive, let's make it lowercase to improve readability. 18428 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18429 # Now convert it back to Unix-style (cygpath) 18430 input_path=`$CYGPATH -u "$shortmode_path"` 18431 new_path="$input_path" 18432 fi 18433 fi 18434 18435 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18436 if test "x$test_cygdrive_prefix" = x; then 18437 # As a simple fix, exclude /usr/bin since it's not a real path. 18438 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18439 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18440 # a path prefixed by /cygdrive for fixpath to work. 18441 new_path="$CYGWIN_ROOT_PATH$input_path" 18442 fi 18443 fi 18444 18445 # remove trailing .exe if any 18446 new_path="${new_path/%.exe/}" 18447 18448 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18449 18450 # First separate the path from the arguments. This will split at the first 18451 # space. 18452 complete="$FOUND_MAKE" 18453 path="${complete%% *}" 18454 tmp="$complete EOL" 18455 arguments="${tmp#* }" 18456 18457 # Input might be given as Windows format, start by converting to 18458 # unix format. 18459 new_path="$path" 18460 18461 windows_path="$new_path" 18462 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18463 unix_path=`$CYGPATH -u "$windows_path"` 18464 new_path="$unix_path" 18465 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18466 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18467 new_path="$unix_path" 18468 fi 18469 18470 18471 # Now try to locate executable using which 18472 new_path=`$WHICH "$new_path" 2> /dev/null` 18473 18474 if test "x$new_path" = x; then 18475 # Oops. Which didn't find the executable. 18476 # The splitting of arguments from the executable at a space might have been incorrect, 18477 # since paths with space are more likely in Windows. Give it another try with the whole 18478 # argument. 18479 path="$complete" 18480 arguments="EOL" 18481 new_path="$path" 18482 18483 windows_path="$new_path" 18484 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18485 unix_path=`$CYGPATH -u "$windows_path"` 18486 new_path="$unix_path" 18487 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18488 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18489 new_path="$unix_path" 18490 fi 18491 18492 18493 new_path=`$WHICH "$new_path" 2> /dev/null` 18494 # bat and cmd files are not always considered executable in MSYS causing which 18495 # to not find them 18496 if test "x$new_path" = x \ 18497 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18498 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18499 new_path="$path" 18500 18501 windows_path="$new_path" 18502 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18503 unix_path=`$CYGPATH -u "$windows_path"` 18504 new_path="$unix_path" 18505 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18506 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18507 new_path="$unix_path" 18508 fi 18509 18510 fi 18511 18512 if test "x$new_path" = x; then 18513 # It's still not found. Now this is an unrecoverable error. 18514 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18515 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18516 has_space=`$ECHO "$complete" | $GREP " "` 18517 if test "x$has_space" != x; then 18518 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18519 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18520 fi 18521 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18522 fi 18523 fi 18524 18525 # Now new_path has a complete unix path to the binary 18526 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18527 # Keep paths in /bin as-is, but remove trailing .exe if any 18528 new_path="${new_path/%.exe/}" 18529 # Do not save /bin paths to all_fixpath_prefixes! 18530 else 18531 # Not in mixed or Windows style, start by that. 18532 new_path=`cmd //c echo $new_path` 18533 18534 input_path="$new_path" 18535 # Check if we need to convert this using DOS-style short mode. If the path 18536 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18537 # take no chances and rewrite it. 18538 # Note: m4 eats our [], so we need to use [ and ] instead. 18539 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18540 if test "x$has_forbidden_chars" != x; then 18541 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18542 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18543 fi 18544 18545 # Output is in $new_path 18546 18547 windows_path="$new_path" 18548 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18549 unix_path=`$CYGPATH -u "$windows_path"` 18550 new_path="$unix_path" 18551 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18552 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18553 new_path="$unix_path" 18554 fi 18555 18556 # remove trailing .exe if any 18557 new_path="${new_path/%.exe/}" 18558 18559 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18560 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18561 fi 18562 18563 else 18564 # We're on a unix platform. Hooray! :) 18565 # First separate the path from the arguments. This will split at the first 18566 # space. 18567 complete="$FOUND_MAKE" 18568 path="${complete%% *}" 18569 tmp="$complete EOL" 18570 arguments="${tmp#* }" 18571 18572 # Cannot rely on the command "which" here since it doesn't always work. 18573 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18574 if test -z "$is_absolute_path"; then 18575 # Path to executable is not absolute. Find it. 18576 IFS_save="$IFS" 18577 IFS=: 18578 for p in $PATH; do 18579 if test -f "$p/$path" && test -x "$p/$path"; then 18580 new_path="$p/$path" 18581 break 18582 fi 18583 done 18584 IFS="$IFS_save" 18585 else 18586 # This is an absolute path, we can use it without further modifications. 18587 new_path="$path" 18588 fi 18589 18590 if test "x$new_path" = x; then 18591 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18592 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18593 has_space=`$ECHO "$complete" | $GREP " "` 18594 if test "x$has_space" != x; then 18595 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18596 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18597 fi 18598 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18599 fi 18600 fi 18601 18602 # Now join together the path and the arguments once again 18603 if test "x$arguments" != xEOL; then 18604 new_complete="$new_path ${arguments% *}" 18605 else 18606 new_complete="$new_path" 18607 fi 18608 18609 if test "x$complete" != "x$new_complete"; then 18610 FOUND_MAKE="$new_complete" 18611 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18612 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18613 fi 18614 fi 18615 18616 fi 18617 fi 18618 fi 18619 fi 18620 18621 fi 18622 18623 if test "x$FOUND_MAKE" = x; then 18624 if test "x$TOOLCHAIN_PATH" != x; then 18625 # We have a toolchain path, check that as well before giving up. 18626 OLD_PATH=$PATH 18627 PATH=$TOOLCHAIN_PATH:$PATH 18628 for ac_prog in gmake 18629 do 18630 # Extract the first word of "$ac_prog", so it can be a program name with args. 18631 set dummy $ac_prog; ac_word=$2 18632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18633 $as_echo_n "checking for $ac_word... " >&6; } 18634 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 18635 $as_echo_n "(cached) " >&6 18636 else 18637 case $CHECK_TOOLSDIR_GMAKE in 18638 [\\/]* | ?:[\\/]*) 18639 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 18640 ;; 18641 *) 18642 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18643 for as_dir in $PATH 18644 do 18645 IFS=$as_save_IFS 18646 test -z "$as_dir" && as_dir=. 18647 for ac_exec_ext in '' $ac_executable_extensions; do 18648 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18649 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 18650 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18651 break 2 18652 fi 18653 done 18654 done 18655 IFS=$as_save_IFS 18656 18657 ;; 18658 esac 18659 fi 18660 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 18661 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 18662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 18663 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 18664 else 18665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18666 $as_echo "no" >&6; } 18667 fi 18668 18669 18670 test -n "$CHECK_TOOLSDIR_GMAKE" && break 18671 done 18672 18673 18674 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 18675 DESCRIPTION="gmake in tools-dir" 18676 18677 # On Cygwin, we require a newer version of make than on other platforms 18678 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18679 MAKE_VERSION_EXPR="-e 4\." 18680 MAKE_REQUIRED_VERSION="4.0" 18681 else 18682 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18683 MAKE_REQUIRED_VERSION="3.81" 18684 fi 18685 18686 if test "x$MAKE_CANDIDATE" != x; then 18687 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18688 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18689 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18690 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18691 if test "x$IS_GNU_MAKE" = x; then 18692 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18693 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18694 else 18695 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18696 if test "x$IS_MODERN_MAKE" = x; then 18697 { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5 18698 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;} 18699 else 18700 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18701 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18702 MAKE_EXPECTED_ENV='cygwin' 18703 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18704 MAKE_EXPECTED_ENV='msys' 18705 else 18706 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18707 fi 18708 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18709 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18710 else 18711 # Not relevant for non-Windows 18712 IS_MAKE_CORRECT_ENV=true 18713 fi 18714 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18715 { $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 18716 $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;} 18717 else 18718 FOUND_MAKE=$MAKE_CANDIDATE 18719 18720 # Only process if variable expands to non-empty 18721 18722 if test "x$FOUND_MAKE" != x; then 18723 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18724 18725 # First separate the path from the arguments. This will split at the first 18726 # space. 18727 complete="$FOUND_MAKE" 18728 path="${complete%% *}" 18729 tmp="$complete EOL" 18730 arguments="${tmp#* }" 18731 18732 # Input might be given as Windows format, start by converting to 18733 # unix format. 18734 new_path=`$CYGPATH -u "$path"` 18735 18736 # Now try to locate executable using which 18737 new_path=`$WHICH "$new_path" 2> /dev/null` 18738 # bat and cmd files are not always considered executable in cygwin causing which 18739 # to not find them 18740 if test "x$new_path" = x \ 18741 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18742 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18743 new_path=`$CYGPATH -u "$path"` 18744 fi 18745 if test "x$new_path" = x; then 18746 # Oops. Which didn't find the executable. 18747 # The splitting of arguments from the executable at a space might have been incorrect, 18748 # since paths with space are more likely in Windows. Give it another try with the whole 18749 # argument. 18750 path="$complete" 18751 arguments="EOL" 18752 new_path=`$CYGPATH -u "$path"` 18753 new_path=`$WHICH "$new_path" 2> /dev/null` 18754 # bat and cmd files are not always considered executable in cygwin causing which 18755 # to not find them 18756 if test "x$new_path" = x \ 18757 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18758 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18759 new_path=`$CYGPATH -u "$path"` 18760 fi 18761 if test "x$new_path" = x; then 18762 # It's still not found. Now this is an unrecoverable error. 18763 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18764 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18765 has_space=`$ECHO "$complete" | $GREP " "` 18766 if test "x$has_space" != x; then 18767 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18768 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18769 fi 18770 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18771 fi 18772 fi 18773 18774 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18775 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18776 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18777 # "foo.exe" is OK but "foo" is an error. 18778 # 18779 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18780 # It is also a way to make sure we got the proper file name for the real test later on. 18781 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18782 if test "x$test_shortpath" = x; then 18783 # Short path failed, file does not exist as specified. 18784 # Try adding .exe or .cmd 18785 if test -f "${new_path}.exe"; then 18786 input_to_shortpath="${new_path}.exe" 18787 elif test -f "${new_path}.cmd"; then 18788 input_to_shortpath="${new_path}.cmd" 18789 else 18790 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18791 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18792 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18793 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18794 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18795 fi 18796 else 18797 input_to_shortpath="$new_path" 18798 fi 18799 18800 # Call helper function which possibly converts this using DOS-style short mode. 18801 # If so, the updated path is stored in $new_path. 18802 new_path="$input_to_shortpath" 18803 18804 input_path="$input_to_shortpath" 18805 # Check if we need to convert this using DOS-style short mode. If the path 18806 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18807 # take no chances and rewrite it. 18808 # Note: m4 eats our [], so we need to use [ and ] instead. 18809 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18810 if test "x$has_forbidden_chars" != x; then 18811 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18812 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18813 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18814 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18815 # Going to short mode and back again did indeed matter. Since short mode is 18816 # case insensitive, let's make it lowercase to improve readability. 18817 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18818 # Now convert it back to Unix-style (cygpath) 18819 input_path=`$CYGPATH -u "$shortmode_path"` 18820 new_path="$input_path" 18821 fi 18822 fi 18823 18824 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18825 if test "x$test_cygdrive_prefix" = x; then 18826 # As a simple fix, exclude /usr/bin since it's not a real path. 18827 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18828 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18829 # a path prefixed by /cygdrive for fixpath to work. 18830 new_path="$CYGWIN_ROOT_PATH$input_path" 18831 fi 18832 fi 18833 18834 # remove trailing .exe if any 18835 new_path="${new_path/%.exe/}" 18836 18837 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18838 18839 # First separate the path from the arguments. This will split at the first 18840 # space. 18841 complete="$FOUND_MAKE" 18842 path="${complete%% *}" 18843 tmp="$complete EOL" 18844 arguments="${tmp#* }" 18845 18846 # Input might be given as Windows format, start by converting to 18847 # unix format. 18848 new_path="$path" 18849 18850 windows_path="$new_path" 18851 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18852 unix_path=`$CYGPATH -u "$windows_path"` 18853 new_path="$unix_path" 18854 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18855 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18856 new_path="$unix_path" 18857 fi 18858 18859 18860 # Now try to locate executable using which 18861 new_path=`$WHICH "$new_path" 2> /dev/null` 18862 18863 if test "x$new_path" = x; then 18864 # Oops. Which didn't find the executable. 18865 # The splitting of arguments from the executable at a space might have been incorrect, 18866 # since paths with space are more likely in Windows. Give it another try with the whole 18867 # argument. 18868 path="$complete" 18869 arguments="EOL" 18870 new_path="$path" 18871 18872 windows_path="$new_path" 18873 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18874 unix_path=`$CYGPATH -u "$windows_path"` 18875 new_path="$unix_path" 18876 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18877 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18878 new_path="$unix_path" 18879 fi 18880 18881 18882 new_path=`$WHICH "$new_path" 2> /dev/null` 18883 # bat and cmd files are not always considered executable in MSYS causing which 18884 # to not find them 18885 if test "x$new_path" = x \ 18886 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18887 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18888 new_path="$path" 18889 18890 windows_path="$new_path" 18891 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18892 unix_path=`$CYGPATH -u "$windows_path"` 18893 new_path="$unix_path" 18894 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18895 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18896 new_path="$unix_path" 18897 fi 18898 18899 fi 18900 18901 if test "x$new_path" = x; then 18902 # It's still not found. Now this is an unrecoverable error. 18903 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18904 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18905 has_space=`$ECHO "$complete" | $GREP " "` 18906 if test "x$has_space" != x; then 18907 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18908 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18909 fi 18910 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18911 fi 18912 fi 18913 18914 # Now new_path has a complete unix path to the binary 18915 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18916 # Keep paths in /bin as-is, but remove trailing .exe if any 18917 new_path="${new_path/%.exe/}" 18918 # Do not save /bin paths to all_fixpath_prefixes! 18919 else 18920 # Not in mixed or Windows style, start by that. 18921 new_path=`cmd //c echo $new_path` 18922 18923 input_path="$new_path" 18924 # Check if we need to convert this using DOS-style short mode. If the path 18925 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18926 # take no chances and rewrite it. 18927 # Note: m4 eats our [], so we need to use [ and ] instead. 18928 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18929 if test "x$has_forbidden_chars" != x; then 18930 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18931 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18932 fi 18933 18934 # Output is in $new_path 18935 18936 windows_path="$new_path" 18937 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18938 unix_path=`$CYGPATH -u "$windows_path"` 18939 new_path="$unix_path" 18940 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18941 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18942 new_path="$unix_path" 18943 fi 18944 18945 # remove trailing .exe if any 18946 new_path="${new_path/%.exe/}" 18947 18948 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18949 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18950 fi 18951 18952 else 18953 # We're on a unix platform. Hooray! :) 18954 # First separate the path from the arguments. This will split at the first 18955 # space. 18956 complete="$FOUND_MAKE" 18957 path="${complete%% *}" 18958 tmp="$complete EOL" 18959 arguments="${tmp#* }" 18960 18961 # Cannot rely on the command "which" here since it doesn't always work. 18962 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18963 if test -z "$is_absolute_path"; then 18964 # Path to executable is not absolute. Find it. 18965 IFS_save="$IFS" 18966 IFS=: 18967 for p in $PATH; do 18968 if test -f "$p/$path" && test -x "$p/$path"; then 18969 new_path="$p/$path" 18970 break 18971 fi 18972 done 18973 IFS="$IFS_save" 18974 else 18975 # This is an absolute path, we can use it without further modifications. 18976 new_path="$path" 18977 fi 18978 18979 if test "x$new_path" = x; then 18980 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18981 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18982 has_space=`$ECHO "$complete" | $GREP " "` 18983 if test "x$has_space" != x; then 18984 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18985 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18986 fi 18987 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18988 fi 18989 fi 18990 18991 # Now join together the path and the arguments once again 18992 if test "x$arguments" != xEOL; then 18993 new_complete="$new_path ${arguments% *}" 18994 else 18995 new_complete="$new_path" 18996 fi 18997 18998 if test "x$complete" != "x$new_complete"; then 18999 FOUND_MAKE="$new_complete" 19000 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19001 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19002 fi 19003 fi 19004 19005 fi 19006 fi 19007 fi 19008 fi 19009 19010 if test "x$FOUND_MAKE" = x; then 19011 for ac_prog in make 19012 do 19013 # Extract the first word of "$ac_prog", so it can be a program name with args. 19014 set dummy $ac_prog; ac_word=$2 19015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19016 $as_echo_n "checking for $ac_word... " >&6; } 19017 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 19018 $as_echo_n "(cached) " >&6 19019 else 19020 case $CHECK_TOOLSDIR_MAKE in 19021 [\\/]* | ?:[\\/]*) 19022 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 19023 ;; 19024 *) 19025 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19026 for as_dir in $PATH 19027 do 19028 IFS=$as_save_IFS 19029 test -z "$as_dir" && as_dir=. 19030 for ac_exec_ext in '' $ac_executable_extensions; do 19031 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19032 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 19033 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19034 break 2 19035 fi 19036 done 19037 done 19038 IFS=$as_save_IFS 19039 19040 ;; 19041 esac 19042 fi 19043 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 19044 if test -n "$CHECK_TOOLSDIR_MAKE"; then 19045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 19046 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 19047 else 19048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19049 $as_echo "no" >&6; } 19050 fi 19051 19052 19053 test -n "$CHECK_TOOLSDIR_MAKE" && break 19054 done 19055 19056 19057 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 19058 DESCRIPTION="make in tools-dir" 19059 19060 # On Cygwin, we require a newer version of make than on other platforms 19061 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19062 MAKE_VERSION_EXPR="-e 4\." 19063 MAKE_REQUIRED_VERSION="4.0" 19064 else 19065 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19066 MAKE_REQUIRED_VERSION="3.81" 19067 fi 19068 19069 if test "x$MAKE_CANDIDATE" != x; then 19070 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19071 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19072 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19073 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19074 if test "x$IS_GNU_MAKE" = x; then 19075 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19076 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19077 else 19078 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19079 if test "x$IS_MODERN_MAKE" = x; then 19080 { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5 19081 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;} 19082 else 19083 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19084 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19085 MAKE_EXPECTED_ENV='cygwin' 19086 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19087 MAKE_EXPECTED_ENV='msys' 19088 else 19089 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19090 fi 19091 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19092 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19093 else 19094 # Not relevant for non-Windows 19095 IS_MAKE_CORRECT_ENV=true 19096 fi 19097 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19098 { $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 19099 $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;} 19100 else 19101 FOUND_MAKE=$MAKE_CANDIDATE 19102 19103 # Only process if variable expands to non-empty 19104 19105 if test "x$FOUND_MAKE" != x; then 19106 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19107 19108 # First separate the path from the arguments. This will split at the first 19109 # space. 19110 complete="$FOUND_MAKE" 19111 path="${complete%% *}" 19112 tmp="$complete EOL" 19113 arguments="${tmp#* }" 19114 19115 # Input might be given as Windows format, start by converting to 19116 # unix format. 19117 new_path=`$CYGPATH -u "$path"` 19118 19119 # Now try to locate executable using which 19120 new_path=`$WHICH "$new_path" 2> /dev/null` 19121 # bat and cmd files are not always considered executable in cygwin causing which 19122 # to not find them 19123 if test "x$new_path" = x \ 19124 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19125 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19126 new_path=`$CYGPATH -u "$path"` 19127 fi 19128 if test "x$new_path" = x; then 19129 # Oops. Which didn't find the executable. 19130 # The splitting of arguments from the executable at a space might have been incorrect, 19131 # since paths with space are more likely in Windows. Give it another try with the whole 19132 # argument. 19133 path="$complete" 19134 arguments="EOL" 19135 new_path=`$CYGPATH -u "$path"` 19136 new_path=`$WHICH "$new_path" 2> /dev/null` 19137 # bat and cmd files are not always considered executable in cygwin causing which 19138 # to not find them 19139 if test "x$new_path" = x \ 19140 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19141 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19142 new_path=`$CYGPATH -u "$path"` 19143 fi 19144 if test "x$new_path" = x; then 19145 # It's still not found. Now this is an unrecoverable error. 19146 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19147 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19148 has_space=`$ECHO "$complete" | $GREP " "` 19149 if test "x$has_space" != x; then 19150 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19151 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19152 fi 19153 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19154 fi 19155 fi 19156 19157 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19158 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19159 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19160 # "foo.exe" is OK but "foo" is an error. 19161 # 19162 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19163 # It is also a way to make sure we got the proper file name for the real test later on. 19164 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19165 if test "x$test_shortpath" = x; then 19166 # Short path failed, file does not exist as specified. 19167 # Try adding .exe or .cmd 19168 if test -f "${new_path}.exe"; then 19169 input_to_shortpath="${new_path}.exe" 19170 elif test -f "${new_path}.cmd"; then 19171 input_to_shortpath="${new_path}.cmd" 19172 else 19173 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19174 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19175 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19176 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19177 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19178 fi 19179 else 19180 input_to_shortpath="$new_path" 19181 fi 19182 19183 # Call helper function which possibly converts this using DOS-style short mode. 19184 # If so, the updated path is stored in $new_path. 19185 new_path="$input_to_shortpath" 19186 19187 input_path="$input_to_shortpath" 19188 # Check if we need to convert this using DOS-style short mode. If the path 19189 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19190 # take no chances and rewrite it. 19191 # Note: m4 eats our [], so we need to use [ and ] instead. 19192 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19193 if test "x$has_forbidden_chars" != x; then 19194 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19195 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19196 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19197 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19198 # Going to short mode and back again did indeed matter. Since short mode is 19199 # case insensitive, let's make it lowercase to improve readability. 19200 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19201 # Now convert it back to Unix-style (cygpath) 19202 input_path=`$CYGPATH -u "$shortmode_path"` 19203 new_path="$input_path" 19204 fi 19205 fi 19206 19207 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19208 if test "x$test_cygdrive_prefix" = x; then 19209 # As a simple fix, exclude /usr/bin since it's not a real path. 19210 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19211 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19212 # a path prefixed by /cygdrive for fixpath to work. 19213 new_path="$CYGWIN_ROOT_PATH$input_path" 19214 fi 19215 fi 19216 19217 # remove trailing .exe if any 19218 new_path="${new_path/%.exe/}" 19219 19220 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19221 19222 # First separate the path from the arguments. This will split at the first 19223 # space. 19224 complete="$FOUND_MAKE" 19225 path="${complete%% *}" 19226 tmp="$complete EOL" 19227 arguments="${tmp#* }" 19228 19229 # Input might be given as Windows format, start by converting to 19230 # unix format. 19231 new_path="$path" 19232 19233 windows_path="$new_path" 19234 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19235 unix_path=`$CYGPATH -u "$windows_path"` 19236 new_path="$unix_path" 19237 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19238 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19239 new_path="$unix_path" 19240 fi 19241 19242 19243 # Now try to locate executable using which 19244 new_path=`$WHICH "$new_path" 2> /dev/null` 19245 19246 if test "x$new_path" = x; then 19247 # Oops. Which didn't find the executable. 19248 # The splitting of arguments from the executable at a space might have been incorrect, 19249 # since paths with space are more likely in Windows. Give it another try with the whole 19250 # argument. 19251 path="$complete" 19252 arguments="EOL" 19253 new_path="$path" 19254 19255 windows_path="$new_path" 19256 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19257 unix_path=`$CYGPATH -u "$windows_path"` 19258 new_path="$unix_path" 19259 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19260 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19261 new_path="$unix_path" 19262 fi 19263 19264 19265 new_path=`$WHICH "$new_path" 2> /dev/null` 19266 # bat and cmd files are not always considered executable in MSYS causing which 19267 # to not find them 19268 if test "x$new_path" = x \ 19269 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19270 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19271 new_path="$path" 19272 19273 windows_path="$new_path" 19274 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19275 unix_path=`$CYGPATH -u "$windows_path"` 19276 new_path="$unix_path" 19277 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19278 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19279 new_path="$unix_path" 19280 fi 19281 19282 fi 19283 19284 if test "x$new_path" = x; then 19285 # It's still not found. Now this is an unrecoverable error. 19286 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19287 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19288 has_space=`$ECHO "$complete" | $GREP " "` 19289 if test "x$has_space" != x; then 19290 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19291 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19292 fi 19293 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19294 fi 19295 fi 19296 19297 # Now new_path has a complete unix path to the binary 19298 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19299 # Keep paths in /bin as-is, but remove trailing .exe if any 19300 new_path="${new_path/%.exe/}" 19301 # Do not save /bin paths to all_fixpath_prefixes! 19302 else 19303 # Not in mixed or Windows style, start by that. 19304 new_path=`cmd //c echo $new_path` 19305 19306 input_path="$new_path" 19307 # Check if we need to convert this using DOS-style short mode. If the path 19308 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19309 # take no chances and rewrite it. 19310 # Note: m4 eats our [], so we need to use [ and ] instead. 19311 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19312 if test "x$has_forbidden_chars" != x; then 19313 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19314 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19315 fi 19316 19317 # Output is in $new_path 19318 19319 windows_path="$new_path" 19320 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19321 unix_path=`$CYGPATH -u "$windows_path"` 19322 new_path="$unix_path" 19323 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19324 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19325 new_path="$unix_path" 19326 fi 19327 19328 # remove trailing .exe if any 19329 new_path="${new_path/%.exe/}" 19330 19331 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19332 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19333 fi 19334 19335 else 19336 # We're on a unix platform. Hooray! :) 19337 # First separate the path from the arguments. This will split at the first 19338 # space. 19339 complete="$FOUND_MAKE" 19340 path="${complete%% *}" 19341 tmp="$complete EOL" 19342 arguments="${tmp#* }" 19343 19344 # Cannot rely on the command "which" here since it doesn't always work. 19345 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19346 if test -z "$is_absolute_path"; then 19347 # Path to executable is not absolute. Find it. 19348 IFS_save="$IFS" 19349 IFS=: 19350 for p in $PATH; do 19351 if test -f "$p/$path" && test -x "$p/$path"; then 19352 new_path="$p/$path" 19353 break 19354 fi 19355 done 19356 IFS="$IFS_save" 19357 else 19358 # This is an absolute path, we can use it without further modifications. 19359 new_path="$path" 19360 fi 19361 19362 if test "x$new_path" = x; then 19363 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19364 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19365 has_space=`$ECHO "$complete" | $GREP " "` 19366 if test "x$has_space" != x; then 19367 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19368 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19369 fi 19370 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19371 fi 19372 fi 19373 19374 # Now join together the path and the arguments once again 19375 if test "x$arguments" != xEOL; then 19376 new_complete="$new_path ${arguments% *}" 19377 else 19378 new_complete="$new_path" 19379 fi 19380 19381 if test "x$complete" != "x$new_complete"; then 19382 FOUND_MAKE="$new_complete" 19383 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19384 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19385 fi 19386 fi 19387 19388 fi 19389 fi 19390 fi 19391 fi 19392 19393 fi 19394 PATH=$OLD_PATH 19395 fi 19396 fi 19397 19398 if test "x$FOUND_MAKE" = x; then 19399 as_fn_error $? "Cannot find GNU make $MAKE_REQUIRED_VERSION or newer! Please put it in the path, or add e.g. MAKE=/opt/gmake3.81/make as argument to configure." "$LINENO" 5 19400 fi 19401 19402 else 19403 # The variable is set, but is it from the command line or the environment? 19404 19405 # Try to remove the string !MAKE! from our list. 19406 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MAKE!/} 19407 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 19408 # If it failed, the variable was not from the command line. Ignore it, 19409 # but warn the user (except for BASH, which is always set by the calling BASH). 19410 if test "xMAKE" != xBASH; then 19411 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&5 19412 $as_echo "$as_me: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&2;} 19413 fi 19414 # Try to locate tool using the code snippet 19415 19416 # Try our hardest to locate a correct version of GNU make 19417 for ac_prog in gmake 19418 do 19419 # Extract the first word of "$ac_prog", so it can be a program name with args. 19420 set dummy $ac_prog; ac_word=$2 19421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19422 $as_echo_n "checking for $ac_word... " >&6; } 19423 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 19424 $as_echo_n "(cached) " >&6 19425 else 19426 case $CHECK_GMAKE in 19427 [\\/]* | ?:[\\/]*) 19428 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 19429 ;; 19430 *) 19431 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19432 for as_dir in $PATH 19433 do 19434 IFS=$as_save_IFS 19435 test -z "$as_dir" && as_dir=. 19436 for ac_exec_ext in '' $ac_executable_extensions; do 19437 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19438 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19439 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19440 break 2 19441 fi 19442 done 19443 done 19444 IFS=$as_save_IFS 19445 19446 ;; 19447 esac 19448 fi 19449 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 19450 if test -n "$CHECK_GMAKE"; then 19451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 19452 $as_echo "$CHECK_GMAKE" >&6; } 19453 else 19454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19455 $as_echo "no" >&6; } 19456 fi 19457 19458 19459 test -n "$CHECK_GMAKE" && break 19460 done 19461 19462 19463 MAKE_CANDIDATE=""$CHECK_GMAKE"" 19464 DESCRIPTION="gmake in PATH" 19465 19466 # On Cygwin, we require a newer version of make than on other platforms 19467 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19468 MAKE_VERSION_EXPR="-e 4\." 19469 MAKE_REQUIRED_VERSION="4.0" 19470 else 19471 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19472 MAKE_REQUIRED_VERSION="3.81" 19473 fi 19474 19475 if test "x$MAKE_CANDIDATE" != x; then 19476 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19477 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19478 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19479 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19480 if test "x$IS_GNU_MAKE" = x; then 19481 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19482 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19483 else 19484 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19485 if test "x$IS_MODERN_MAKE" = x; then 19486 { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5 19487 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;} 19488 else 19489 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19490 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19491 MAKE_EXPECTED_ENV='cygwin' 19492 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19493 MAKE_EXPECTED_ENV='msys' 19494 else 19495 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19496 fi 19497 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19498 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19499 else 19500 # Not relevant for non-Windows 19501 IS_MAKE_CORRECT_ENV=true 19502 fi 19503 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19504 { $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 19505 $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;} 19506 else 19507 FOUND_MAKE=$MAKE_CANDIDATE 19508 19509 # Only process if variable expands to non-empty 19510 19511 if test "x$FOUND_MAKE" != x; then 19512 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19513 19514 # First separate the path from the arguments. This will split at the first 19515 # space. 19516 complete="$FOUND_MAKE" 19517 path="${complete%% *}" 19518 tmp="$complete EOL" 19519 arguments="${tmp#* }" 19520 19521 # Input might be given as Windows format, start by converting to 19522 # unix format. 19523 new_path=`$CYGPATH -u "$path"` 19524 19525 # Now try to locate executable using which 19526 new_path=`$WHICH "$new_path" 2> /dev/null` 19527 # bat and cmd files are not always considered executable in cygwin causing which 19528 # to not find them 19529 if test "x$new_path" = x \ 19530 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19531 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19532 new_path=`$CYGPATH -u "$path"` 19533 fi 19534 if test "x$new_path" = x; then 19535 # Oops. Which didn't find the executable. 19536 # The splitting of arguments from the executable at a space might have been incorrect, 19537 # since paths with space are more likely in Windows. Give it another try with the whole 19538 # argument. 19539 path="$complete" 19540 arguments="EOL" 19541 new_path=`$CYGPATH -u "$path"` 19542 new_path=`$WHICH "$new_path" 2> /dev/null` 19543 # bat and cmd files are not always considered executable in cygwin causing which 19544 # to not find them 19545 if test "x$new_path" = x \ 19546 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19547 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19548 new_path=`$CYGPATH -u "$path"` 19549 fi 19550 if test "x$new_path" = x; then 19551 # It's still not found. Now this is an unrecoverable error. 19552 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19553 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19554 has_space=`$ECHO "$complete" | $GREP " "` 19555 if test "x$has_space" != x; then 19556 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19557 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19558 fi 19559 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19560 fi 19561 fi 19562 19563 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19564 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19565 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19566 # "foo.exe" is OK but "foo" is an error. 19567 # 19568 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19569 # It is also a way to make sure we got the proper file name for the real test later on. 19570 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19571 if test "x$test_shortpath" = x; then 19572 # Short path failed, file does not exist as specified. 19573 # Try adding .exe or .cmd 19574 if test -f "${new_path}.exe"; then 19575 input_to_shortpath="${new_path}.exe" 19576 elif test -f "${new_path}.cmd"; then 19577 input_to_shortpath="${new_path}.cmd" 19578 else 19579 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19580 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19581 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19582 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19583 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19584 fi 19585 else 19586 input_to_shortpath="$new_path" 19587 fi 19588 19589 # Call helper function which possibly converts this using DOS-style short mode. 19590 # If so, the updated path is stored in $new_path. 19591 new_path="$input_to_shortpath" 19592 19593 input_path="$input_to_shortpath" 19594 # Check if we need to convert this using DOS-style short mode. If the path 19595 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19596 # take no chances and rewrite it. 19597 # Note: m4 eats our [], so we need to use [ and ] instead. 19598 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19599 if test "x$has_forbidden_chars" != x; then 19600 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19601 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19602 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19603 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19604 # Going to short mode and back again did indeed matter. Since short mode is 19605 # case insensitive, let's make it lowercase to improve readability. 19606 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19607 # Now convert it back to Unix-style (cygpath) 19608 input_path=`$CYGPATH -u "$shortmode_path"` 19609 new_path="$input_path" 19610 fi 19611 fi 19612 19613 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19614 if test "x$test_cygdrive_prefix" = x; then 19615 # As a simple fix, exclude /usr/bin since it's not a real path. 19616 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19617 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19618 # a path prefixed by /cygdrive for fixpath to work. 19619 new_path="$CYGWIN_ROOT_PATH$input_path" 19620 fi 19621 fi 19622 19623 # remove trailing .exe if any 19624 new_path="${new_path/%.exe/}" 19625 19626 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19627 19628 # First separate the path from the arguments. This will split at the first 19629 # space. 19630 complete="$FOUND_MAKE" 19631 path="${complete%% *}" 19632 tmp="$complete EOL" 19633 arguments="${tmp#* }" 19634 19635 # Input might be given as Windows format, start by converting to 19636 # unix format. 19637 new_path="$path" 19638 19639 windows_path="$new_path" 19640 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19641 unix_path=`$CYGPATH -u "$windows_path"` 19642 new_path="$unix_path" 19643 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19644 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19645 new_path="$unix_path" 19646 fi 19647 19648 19649 # Now try to locate executable using which 19650 new_path=`$WHICH "$new_path" 2> /dev/null` 19651 19652 if test "x$new_path" = x; then 19653 # Oops. Which didn't find the executable. 19654 # The splitting of arguments from the executable at a space might have been incorrect, 19655 # since paths with space are more likely in Windows. Give it another try with the whole 19656 # argument. 19657 path="$complete" 19658 arguments="EOL" 19659 new_path="$path" 19660 19661 windows_path="$new_path" 19662 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19663 unix_path=`$CYGPATH -u "$windows_path"` 19664 new_path="$unix_path" 19665 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19666 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19667 new_path="$unix_path" 19668 fi 19669 19670 19671 new_path=`$WHICH "$new_path" 2> /dev/null` 19672 # bat and cmd files are not always considered executable in MSYS 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="$path" 19678 19679 windows_path="$new_path" 19680 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19681 unix_path=`$CYGPATH -u "$windows_path"` 19682 new_path="$unix_path" 19683 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19684 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19685 new_path="$unix_path" 19686 fi 19687 19688 fi 19689 19690 if test "x$new_path" = x; then 19691 # It's still not found. Now this is an unrecoverable error. 19692 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19693 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19694 has_space=`$ECHO "$complete" | $GREP " "` 19695 if test "x$has_space" != x; then 19696 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19697 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19698 fi 19699 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19700 fi 19701 fi 19702 19703 # Now new_path has a complete unix path to the binary 19704 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19705 # Keep paths in /bin as-is, but remove trailing .exe if any 19706 new_path="${new_path/%.exe/}" 19707 # Do not save /bin paths to all_fixpath_prefixes! 19708 else 19709 # Not in mixed or Windows style, start by that. 19710 new_path=`cmd //c echo $new_path` 19711 19712 input_path="$new_path" 19713 # Check if we need to convert this using DOS-style short mode. If the path 19714 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19715 # take no chances and rewrite it. 19716 # Note: m4 eats our [], so we need to use [ and ] instead. 19717 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19718 if test "x$has_forbidden_chars" != x; then 19719 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19720 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19721 fi 19722 19723 # Output is in $new_path 19724 19725 windows_path="$new_path" 19726 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19727 unix_path=`$CYGPATH -u "$windows_path"` 19728 new_path="$unix_path" 19729 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19730 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19731 new_path="$unix_path" 19732 fi 19733 19734 # remove trailing .exe if any 19735 new_path="${new_path/%.exe/}" 19736 19737 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19738 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19739 fi 19740 19741 else 19742 # We're on a unix platform. Hooray! :) 19743 # First separate the path from the arguments. This will split at the first 19744 # space. 19745 complete="$FOUND_MAKE" 19746 path="${complete%% *}" 19747 tmp="$complete EOL" 19748 arguments="${tmp#* }" 19749 19750 # Cannot rely on the command "which" here since it doesn't always work. 19751 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19752 if test -z "$is_absolute_path"; then 19753 # Path to executable is not absolute. Find it. 19754 IFS_save="$IFS" 19755 IFS=: 19756 for p in $PATH; do 19757 if test -f "$p/$path" && test -x "$p/$path"; then 19758 new_path="$p/$path" 19759 break 19760 fi 19761 done 19762 IFS="$IFS_save" 19763 else 19764 # This is an absolute path, we can use it without further modifications. 19765 new_path="$path" 19766 fi 19767 19768 if test "x$new_path" = x; then 19769 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19770 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19771 has_space=`$ECHO "$complete" | $GREP " "` 19772 if test "x$has_space" != x; then 19773 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19774 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19775 fi 19776 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19777 fi 19778 fi 19779 19780 # Now join together the path and the arguments once again 19781 if test "x$arguments" != xEOL; then 19782 new_complete="$new_path ${arguments% *}" 19783 else 19784 new_complete="$new_path" 19785 fi 19786 19787 if test "x$complete" != "x$new_complete"; then 19788 FOUND_MAKE="$new_complete" 19789 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19790 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19791 fi 19792 fi 19793 19794 fi 19795 fi 19796 fi 19797 fi 19798 19799 19800 if test "x$FOUND_MAKE" = x; then 19801 for ac_prog in make 19802 do 19803 # Extract the first word of "$ac_prog", so it can be a program name with args. 19804 set dummy $ac_prog; ac_word=$2 19805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19806 $as_echo_n "checking for $ac_word... " >&6; } 19807 if ${ac_cv_path_CHECK_MAKE+:} false; then : 19808 $as_echo_n "(cached) " >&6 19809 else 19810 case $CHECK_MAKE in 19811 [\\/]* | ?:[\\/]*) 19812 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 19813 ;; 19814 *) 19815 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19816 for as_dir in $PATH 19817 do 19818 IFS=$as_save_IFS 19819 test -z "$as_dir" && as_dir=. 19820 for ac_exec_ext in '' $ac_executable_extensions; do 19821 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19822 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 19823 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19824 break 2 19825 fi 19826 done 19827 done 19828 IFS=$as_save_IFS 19829 19830 ;; 19831 esac 19832 fi 19833 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 19834 if test -n "$CHECK_MAKE"; then 19835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 19836 $as_echo "$CHECK_MAKE" >&6; } 19837 else 19838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19839 $as_echo "no" >&6; } 19840 fi 19841 19842 19843 test -n "$CHECK_MAKE" && break 19844 done 19845 19846 19847 MAKE_CANDIDATE=""$CHECK_MAKE"" 19848 DESCRIPTION="make in PATH" 19849 19850 # On Cygwin, we require a newer version of make than on other platforms 19851 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19852 MAKE_VERSION_EXPR="-e 4\." 19853 MAKE_REQUIRED_VERSION="4.0" 19854 else 19855 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19856 MAKE_REQUIRED_VERSION="3.81" 19857 fi 19858 19859 if test "x$MAKE_CANDIDATE" != x; then 19860 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19861 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19862 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19863 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19864 if test "x$IS_GNU_MAKE" = x; then 19865 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19866 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19867 else 19868 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19869 if test "x$IS_MODERN_MAKE" = x; then 19870 { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5 19871 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;} 19872 else 19873 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19874 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19875 MAKE_EXPECTED_ENV='cygwin' 19876 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19877 MAKE_EXPECTED_ENV='msys' 19878 else 19879 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19880 fi 19881 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19882 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19883 else 19884 # Not relevant for non-Windows 19885 IS_MAKE_CORRECT_ENV=true 19886 fi 19887 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19888 { $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 19889 $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;} 19890 else 19891 FOUND_MAKE=$MAKE_CANDIDATE 19892 19893 # Only process if variable expands to non-empty 19894 19895 if test "x$FOUND_MAKE" != x; then 19896 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19897 19898 # First separate the path from the arguments. This will split at the first 19899 # space. 19900 complete="$FOUND_MAKE" 19901 path="${complete%% *}" 19902 tmp="$complete EOL" 19903 arguments="${tmp#* }" 19904 19905 # Input might be given as Windows format, start by converting to 19906 # unix format. 19907 new_path=`$CYGPATH -u "$path"` 19908 19909 # Now try to locate executable using which 19910 new_path=`$WHICH "$new_path" 2> /dev/null` 19911 # bat and cmd files are not always considered executable in cygwin causing which 19912 # to not find them 19913 if test "x$new_path" = x \ 19914 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19915 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19916 new_path=`$CYGPATH -u "$path"` 19917 fi 19918 if test "x$new_path" = x; then 19919 # Oops. Which didn't find the executable. 19920 # The splitting of arguments from the executable at a space might have been incorrect, 19921 # since paths with space are more likely in Windows. Give it another try with the whole 19922 # argument. 19923 path="$complete" 19924 arguments="EOL" 19925 new_path=`$CYGPATH -u "$path"` 19926 new_path=`$WHICH "$new_path" 2> /dev/null` 19927 # bat and cmd files are not always considered executable in cygwin causing which 19928 # to not find them 19929 if test "x$new_path" = x \ 19930 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19931 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19932 new_path=`$CYGPATH -u "$path"` 19933 fi 19934 if test "x$new_path" = x; then 19935 # It's still not found. Now this is an unrecoverable error. 19936 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19937 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19938 has_space=`$ECHO "$complete" | $GREP " "` 19939 if test "x$has_space" != x; then 19940 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19941 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19942 fi 19943 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19944 fi 19945 fi 19946 19947 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19948 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19949 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19950 # "foo.exe" is OK but "foo" is an error. 19951 # 19952 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19953 # It is also a way to make sure we got the proper file name for the real test later on. 19954 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19955 if test "x$test_shortpath" = x; then 19956 # Short path failed, file does not exist as specified. 19957 # Try adding .exe or .cmd 19958 if test -f "${new_path}.exe"; then 19959 input_to_shortpath="${new_path}.exe" 19960 elif test -f "${new_path}.cmd"; then 19961 input_to_shortpath="${new_path}.cmd" 19962 else 19963 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19964 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19965 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19966 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19967 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19968 fi 19969 else 19970 input_to_shortpath="$new_path" 19971 fi 19972 19973 # Call helper function which possibly converts this using DOS-style short mode. 19974 # If so, the updated path is stored in $new_path. 19975 new_path="$input_to_shortpath" 19976 19977 input_path="$input_to_shortpath" 19978 # Check if we need to convert this using DOS-style short mode. If the path 19979 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19980 # take no chances and rewrite it. 19981 # Note: m4 eats our [], so we need to use [ and ] instead. 19982 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19983 if test "x$has_forbidden_chars" != x; then 19984 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19985 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19986 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19987 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19988 # Going to short mode and back again did indeed matter. Since short mode is 19989 # case insensitive, let's make it lowercase to improve readability. 19990 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19991 # Now convert it back to Unix-style (cygpath) 19992 input_path=`$CYGPATH -u "$shortmode_path"` 19993 new_path="$input_path" 19994 fi 19995 fi 19996 19997 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19998 if test "x$test_cygdrive_prefix" = x; then 19999 # As a simple fix, exclude /usr/bin since it's not a real path. 20000 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20001 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20002 # a path prefixed by /cygdrive for fixpath to work. 20003 new_path="$CYGWIN_ROOT_PATH$input_path" 20004 fi 20005 fi 20006 20007 # remove trailing .exe if any 20008 new_path="${new_path/%.exe/}" 20009 20010 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20011 20012 # First separate the path from the arguments. This will split at the first 20013 # space. 20014 complete="$FOUND_MAKE" 20015 path="${complete%% *}" 20016 tmp="$complete EOL" 20017 arguments="${tmp#* }" 20018 20019 # Input might be given as Windows format, start by converting to 20020 # unix format. 20021 new_path="$path" 20022 20023 windows_path="$new_path" 20024 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20025 unix_path=`$CYGPATH -u "$windows_path"` 20026 new_path="$unix_path" 20027 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20028 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20029 new_path="$unix_path" 20030 fi 20031 20032 20033 # Now try to locate executable using which 20034 new_path=`$WHICH "$new_path" 2> /dev/null` 20035 20036 if test "x$new_path" = x; then 20037 # Oops. Which didn't find the executable. 20038 # The splitting of arguments from the executable at a space might have been incorrect, 20039 # since paths with space are more likely in Windows. Give it another try with the whole 20040 # argument. 20041 path="$complete" 20042 arguments="EOL" 20043 new_path="$path" 20044 20045 windows_path="$new_path" 20046 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20047 unix_path=`$CYGPATH -u "$windows_path"` 20048 new_path="$unix_path" 20049 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20050 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20051 new_path="$unix_path" 20052 fi 20053 20054 20055 new_path=`$WHICH "$new_path" 2> /dev/null` 20056 # bat and cmd files are not always considered executable in MSYS causing which 20057 # to not find them 20058 if test "x$new_path" = x \ 20059 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20060 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20061 new_path="$path" 20062 20063 windows_path="$new_path" 20064 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20065 unix_path=`$CYGPATH -u "$windows_path"` 20066 new_path="$unix_path" 20067 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20068 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20069 new_path="$unix_path" 20070 fi 20071 20072 fi 20073 20074 if test "x$new_path" = x; then 20075 # It's still not found. Now this is an unrecoverable error. 20076 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20077 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20078 has_space=`$ECHO "$complete" | $GREP " "` 20079 if test "x$has_space" != x; then 20080 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20081 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20082 fi 20083 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20084 fi 20085 fi 20086 20087 # Now new_path has a complete unix path to the binary 20088 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20089 # Keep paths in /bin as-is, but remove trailing .exe if any 20090 new_path="${new_path/%.exe/}" 20091 # Do not save /bin paths to all_fixpath_prefixes! 20092 else 20093 # Not in mixed or Windows style, start by that. 20094 new_path=`cmd //c echo $new_path` 20095 20096 input_path="$new_path" 20097 # Check if we need to convert this using DOS-style short mode. If the path 20098 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20099 # take no chances and rewrite it. 20100 # Note: m4 eats our [], so we need to use [ and ] instead. 20101 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20102 if test "x$has_forbidden_chars" != x; then 20103 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20104 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20105 fi 20106 20107 # Output is in $new_path 20108 20109 windows_path="$new_path" 20110 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20111 unix_path=`$CYGPATH -u "$windows_path"` 20112 new_path="$unix_path" 20113 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20114 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20115 new_path="$unix_path" 20116 fi 20117 20118 # remove trailing .exe if any 20119 new_path="${new_path/%.exe/}" 20120 20121 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20122 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20123 fi 20124 20125 else 20126 # We're on a unix platform. Hooray! :) 20127 # First separate the path from the arguments. This will split at the first 20128 # space. 20129 complete="$FOUND_MAKE" 20130 path="${complete%% *}" 20131 tmp="$complete EOL" 20132 arguments="${tmp#* }" 20133 20134 # Cannot rely on the command "which" here since it doesn't always work. 20135 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20136 if test -z "$is_absolute_path"; then 20137 # Path to executable is not absolute. Find it. 20138 IFS_save="$IFS" 20139 IFS=: 20140 for p in $PATH; do 20141 if test -f "$p/$path" && test -x "$p/$path"; then 20142 new_path="$p/$path" 20143 break 20144 fi 20145 done 20146 IFS="$IFS_save" 20147 else 20148 # This is an absolute path, we can use it without further modifications. 20149 new_path="$path" 20150 fi 20151 20152 if test "x$new_path" = x; then 20153 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20154 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20155 has_space=`$ECHO "$complete" | $GREP " "` 20156 if test "x$has_space" != x; then 20157 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20158 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20159 fi 20160 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20161 fi 20162 fi 20163 20164 # Now join together the path and the arguments once again 20165 if test "x$arguments" != xEOL; then 20166 new_complete="$new_path ${arguments% *}" 20167 else 20168 new_complete="$new_path" 20169 fi 20170 20171 if test "x$complete" != "x$new_complete"; then 20172 FOUND_MAKE="$new_complete" 20173 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20174 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20175 fi 20176 fi 20177 20178 fi 20179 fi 20180 fi 20181 fi 20182 20183 fi 20184 20185 if test "x$FOUND_MAKE" = x; then 20186 if test "x$TOOLCHAIN_PATH" != x; then 20187 # We have a toolchain path, check that as well before giving up. 20188 OLD_PATH=$PATH 20189 PATH=$TOOLCHAIN_PATH:$PATH 20190 for ac_prog in gmake 20191 do 20192 # Extract the first word of "$ac_prog", so it can be a program name with args. 20193 set dummy $ac_prog; ac_word=$2 20194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20195 $as_echo_n "checking for $ac_word... " >&6; } 20196 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 20197 $as_echo_n "(cached) " >&6 20198 else 20199 case $CHECK_TOOLSDIR_GMAKE in 20200 [\\/]* | ?:[\\/]*) 20201 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 20202 ;; 20203 *) 20204 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20205 for as_dir in $PATH 20206 do 20207 IFS=$as_save_IFS 20208 test -z "$as_dir" && as_dir=. 20209 for ac_exec_ext in '' $ac_executable_extensions; do 20210 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20211 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 20212 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20213 break 2 20214 fi 20215 done 20216 done 20217 IFS=$as_save_IFS 20218 20219 ;; 20220 esac 20221 fi 20222 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 20223 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 20224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 20225 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 20226 else 20227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20228 $as_echo "no" >&6; } 20229 fi 20230 20231 20232 test -n "$CHECK_TOOLSDIR_GMAKE" && break 20233 done 20234 20235 20236 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 20237 DESCRIPTION="gmake in tools-dir" 20238 20239 # On Cygwin, we require a newer version of make than on other platforms 20240 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20241 MAKE_VERSION_EXPR="-e 4\." 20242 MAKE_REQUIRED_VERSION="4.0" 20243 else 20244 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20245 MAKE_REQUIRED_VERSION="3.81" 20246 fi 20247 20248 if test "x$MAKE_CANDIDATE" != x; then 20249 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20250 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20251 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20252 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20253 if test "x$IS_GNU_MAKE" = x; then 20254 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20255 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20256 else 20257 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20258 if test "x$IS_MODERN_MAKE" = x; then 20259 { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5 20260 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;} 20261 else 20262 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20263 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20264 MAKE_EXPECTED_ENV='cygwin' 20265 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20266 MAKE_EXPECTED_ENV='msys' 20267 else 20268 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20269 fi 20270 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20271 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20272 else 20273 # Not relevant for non-Windows 20274 IS_MAKE_CORRECT_ENV=true 20275 fi 20276 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20277 { $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 20278 $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;} 20279 else 20280 FOUND_MAKE=$MAKE_CANDIDATE 20281 20282 # Only process if variable expands to non-empty 20283 20284 if test "x$FOUND_MAKE" != x; then 20285 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20286 20287 # First separate the path from the arguments. This will split at the first 20288 # space. 20289 complete="$FOUND_MAKE" 20290 path="${complete%% *}" 20291 tmp="$complete EOL" 20292 arguments="${tmp#* }" 20293 20294 # Input might be given as Windows format, start by converting to 20295 # unix format. 20296 new_path=`$CYGPATH -u "$path"` 20297 20298 # Now try to locate executable using which 20299 new_path=`$WHICH "$new_path" 2> /dev/null` 20300 # bat and cmd files are not always considered executable in cygwin causing which 20301 # to not find them 20302 if test "x$new_path" = x \ 20303 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20304 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20305 new_path=`$CYGPATH -u "$path"` 20306 fi 20307 if test "x$new_path" = x; then 20308 # Oops. Which didn't find the executable. 20309 # The splitting of arguments from the executable at a space might have been incorrect, 20310 # since paths with space are more likely in Windows. Give it another try with the whole 20311 # argument. 20312 path="$complete" 20313 arguments="EOL" 20314 new_path=`$CYGPATH -u "$path"` 20315 new_path=`$WHICH "$new_path" 2> /dev/null` 20316 # bat and cmd files are not always considered executable in cygwin causing which 20317 # to not find them 20318 if test "x$new_path" = x \ 20319 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20320 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20321 new_path=`$CYGPATH -u "$path"` 20322 fi 20323 if test "x$new_path" = x; then 20324 # It's still not found. Now this is an unrecoverable error. 20325 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20326 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20327 has_space=`$ECHO "$complete" | $GREP " "` 20328 if test "x$has_space" != x; then 20329 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20330 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20331 fi 20332 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20333 fi 20334 fi 20335 20336 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20337 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20338 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20339 # "foo.exe" is OK but "foo" is an error. 20340 # 20341 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20342 # It is also a way to make sure we got the proper file name for the real test later on. 20343 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20344 if test "x$test_shortpath" = x; then 20345 # Short path failed, file does not exist as specified. 20346 # Try adding .exe or .cmd 20347 if test -f "${new_path}.exe"; then 20348 input_to_shortpath="${new_path}.exe" 20349 elif test -f "${new_path}.cmd"; then 20350 input_to_shortpath="${new_path}.cmd" 20351 else 20352 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20353 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20354 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20355 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20356 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20357 fi 20358 else 20359 input_to_shortpath="$new_path" 20360 fi 20361 20362 # Call helper function which possibly converts this using DOS-style short mode. 20363 # If so, the updated path is stored in $new_path. 20364 new_path="$input_to_shortpath" 20365 20366 input_path="$input_to_shortpath" 20367 # Check if we need to convert this using DOS-style short mode. If the path 20368 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20369 # take no chances and rewrite it. 20370 # Note: m4 eats our [], so we need to use [ and ] instead. 20371 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20372 if test "x$has_forbidden_chars" != x; then 20373 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20374 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20375 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20376 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20377 # Going to short mode and back again did indeed matter. Since short mode is 20378 # case insensitive, let's make it lowercase to improve readability. 20379 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20380 # Now convert it back to Unix-style (cygpath) 20381 input_path=`$CYGPATH -u "$shortmode_path"` 20382 new_path="$input_path" 20383 fi 20384 fi 20385 20386 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20387 if test "x$test_cygdrive_prefix" = x; then 20388 # As a simple fix, exclude /usr/bin since it's not a real path. 20389 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20390 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20391 # a path prefixed by /cygdrive for fixpath to work. 20392 new_path="$CYGWIN_ROOT_PATH$input_path" 20393 fi 20394 fi 20395 20396 # remove trailing .exe if any 20397 new_path="${new_path/%.exe/}" 20398 20399 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20400 20401 # First separate the path from the arguments. This will split at the first 20402 # space. 20403 complete="$FOUND_MAKE" 20404 path="${complete%% *}" 20405 tmp="$complete EOL" 20406 arguments="${tmp#* }" 20407 20408 # Input might be given as Windows format, start by converting to 20409 # unix format. 20410 new_path="$path" 20411 20412 windows_path="$new_path" 20413 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20414 unix_path=`$CYGPATH -u "$windows_path"` 20415 new_path="$unix_path" 20416 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20417 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20418 new_path="$unix_path" 20419 fi 20420 20421 20422 # Now try to locate executable using which 20423 new_path=`$WHICH "$new_path" 2> /dev/null` 20424 20425 if test "x$new_path" = x; then 20426 # Oops. Which didn't find the executable. 20427 # The splitting of arguments from the executable at a space might have been incorrect, 20428 # since paths with space are more likely in Windows. Give it another try with the whole 20429 # argument. 20430 path="$complete" 20431 arguments="EOL" 20432 new_path="$path" 20433 20434 windows_path="$new_path" 20435 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20436 unix_path=`$CYGPATH -u "$windows_path"` 20437 new_path="$unix_path" 20438 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20439 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20440 new_path="$unix_path" 20441 fi 20442 20443 20444 new_path=`$WHICH "$new_path" 2> /dev/null` 20445 # bat and cmd files are not always considered executable in MSYS causing which 20446 # to not find them 20447 if test "x$new_path" = x \ 20448 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20449 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20450 new_path="$path" 20451 20452 windows_path="$new_path" 20453 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20454 unix_path=`$CYGPATH -u "$windows_path"` 20455 new_path="$unix_path" 20456 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20457 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20458 new_path="$unix_path" 20459 fi 20460 20461 fi 20462 20463 if test "x$new_path" = x; then 20464 # It's still not found. Now this is an unrecoverable error. 20465 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20466 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20467 has_space=`$ECHO "$complete" | $GREP " "` 20468 if test "x$has_space" != x; then 20469 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20470 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20471 fi 20472 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20473 fi 20474 fi 20475 20476 # Now new_path has a complete unix path to the binary 20477 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20478 # Keep paths in /bin as-is, but remove trailing .exe if any 20479 new_path="${new_path/%.exe/}" 20480 # Do not save /bin paths to all_fixpath_prefixes! 20481 else 20482 # Not in mixed or Windows style, start by that. 20483 new_path=`cmd //c echo $new_path` 20484 20485 input_path="$new_path" 20486 # Check if we need to convert this using DOS-style short mode. If the path 20487 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20488 # take no chances and rewrite it. 20489 # Note: m4 eats our [], so we need to use [ and ] instead. 20490 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20491 if test "x$has_forbidden_chars" != x; then 20492 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20493 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20494 fi 20495 20496 # Output is in $new_path 20497 20498 windows_path="$new_path" 20499 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20500 unix_path=`$CYGPATH -u "$windows_path"` 20501 new_path="$unix_path" 20502 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20503 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20504 new_path="$unix_path" 20505 fi 20506 20507 # remove trailing .exe if any 20508 new_path="${new_path/%.exe/}" 20509 20510 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20511 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20512 fi 20513 20514 else 20515 # We're on a unix platform. Hooray! :) 20516 # First separate the path from the arguments. This will split at the first 20517 # space. 20518 complete="$FOUND_MAKE" 20519 path="${complete%% *}" 20520 tmp="$complete EOL" 20521 arguments="${tmp#* }" 20522 20523 # Cannot rely on the command "which" here since it doesn't always work. 20524 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20525 if test -z "$is_absolute_path"; then 20526 # Path to executable is not absolute. Find it. 20527 IFS_save="$IFS" 20528 IFS=: 20529 for p in $PATH; do 20530 if test -f "$p/$path" && test -x "$p/$path"; then 20531 new_path="$p/$path" 20532 break 20533 fi 20534 done 20535 IFS="$IFS_save" 20536 else 20537 # This is an absolute path, we can use it without further modifications. 20538 new_path="$path" 20539 fi 20540 20541 if test "x$new_path" = x; then 20542 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20543 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20544 has_space=`$ECHO "$complete" | $GREP " "` 20545 if test "x$has_space" != x; then 20546 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20547 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20548 fi 20549 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20550 fi 20551 fi 20552 20553 # Now join together the path and the arguments once again 20554 if test "x$arguments" != xEOL; then 20555 new_complete="$new_path ${arguments% *}" 20556 else 20557 new_complete="$new_path" 20558 fi 20559 20560 if test "x$complete" != "x$new_complete"; then 20561 FOUND_MAKE="$new_complete" 20562 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20563 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20564 fi 20565 fi 20566 20567 fi 20568 fi 20569 fi 20570 fi 20571 20572 if test "x$FOUND_MAKE" = x; then 20573 for ac_prog in make 20574 do 20575 # Extract the first word of "$ac_prog", so it can be a program name with args. 20576 set dummy $ac_prog; ac_word=$2 20577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20578 $as_echo_n "checking for $ac_word... " >&6; } 20579 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 20580 $as_echo_n "(cached) " >&6 20581 else 20582 case $CHECK_TOOLSDIR_MAKE in 20583 [\\/]* | ?:[\\/]*) 20584 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 20585 ;; 20586 *) 20587 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20588 for as_dir in $PATH 20589 do 20590 IFS=$as_save_IFS 20591 test -z "$as_dir" && as_dir=. 20592 for ac_exec_ext in '' $ac_executable_extensions; do 20593 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20594 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 20595 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20596 break 2 20597 fi 20598 done 20599 done 20600 IFS=$as_save_IFS 20601 20602 ;; 20603 esac 20604 fi 20605 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 20606 if test -n "$CHECK_TOOLSDIR_MAKE"; then 20607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 20608 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 20609 else 20610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20611 $as_echo "no" >&6; } 20612 fi 20613 20614 20615 test -n "$CHECK_TOOLSDIR_MAKE" && break 20616 done 20617 20618 20619 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 20620 DESCRIPTION="make in tools-dir" 20621 20622 # On Cygwin, we require a newer version of make than on other platforms 20623 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20624 MAKE_VERSION_EXPR="-e 4\." 20625 MAKE_REQUIRED_VERSION="4.0" 20626 else 20627 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20628 MAKE_REQUIRED_VERSION="3.81" 20629 fi 20630 20631 if test "x$MAKE_CANDIDATE" != x; then 20632 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20633 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20634 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20635 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20636 if test "x$IS_GNU_MAKE" = x; then 20637 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20638 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20639 else 20640 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20641 if test "x$IS_MODERN_MAKE" = x; then 20642 { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5 20643 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;} 20644 else 20645 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20646 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20647 MAKE_EXPECTED_ENV='cygwin' 20648 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20649 MAKE_EXPECTED_ENV='msys' 20650 else 20651 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20652 fi 20653 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20654 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20655 else 20656 # Not relevant for non-Windows 20657 IS_MAKE_CORRECT_ENV=true 20658 fi 20659 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20660 { $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 20661 $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;} 20662 else 20663 FOUND_MAKE=$MAKE_CANDIDATE 20664 20665 # Only process if variable expands to non-empty 20666 20667 if test "x$FOUND_MAKE" != x; then 20668 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20669 20670 # First separate the path from the arguments. This will split at the first 20671 # space. 20672 complete="$FOUND_MAKE" 20673 path="${complete%% *}" 20674 tmp="$complete EOL" 20675 arguments="${tmp#* }" 20676 20677 # Input might be given as Windows format, start by converting to 20678 # unix format. 20679 new_path=`$CYGPATH -u "$path"` 20680 20681 # Now try to locate executable using which 20682 new_path=`$WHICH "$new_path" 2> /dev/null` 20683 # bat and cmd files are not always considered executable in cygwin causing which 20684 # to not find them 20685 if test "x$new_path" = x \ 20686 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20687 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20688 new_path=`$CYGPATH -u "$path"` 20689 fi 20690 if test "x$new_path" = x; then 20691 # Oops. Which didn't find the executable. 20692 # The splitting of arguments from the executable at a space might have been incorrect, 20693 # since paths with space are more likely in Windows. Give it another try with the whole 20694 # argument. 20695 path="$complete" 20696 arguments="EOL" 20697 new_path=`$CYGPATH -u "$path"` 20698 new_path=`$WHICH "$new_path" 2> /dev/null` 20699 # bat and cmd files are not always considered executable in cygwin causing which 20700 # to not find them 20701 if test "x$new_path" = x \ 20702 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20703 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20704 new_path=`$CYGPATH -u "$path"` 20705 fi 20706 if test "x$new_path" = x; then 20707 # It's still not found. Now this is an unrecoverable error. 20708 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20709 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20710 has_space=`$ECHO "$complete" | $GREP " "` 20711 if test "x$has_space" != x; then 20712 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20713 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20714 fi 20715 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20716 fi 20717 fi 20718 20719 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20720 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20721 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20722 # "foo.exe" is OK but "foo" is an error. 20723 # 20724 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20725 # It is also a way to make sure we got the proper file name for the real test later on. 20726 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20727 if test "x$test_shortpath" = x; then 20728 # Short path failed, file does not exist as specified. 20729 # Try adding .exe or .cmd 20730 if test -f "${new_path}.exe"; then 20731 input_to_shortpath="${new_path}.exe" 20732 elif test -f "${new_path}.cmd"; then 20733 input_to_shortpath="${new_path}.cmd" 20734 else 20735 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20736 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20737 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20738 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20739 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20740 fi 20741 else 20742 input_to_shortpath="$new_path" 20743 fi 20744 20745 # Call helper function which possibly converts this using DOS-style short mode. 20746 # If so, the updated path is stored in $new_path. 20747 new_path="$input_to_shortpath" 20748 20749 input_path="$input_to_shortpath" 20750 # Check if we need to convert this using DOS-style short mode. If the path 20751 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20752 # take no chances and rewrite it. 20753 # Note: m4 eats our [], so we need to use [ and ] instead. 20754 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20755 if test "x$has_forbidden_chars" != x; then 20756 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20757 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20758 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20759 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20760 # Going to short mode and back again did indeed matter. Since short mode is 20761 # case insensitive, let's make it lowercase to improve readability. 20762 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20763 # Now convert it back to Unix-style (cygpath) 20764 input_path=`$CYGPATH -u "$shortmode_path"` 20765 new_path="$input_path" 20766 fi 20767 fi 20768 20769 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20770 if test "x$test_cygdrive_prefix" = x; then 20771 # As a simple fix, exclude /usr/bin since it's not a real path. 20772 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20773 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20774 # a path prefixed by /cygdrive for fixpath to work. 20775 new_path="$CYGWIN_ROOT_PATH$input_path" 20776 fi 20777 fi 20778 20779 # remove trailing .exe if any 20780 new_path="${new_path/%.exe/}" 20781 20782 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20783 20784 # First separate the path from the arguments. This will split at the first 20785 # space. 20786 complete="$FOUND_MAKE" 20787 path="${complete%% *}" 20788 tmp="$complete EOL" 20789 arguments="${tmp#* }" 20790 20791 # Input might be given as Windows format, start by converting to 20792 # unix format. 20793 new_path="$path" 20794 20795 windows_path="$new_path" 20796 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20797 unix_path=`$CYGPATH -u "$windows_path"` 20798 new_path="$unix_path" 20799 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20800 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20801 new_path="$unix_path" 20802 fi 20803 20804 20805 # Now try to locate executable using which 20806 new_path=`$WHICH "$new_path" 2> /dev/null` 20807 20808 if test "x$new_path" = x; then 20809 # Oops. Which didn't find the executable. 20810 # The splitting of arguments from the executable at a space might have been incorrect, 20811 # since paths with space are more likely in Windows. Give it another try with the whole 20812 # argument. 20813 path="$complete" 20814 arguments="EOL" 20815 new_path="$path" 20816 20817 windows_path="$new_path" 20818 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20819 unix_path=`$CYGPATH -u "$windows_path"` 20820 new_path="$unix_path" 20821 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20822 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20823 new_path="$unix_path" 20824 fi 20825 20826 20827 new_path=`$WHICH "$new_path" 2> /dev/null` 20828 # bat and cmd files are not always considered executable in MSYS causing which 20829 # to not find them 20830 if test "x$new_path" = x \ 20831 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20832 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20833 new_path="$path" 20834 20835 windows_path="$new_path" 20836 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20837 unix_path=`$CYGPATH -u "$windows_path"` 20838 new_path="$unix_path" 20839 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20840 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20841 new_path="$unix_path" 20842 fi 20843 20844 fi 20845 20846 if test "x$new_path" = x; then 20847 # It's still not found. Now this is an unrecoverable error. 20848 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20849 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20850 has_space=`$ECHO "$complete" | $GREP " "` 20851 if test "x$has_space" != x; then 20852 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20853 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20854 fi 20855 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20856 fi 20857 fi 20858 20859 # Now new_path has a complete unix path to the binary 20860 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20861 # Keep paths in /bin as-is, but remove trailing .exe if any 20862 new_path="${new_path/%.exe/}" 20863 # Do not save /bin paths to all_fixpath_prefixes! 20864 else 20865 # Not in mixed or Windows style, start by that. 20866 new_path=`cmd //c echo $new_path` 20867 20868 input_path="$new_path" 20869 # Check if we need to convert this using DOS-style short mode. If the path 20870 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20871 # take no chances and rewrite it. 20872 # Note: m4 eats our [], so we need to use [ and ] instead. 20873 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20874 if test "x$has_forbidden_chars" != x; then 20875 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20876 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20877 fi 20878 20879 # Output is in $new_path 20880 20881 windows_path="$new_path" 20882 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20883 unix_path=`$CYGPATH -u "$windows_path"` 20884 new_path="$unix_path" 20885 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20886 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20887 new_path="$unix_path" 20888 fi 20889 20890 # remove trailing .exe if any 20891 new_path="${new_path/%.exe/}" 20892 20893 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20894 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20895 fi 20896 20897 else 20898 # We're on a unix platform. Hooray! :) 20899 # First separate the path from the arguments. This will split at the first 20900 # space. 20901 complete="$FOUND_MAKE" 20902 path="${complete%% *}" 20903 tmp="$complete EOL" 20904 arguments="${tmp#* }" 20905 20906 # Cannot rely on the command "which" here since it doesn't always work. 20907 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20908 if test -z "$is_absolute_path"; then 20909 # Path to executable is not absolute. Find it. 20910 IFS_save="$IFS" 20911 IFS=: 20912 for p in $PATH; do 20913 if test -f "$p/$path" && test -x "$p/$path"; then 20914 new_path="$p/$path" 20915 break 20916 fi 20917 done 20918 IFS="$IFS_save" 20919 else 20920 # This is an absolute path, we can use it without further modifications. 20921 new_path="$path" 20922 fi 20923 20924 if test "x$new_path" = x; then 20925 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20926 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20927 has_space=`$ECHO "$complete" | $GREP " "` 20928 if test "x$has_space" != x; then 20929 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20930 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20931 fi 20932 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20933 fi 20934 fi 20935 20936 # Now join together the path and the arguments once again 20937 if test "x$arguments" != xEOL; then 20938 new_complete="$new_path ${arguments% *}" 20939 else 20940 new_complete="$new_path" 20941 fi 20942 20943 if test "x$complete" != "x$new_complete"; then 20944 FOUND_MAKE="$new_complete" 20945 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20946 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20947 fi 20948 fi 20949 20950 fi 20951 fi 20952 fi 20953 fi 20954 20955 fi 20956 PATH=$OLD_PATH 20957 fi 20958 fi 20959 20960 if test "x$FOUND_MAKE" = x; then 20961 as_fn_error $? "Cannot find GNU make $MAKE_REQUIRED_VERSION or newer! Please put it in the path, or add e.g. MAKE=/opt/gmake3.81/make as argument to configure." "$LINENO" 5 20962 fi 20963 20964 else 20965 # If it succeeded, then it was overridden by the user. We will use it 20966 # for the tool. 20967 20968 # First remove it from the list of overridden variables, so we can test 20969 # for unknown variables in the end. 20970 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 20971 20972 # Check if we try to supply an empty value 20973 if test "x$MAKE" = x; then 20974 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MAKE= (no value)" >&5 20975 $as_echo "$as_me: Setting user supplied tool MAKE= (no value)" >&6;} 20976 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20977 $as_echo_n "checking for MAKE... " >&6; } 20978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 20979 $as_echo "disabled" >&6; } 20980 else 20981 # Check if the provided tool contains a complete path. 20982 tool_specified="$MAKE" 20983 tool_basename="${tool_specified##*/}" 20984 if test "x$tool_basename" = "x$tool_specified"; then 20985 # A command without a complete path is provided, search $PATH. 20986 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MAKE=$tool_basename" >&5 20987 $as_echo "$as_me: Will search for user supplied tool MAKE=$tool_basename" >&6;} 20988 # Extract the first word of "$tool_basename", so it can be a program name with args. 20989 set dummy $tool_basename; ac_word=$2 20990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20991 $as_echo_n "checking for $ac_word... " >&6; } 20992 if ${ac_cv_path_MAKE+:} false; then : 20993 $as_echo_n "(cached) " >&6 20994 else 20995 case $MAKE in 20996 [\\/]* | ?:[\\/]*) 20997 ac_cv_path_MAKE="$MAKE" # Let the user override the test with a path. 20998 ;; 20999 *) 21000 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21001 for as_dir in $PATH 21002 do 21003 IFS=$as_save_IFS 21004 test -z "$as_dir" && as_dir=. 21005 for ac_exec_ext in '' $ac_executable_extensions; do 21006 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21007 ac_cv_path_MAKE="$as_dir/$ac_word$ac_exec_ext" 21008 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21009 break 2 21010 fi 21011 done 21012 done 21013 IFS=$as_save_IFS 21014 21015 ;; 21016 esac 21017 fi 21018 MAKE=$ac_cv_path_MAKE 21019 if test -n "$MAKE"; then 21020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5 21021 $as_echo "$MAKE" >&6; } 21022 else 21023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21024 $as_echo "no" >&6; } 21025 fi 21026 21027 21028 if test "x$MAKE" = x; then 21029 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21030 fi 21031 else 21032 # Otherwise we believe it is a complete path. Use it as it is. 21033 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MAKE=$tool_specified" >&5 21034 $as_echo "$as_me: Will use user supplied tool MAKE=$tool_specified" >&6;} 21035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 21036 $as_echo_n "checking for MAKE... " >&6; } 21037 if test ! -x "$tool_specified"; then 21038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21039 $as_echo "not found" >&6; } 21040 as_fn_error $? "User supplied tool MAKE=$tool_specified does not exist or is not executable" "$LINENO" 5 21041 fi 21042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21043 $as_echo "$tool_specified" >&6; } 21044 fi 21045 fi 21046 fi 21047 21048 # If MAKE was set by user, verify the version 21049 21050 MAKE_CANDIDATE=""$MAKE"" 21051 DESCRIPTION="user supplied MAKE=$MAKE" 21052 21053 # On Cygwin, we require a newer version of make than on other platforms 21054 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21055 MAKE_VERSION_EXPR="-e 4\." 21056 MAKE_REQUIRED_VERSION="4.0" 21057 else 21058 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 21059 MAKE_REQUIRED_VERSION="3.81" 21060 fi 21061 21062 if test "x$MAKE_CANDIDATE" != x; then 21063 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 21064 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 21065 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 21066 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 21067 if test "x$IS_GNU_MAKE" = x; then 21068 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 21069 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 21070 else 21071 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 21072 if test "x$IS_MODERN_MAKE" = x; then 21073 { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5 21074 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version $MAKE_REQUIRED_VERSION or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;} 21075 else 21076 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 21077 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21078 MAKE_EXPECTED_ENV='cygwin' 21079 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21080 MAKE_EXPECTED_ENV='msys' 21081 else 21082 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 21083 fi 21084 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 21085 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 21086 else 21087 # Not relevant for non-Windows 21088 IS_MAKE_CORRECT_ENV=true 21089 fi 21090 if test "x$IS_MAKE_CORRECT_ENV" = x; then 21091 { $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 21092 $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;} 21093 else 21094 FOUND_MAKE=$MAKE_CANDIDATE 21095 21096 # Only process if variable expands to non-empty 21097 21098 if test "x$FOUND_MAKE" != x; then 21099 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21100 21101 # First separate the path from the arguments. This will split at the first 21102 # space. 21103 complete="$FOUND_MAKE" 21104 path="${complete%% *}" 21105 tmp="$complete EOL" 21106 arguments="${tmp#* }" 21107 21108 # Input might be given as Windows format, start by converting to 21109 # unix format. 21110 new_path=`$CYGPATH -u "$path"` 21111 21112 # Now try to locate executable using which 21113 new_path=`$WHICH "$new_path" 2> /dev/null` 21114 # bat and cmd files are not always considered executable in cygwin causing which 21115 # to not find them 21116 if test "x$new_path" = x \ 21117 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21118 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21119 new_path=`$CYGPATH -u "$path"` 21120 fi 21121 if test "x$new_path" = x; then 21122 # Oops. Which didn't find the executable. 21123 # The splitting of arguments from the executable at a space might have been incorrect, 21124 # since paths with space are more likely in Windows. Give it another try with the whole 21125 # argument. 21126 path="$complete" 21127 arguments="EOL" 21128 new_path=`$CYGPATH -u "$path"` 21129 new_path=`$WHICH "$new_path" 2> /dev/null` 21130 # bat and cmd files are not always considered executable in cygwin causing which 21131 # to not find them 21132 if test "x$new_path" = x \ 21133 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21134 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21135 new_path=`$CYGPATH -u "$path"` 21136 fi 21137 if test "x$new_path" = x; then 21138 # It's still not found. Now this is an unrecoverable error. 21139 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21140 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21141 has_space=`$ECHO "$complete" | $GREP " "` 21142 if test "x$has_space" != x; then 21143 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21144 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21145 fi 21146 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21147 fi 21148 fi 21149 21150 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 21151 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 21152 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 21153 # "foo.exe" is OK but "foo" is an error. 21154 # 21155 # This test is therefore slightly more accurate than "test -f" to check for file presence. 21156 # It is also a way to make sure we got the proper file name for the real test later on. 21157 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 21158 if test "x$test_shortpath" = x; then 21159 # Short path failed, file does not exist as specified. 21160 # Try adding .exe or .cmd 21161 if test -f "${new_path}.exe"; then 21162 input_to_shortpath="${new_path}.exe" 21163 elif test -f "${new_path}.cmd"; then 21164 input_to_shortpath="${new_path}.cmd" 21165 else 21166 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 21167 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 21168 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 21169 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 21170 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21171 fi 21172 else 21173 input_to_shortpath="$new_path" 21174 fi 21175 21176 # Call helper function which possibly converts this using DOS-style short mode. 21177 # If so, the updated path is stored in $new_path. 21178 new_path="$input_to_shortpath" 21179 21180 input_path="$input_to_shortpath" 21181 # Check if we need to convert this using DOS-style short mode. If the path 21182 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21183 # take no chances and rewrite it. 21184 # Note: m4 eats our [], so we need to use [ and ] instead. 21185 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 21186 if test "x$has_forbidden_chars" != x; then 21187 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21188 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 21189 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 21190 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 21191 # Going to short mode and back again did indeed matter. Since short mode is 21192 # case insensitive, let's make it lowercase to improve readability. 21193 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21194 # Now convert it back to Unix-style (cygpath) 21195 input_path=`$CYGPATH -u "$shortmode_path"` 21196 new_path="$input_path" 21197 fi 21198 fi 21199 21200 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 21201 if test "x$test_cygdrive_prefix" = x; then 21202 # As a simple fix, exclude /usr/bin since it's not a real path. 21203 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 21204 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 21205 # a path prefixed by /cygdrive for fixpath to work. 21206 new_path="$CYGWIN_ROOT_PATH$input_path" 21207 fi 21208 fi 21209 21210 # remove trailing .exe if any 21211 new_path="${new_path/%.exe/}" 21212 21213 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21214 21215 # First separate the path from the arguments. This will split at the first 21216 # space. 21217 complete="$FOUND_MAKE" 21218 path="${complete%% *}" 21219 tmp="$complete EOL" 21220 arguments="${tmp#* }" 21221 21222 # Input might be given as Windows format, start by converting to 21223 # unix format. 21224 new_path="$path" 21225 21226 windows_path="$new_path" 21227 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21228 unix_path=`$CYGPATH -u "$windows_path"` 21229 new_path="$unix_path" 21230 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21231 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21232 new_path="$unix_path" 21233 fi 21234 21235 21236 # Now try to locate executable using which 21237 new_path=`$WHICH "$new_path" 2> /dev/null` 21238 21239 if test "x$new_path" = x; then 21240 # Oops. Which didn't find the executable. 21241 # The splitting of arguments from the executable at a space might have been incorrect, 21242 # since paths with space are more likely in Windows. Give it another try with the whole 21243 # argument. 21244 path="$complete" 21245 arguments="EOL" 21246 new_path="$path" 21247 21248 windows_path="$new_path" 21249 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21250 unix_path=`$CYGPATH -u "$windows_path"` 21251 new_path="$unix_path" 21252 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21253 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21254 new_path="$unix_path" 21255 fi 21256 21257 21258 new_path=`$WHICH "$new_path" 2> /dev/null` 21259 # bat and cmd files are not always considered executable in MSYS causing which 21260 # to not find them 21261 if test "x$new_path" = x \ 21262 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21263 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21264 new_path="$path" 21265 21266 windows_path="$new_path" 21267 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21268 unix_path=`$CYGPATH -u "$windows_path"` 21269 new_path="$unix_path" 21270 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21271 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21272 new_path="$unix_path" 21273 fi 21274 21275 fi 21276 21277 if test "x$new_path" = x; then 21278 # It's still not found. Now this is an unrecoverable error. 21279 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21280 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21281 has_space=`$ECHO "$complete" | $GREP " "` 21282 if test "x$has_space" != x; then 21283 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21284 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21285 fi 21286 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21287 fi 21288 fi 21289 21290 # Now new_path has a complete unix path to the binary 21291 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 21292 # Keep paths in /bin as-is, but remove trailing .exe if any 21293 new_path="${new_path/%.exe/}" 21294 # Do not save /bin paths to all_fixpath_prefixes! 21295 else 21296 # Not in mixed or Windows style, start by that. 21297 new_path=`cmd //c echo $new_path` 21298 21299 input_path="$new_path" 21300 # Check if we need to convert this using DOS-style short mode. If the path 21301 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21302 # take no chances and rewrite it. 21303 # Note: m4 eats our [], so we need to use [ and ] instead. 21304 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 21305 if test "x$has_forbidden_chars" != x; then 21306 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21307 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21308 fi 21309 21310 # Output is in $new_path 21311 21312 windows_path="$new_path" 21313 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21314 unix_path=`$CYGPATH -u "$windows_path"` 21315 new_path="$unix_path" 21316 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21317 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21318 new_path="$unix_path" 21319 fi 21320 21321 # remove trailing .exe if any 21322 new_path="${new_path/%.exe/}" 21323 21324 # Save the first 10 bytes of this path to the storage, so fixpath can work. 21325 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21326 fi 21327 21328 else 21329 # We're on a unix platform. Hooray! :) 21330 # First separate the path from the arguments. This will split at the first 21331 # space. 21332 complete="$FOUND_MAKE" 21333 path="${complete%% *}" 21334 tmp="$complete EOL" 21335 arguments="${tmp#* }" 21336 21337 # Cannot rely on the command "which" here since it doesn't always work. 21338 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21339 if test -z "$is_absolute_path"; then 21340 # Path to executable is not absolute. Find it. 21341 IFS_save="$IFS" 21342 IFS=: 21343 for p in $PATH; do 21344 if test -f "$p/$path" && test -x "$p/$path"; then 21345 new_path="$p/$path" 21346 break 21347 fi 21348 done 21349 IFS="$IFS_save" 21350 else 21351 # This is an absolute path, we can use it without further modifications. 21352 new_path="$path" 21353 fi 21354 21355 if test "x$new_path" = x; then 21356 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21357 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21358 has_space=`$ECHO "$complete" | $GREP " "` 21359 if test "x$has_space" != x; then 21360 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21361 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21362 fi 21363 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21364 fi 21365 fi 21366 21367 # Now join together the path and the arguments once again 21368 if test "x$arguments" != xEOL; then 21369 new_complete="$new_path ${arguments% *}" 21370 else 21371 new_complete="$new_path" 21372 fi 21373 21374 if test "x$complete" != "x$new_complete"; then 21375 FOUND_MAKE="$new_complete" 21376 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 21377 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 21378 fi 21379 fi 21380 21381 fi 21382 fi 21383 fi 21384 fi 21385 21386 if test "x$FOUND_MAKE" = x; then 21387 as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make $MAKE_REQUIRED_VERSION or newer." "$LINENO" 5 21388 fi 21389 21390 fi 21391 21392 21393 MAKE=$FOUND_MAKE 21394 21395 { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5 21396 $as_echo "$as_me: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;} 21397 21398 21399 # Check if make supports the output sync option and if so, setup using it. 21400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if make --output-sync is supported" >&5 21401 $as_echo_n "checking if make --output-sync is supported... " >&6; } 21402 if $MAKE --version -O > /dev/null 2>&1; then 21403 OUTPUT_SYNC_SUPPORTED=true 21404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21405 $as_echo "yes" >&6; } 21406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for output-sync value" >&5 21407 $as_echo_n "checking for output-sync value... " >&6; } 21408 21409 # Check whether --with-output-sync was given. 21410 if test "${with_output_sync+set}" = set; then : 21411 withval=$with_output_sync; OUTPUT_SYNC=$with_output_sync 21412 fi 21413 21414 if test "x$OUTPUT_SYNC" = "x"; then 21415 OUTPUT_SYNC=none 21416 fi 21417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_SYNC" >&5 21418 $as_echo "$OUTPUT_SYNC" >&6; } 21419 if ! $MAKE --version -O$OUTPUT_SYNC > /dev/null 2>&1; then 21420 as_fn_error $? "Make did not the support the value $OUTPUT_SYNC as output sync type." "$LINENO" 5 21421 fi 21422 else 21423 OUTPUT_SYNC_SUPPORTED=false 21424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21425 $as_echo "no" >&6; } 21426 fi 21427 21428 21429 21430 21431 21432 21433 # Test if find supports -delete 21434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5 21435 $as_echo_n "checking if find supports -delete... " >&6; } 21436 FIND_DELETE="-delete" 21437 21438 DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?) 21439 21440 echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete 21441 21442 TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1` 21443 if test -f $DELETEDIR/TestIfFindSupportsDelete; then 21444 # No, it does not. 21445 $RM $DELETEDIR/TestIfFindSupportsDelete 21446 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21447 # AIX 'find' is buggy if called with '-exec {} \+' and an empty file list 21448 FIND_DELETE="-print | $XARGS $RM" 21449 else 21450 FIND_DELETE="-exec $RM \{\} \+" 21451 fi 21452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21453 $as_echo "no" >&6; } 21454 else 21455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21456 $as_echo "yes" >&6; } 21457 fi 21458 $RMDIR $DELETEDIR 21459 21460 21461 21462 # Test which kind of tar was found 21463 if test "x$($TAR --version | $GREP "GNU tar")" != "x"; then 21464 TAR_TYPE="gnu" 21465 elif test "x$($TAR --version | $GREP "bsdtar")" != "x"; then 21466 TAR_TYPE="bsd" 21467 elif test "x$($TAR -v | $GREP "bsdtar")" != "x"; then 21468 TAR_TYPE="bsd" 21469 elif test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 21470 TAR_TYPE="solaris" 21471 fi 21472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of tar was found" >&5 21473 $as_echo_n "checking what type of tar was found... " >&6; } 21474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR_TYPE" >&5 21475 $as_echo "$TAR_TYPE" >&6; } 21476 21477 TAR_CREATE_FILE_PARAM="" 21478 21479 if test "x$TAR_TYPE" = "xgnu"; then 21480 TAR_INCLUDE_PARAM="T" 21481 TAR_SUPPORTS_TRANSFORM="true" 21482 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 21483 # When using gnu tar for Solaris targets, need to use compatibility mode 21484 TAR_CREATE_EXTRA_PARAM="--format=ustar" 21485 fi 21486 else 21487 TAR_INCLUDE_PARAM="I" 21488 TAR_SUPPORTS_TRANSFORM="false" 21489 fi 21490 21491 21492 21493 21494 21495 21496 # Test that grep supports -Fx with a list of pattern which includes null pattern. 21497 # This is a problem for the grep resident on AIX. 21498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that grep ($GREP) -Fx handles empty lines in the pattern list correctly" >&5 21499 $as_echo_n "checking that grep ($GREP) -Fx handles empty lines in the pattern list correctly... " >&6; } 21500 # Multiple subsequent spaces.. 21501 STACK_SPACES='aaa bbb ccc' 21502 # ..converted to subsequent newlines, causes STACK_LIST to be a list with some empty 21503 # patterns in it. 21504 STACK_LIST=${STACK_SPACES// /$'\n'} 21505 NEEDLE_SPACES='ccc bbb aaa' 21506 NEEDLE_LIST=${NEEDLE_SPACES// /$'\n'} 21507 RESULT="$($GREP -Fvx "$STACK_LIST" <<< "$NEEDLE_LIST")" 21508 if test "x$RESULT" == "x"; then 21509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21510 $as_echo "yes" >&6; } 21511 else 21512 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21513 ADDINFO="Please make sure you use GNU grep, usually found at /opt/freeware/bin." 21514 fi 21515 as_fn_error $? "grep does not handle -Fx correctly. ${ADDINFO}" "$LINENO" 5 21516 fi 21517 21518 21519 # These tools might not be installed by default, 21520 # need hint on how to install them. 21521 21522 21523 21524 # Publish this variable in the help. 21525 21526 21527 if [ -z "${UNZIP+x}" ]; then 21528 # The variable is not set by user, try to locate tool using the code snippet 21529 for ac_prog in unzip 21530 do 21531 # Extract the first word of "$ac_prog", so it can be a program name with args. 21532 set dummy $ac_prog; ac_word=$2 21533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21534 $as_echo_n "checking for $ac_word... " >&6; } 21535 if ${ac_cv_path_UNZIP+:} false; then : 21536 $as_echo_n "(cached) " >&6 21537 else 21538 case $UNZIP in 21539 [\\/]* | ?:[\\/]*) 21540 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21541 ;; 21542 *) 21543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21544 for as_dir in $PATH 21545 do 21546 IFS=$as_save_IFS 21547 test -z "$as_dir" && as_dir=. 21548 for ac_exec_ext in '' $ac_executable_extensions; do 21549 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21550 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21552 break 2 21553 fi 21554 done 21555 done 21556 IFS=$as_save_IFS 21557 21558 ;; 21559 esac 21560 fi 21561 UNZIP=$ac_cv_path_UNZIP 21562 if test -n "$UNZIP"; then 21563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21564 $as_echo "$UNZIP" >&6; } 21565 else 21566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21567 $as_echo "no" >&6; } 21568 fi 21569 21570 21571 test -n "$UNZIP" && break 21572 done 21573 21574 else 21575 # The variable is set, but is it from the command line or the environment? 21576 21577 # Try to remove the string !UNZIP! from our list. 21578 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/} 21579 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21580 # If it failed, the variable was not from the command line. Ignore it, 21581 # but warn the user (except for BASH, which is always set by the calling BASH). 21582 if test "xUNZIP" != xBASH; then 21583 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5 21584 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;} 21585 fi 21586 # Try to locate tool using the code snippet 21587 for ac_prog in unzip 21588 do 21589 # Extract the first word of "$ac_prog", so it can be a program name with args. 21590 set dummy $ac_prog; ac_word=$2 21591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21592 $as_echo_n "checking for $ac_word... " >&6; } 21593 if ${ac_cv_path_UNZIP+:} false; then : 21594 $as_echo_n "(cached) " >&6 21595 else 21596 case $UNZIP in 21597 [\\/]* | ?:[\\/]*) 21598 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21599 ;; 21600 *) 21601 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21602 for as_dir in $PATH 21603 do 21604 IFS=$as_save_IFS 21605 test -z "$as_dir" && as_dir=. 21606 for ac_exec_ext in '' $ac_executable_extensions; do 21607 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21608 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21609 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21610 break 2 21611 fi 21612 done 21613 done 21614 IFS=$as_save_IFS 21615 21616 ;; 21617 esac 21618 fi 21619 UNZIP=$ac_cv_path_UNZIP 21620 if test -n "$UNZIP"; then 21621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21622 $as_echo "$UNZIP" >&6; } 21623 else 21624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21625 $as_echo "no" >&6; } 21626 fi 21627 21628 21629 test -n "$UNZIP" && break 21630 done 21631 21632 else 21633 # If it succeeded, then it was overridden by the user. We will use it 21634 # for the tool. 21635 21636 # First remove it from the list of overridden variables, so we can test 21637 # for unknown variables in the end. 21638 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21639 21640 # Check if we try to supply an empty value 21641 if test "x$UNZIP" = x; then 21642 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNZIP= (no value)" >&5 21643 $as_echo "$as_me: Setting user supplied tool UNZIP= (no value)" >&6;} 21644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21645 $as_echo_n "checking for UNZIP... " >&6; } 21646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21647 $as_echo "disabled" >&6; } 21648 else 21649 # Check if the provided tool contains a complete path. 21650 tool_specified="$UNZIP" 21651 tool_basename="${tool_specified##*/}" 21652 if test "x$tool_basename" = "x$tool_specified"; then 21653 # A command without a complete path is provided, search $PATH. 21654 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5 21655 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;} 21656 # Extract the first word of "$tool_basename", so it can be a program name with args. 21657 set dummy $tool_basename; ac_word=$2 21658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21659 $as_echo_n "checking for $ac_word... " >&6; } 21660 if ${ac_cv_path_UNZIP+:} false; then : 21661 $as_echo_n "(cached) " >&6 21662 else 21663 case $UNZIP in 21664 [\\/]* | ?:[\\/]*) 21665 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21666 ;; 21667 *) 21668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21669 for as_dir in $PATH 21670 do 21671 IFS=$as_save_IFS 21672 test -z "$as_dir" && as_dir=. 21673 for ac_exec_ext in '' $ac_executable_extensions; do 21674 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21675 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21676 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21677 break 2 21678 fi 21679 done 21680 done 21681 IFS=$as_save_IFS 21682 21683 ;; 21684 esac 21685 fi 21686 UNZIP=$ac_cv_path_UNZIP 21687 if test -n "$UNZIP"; then 21688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21689 $as_echo "$UNZIP" >&6; } 21690 else 21691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21692 $as_echo "no" >&6; } 21693 fi 21694 21695 21696 if test "x$UNZIP" = x; then 21697 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21698 fi 21699 else 21700 # Otherwise we believe it is a complete path. Use it as it is. 21701 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5 21702 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;} 21703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21704 $as_echo_n "checking for UNZIP... " >&6; } 21705 if test ! -x "$tool_specified"; then 21706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21707 $as_echo "not found" >&6; } 21708 as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 21709 fi 21710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21711 $as_echo "$tool_specified" >&6; } 21712 fi 21713 fi 21714 fi 21715 21716 fi 21717 21718 21719 21720 if test "x$UNZIP" = x; then 21721 as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5 21722 fi 21723 21724 21725 # Since zip uses "ZIP" as a environment variable for passing options, we need 21726 # to name our variable differently, hence ZIPEXE. 21727 21728 21729 21730 # Publish this variable in the help. 21731 21732 21733 if [ -z "${ZIPEXE+x}" ]; then 21734 # The variable is not set by user, try to locate tool using the code snippet 21735 for ac_prog in zip 21736 do 21737 # Extract the first word of "$ac_prog", so it can be a program name with args. 21738 set dummy $ac_prog; ac_word=$2 21739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21740 $as_echo_n "checking for $ac_word... " >&6; } 21741 if ${ac_cv_path_ZIPEXE+:} false; then : 21742 $as_echo_n "(cached) " >&6 21743 else 21744 case $ZIPEXE in 21745 [\\/]* | ?:[\\/]*) 21746 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21747 ;; 21748 *) 21749 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21750 for as_dir in $PATH 21751 do 21752 IFS=$as_save_IFS 21753 test -z "$as_dir" && as_dir=. 21754 for ac_exec_ext in '' $ac_executable_extensions; do 21755 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21756 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21757 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21758 break 2 21759 fi 21760 done 21761 done 21762 IFS=$as_save_IFS 21763 21764 ;; 21765 esac 21766 fi 21767 ZIPEXE=$ac_cv_path_ZIPEXE 21768 if test -n "$ZIPEXE"; then 21769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21770 $as_echo "$ZIPEXE" >&6; } 21771 else 21772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21773 $as_echo "no" >&6; } 21774 fi 21775 21776 21777 test -n "$ZIPEXE" && break 21778 done 21779 21780 else 21781 # The variable is set, but is it from the command line or the environment? 21782 21783 # Try to remove the string !ZIPEXE! from our list. 21784 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIPEXE!/} 21785 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21786 # If it failed, the variable was not from the command line. Ignore it, 21787 # but warn the user (except for BASH, which is always set by the calling BASH). 21788 if test "xZIPEXE" != xBASH; then 21789 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIPEXE from the environment. Use command line variables instead." >&5 21790 $as_echo "$as_me: WARNING: Ignoring value of ZIPEXE from the environment. Use command line variables instead." >&2;} 21791 fi 21792 # Try to locate tool using the code snippet 21793 for ac_prog in zip 21794 do 21795 # Extract the first word of "$ac_prog", so it can be a program name with args. 21796 set dummy $ac_prog; ac_word=$2 21797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21798 $as_echo_n "checking for $ac_word... " >&6; } 21799 if ${ac_cv_path_ZIPEXE+:} false; then : 21800 $as_echo_n "(cached) " >&6 21801 else 21802 case $ZIPEXE in 21803 [\\/]* | ?:[\\/]*) 21804 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21805 ;; 21806 *) 21807 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21808 for as_dir in $PATH 21809 do 21810 IFS=$as_save_IFS 21811 test -z "$as_dir" && as_dir=. 21812 for ac_exec_ext in '' $ac_executable_extensions; do 21813 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21814 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21815 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21816 break 2 21817 fi 21818 done 21819 done 21820 IFS=$as_save_IFS 21821 21822 ;; 21823 esac 21824 fi 21825 ZIPEXE=$ac_cv_path_ZIPEXE 21826 if test -n "$ZIPEXE"; then 21827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21828 $as_echo "$ZIPEXE" >&6; } 21829 else 21830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21831 $as_echo "no" >&6; } 21832 fi 21833 21834 21835 test -n "$ZIPEXE" && break 21836 done 21837 21838 else 21839 # If it succeeded, then it was overridden by the user. We will use it 21840 # for the tool. 21841 21842 # First remove it from the list of overridden variables, so we can test 21843 # for unknown variables in the end. 21844 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21845 21846 # Check if we try to supply an empty value 21847 if test "x$ZIPEXE" = x; then 21848 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ZIPEXE= (no value)" >&5 21849 $as_echo "$as_me: Setting user supplied tool ZIPEXE= (no value)" >&6;} 21850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIPEXE" >&5 21851 $as_echo_n "checking for ZIPEXE... " >&6; } 21852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21853 $as_echo "disabled" >&6; } 21854 else 21855 # Check if the provided tool contains a complete path. 21856 tool_specified="$ZIPEXE" 21857 tool_basename="${tool_specified##*/}" 21858 if test "x$tool_basename" = "x$tool_specified"; then 21859 # A command without a complete path is provided, search $PATH. 21860 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIPEXE=$tool_basename" >&5 21861 $as_echo "$as_me: Will search for user supplied tool ZIPEXE=$tool_basename" >&6;} 21862 # Extract the first word of "$tool_basename", so it can be a program name with args. 21863 set dummy $tool_basename; ac_word=$2 21864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21865 $as_echo_n "checking for $ac_word... " >&6; } 21866 if ${ac_cv_path_ZIPEXE+:} false; then : 21867 $as_echo_n "(cached) " >&6 21868 else 21869 case $ZIPEXE in 21870 [\\/]* | ?:[\\/]*) 21871 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21872 ;; 21873 *) 21874 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21875 for as_dir in $PATH 21876 do 21877 IFS=$as_save_IFS 21878 test -z "$as_dir" && as_dir=. 21879 for ac_exec_ext in '' $ac_executable_extensions; do 21880 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21881 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21882 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21883 break 2 21884 fi 21885 done 21886 done 21887 IFS=$as_save_IFS 21888 21889 ;; 21890 esac 21891 fi 21892 ZIPEXE=$ac_cv_path_ZIPEXE 21893 if test -n "$ZIPEXE"; then 21894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21895 $as_echo "$ZIPEXE" >&6; } 21896 else 21897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21898 $as_echo "no" >&6; } 21899 fi 21900 21901 21902 if test "x$ZIPEXE" = x; then 21903 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21904 fi 21905 else 21906 # Otherwise we believe it is a complete path. Use it as it is. 21907 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIPEXE=$tool_specified" >&5 21908 $as_echo "$as_me: Will use user supplied tool ZIPEXE=$tool_specified" >&6;} 21909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIPEXE" >&5 21910 $as_echo_n "checking for ZIPEXE... " >&6; } 21911 if test ! -x "$tool_specified"; then 21912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21913 $as_echo "not found" >&6; } 21914 as_fn_error $? "User supplied tool ZIPEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 21915 fi 21916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21917 $as_echo "$tool_specified" >&6; } 21918 fi 21919 fi 21920 fi 21921 21922 fi 21923 21924 21925 21926 if test "x$ZIPEXE" = x; then 21927 as_fn_error $? "Could not find required tool for ZIPEXE" "$LINENO" 5 21928 fi 21929 21930 21931 21932 # Non-required basic tools 21933 21934 21935 21936 # Publish this variable in the help. 21937 21938 21939 if [ -z "${LDD+x}" ]; then 21940 # The variable is not set by user, try to locate tool using the code snippet 21941 for ac_prog in ldd 21942 do 21943 # Extract the first word of "$ac_prog", so it can be a program name with args. 21944 set dummy $ac_prog; ac_word=$2 21945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21946 $as_echo_n "checking for $ac_word... " >&6; } 21947 if ${ac_cv_path_LDD+:} false; then : 21948 $as_echo_n "(cached) " >&6 21949 else 21950 case $LDD in 21951 [\\/]* | ?:[\\/]*) 21952 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21953 ;; 21954 *) 21955 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21956 for as_dir in $PATH 21957 do 21958 IFS=$as_save_IFS 21959 test -z "$as_dir" && as_dir=. 21960 for ac_exec_ext in '' $ac_executable_extensions; do 21961 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21962 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21963 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21964 break 2 21965 fi 21966 done 21967 done 21968 IFS=$as_save_IFS 21969 21970 ;; 21971 esac 21972 fi 21973 LDD=$ac_cv_path_LDD 21974 if test -n "$LDD"; then 21975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21976 $as_echo "$LDD" >&6; } 21977 else 21978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21979 $as_echo "no" >&6; } 21980 fi 21981 21982 21983 test -n "$LDD" && break 21984 done 21985 21986 else 21987 # The variable is set, but is it from the command line or the environment? 21988 21989 # Try to remove the string !LDD! from our list. 21990 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/} 21991 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21992 # If it failed, the variable was not from the command line. Ignore it, 21993 # but warn the user (except for BASH, which is always set by the calling BASH). 21994 if test "xLDD" != xBASH; then 21995 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5 21996 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;} 21997 fi 21998 # Try to locate tool using the code snippet 21999 for ac_prog in ldd 22000 do 22001 # Extract the first word of "$ac_prog", so it can be a program name with args. 22002 set dummy $ac_prog; ac_word=$2 22003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22004 $as_echo_n "checking for $ac_word... " >&6; } 22005 if ${ac_cv_path_LDD+:} false; then : 22006 $as_echo_n "(cached) " >&6 22007 else 22008 case $LDD in 22009 [\\/]* | ?:[\\/]*) 22010 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 22011 ;; 22012 *) 22013 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22014 for as_dir in $PATH 22015 do 22016 IFS=$as_save_IFS 22017 test -z "$as_dir" && as_dir=. 22018 for ac_exec_ext in '' $ac_executable_extensions; do 22019 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22020 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 22021 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22022 break 2 22023 fi 22024 done 22025 done 22026 IFS=$as_save_IFS 22027 22028 ;; 22029 esac 22030 fi 22031 LDD=$ac_cv_path_LDD 22032 if test -n "$LDD"; then 22033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 22034 $as_echo "$LDD" >&6; } 22035 else 22036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22037 $as_echo "no" >&6; } 22038 fi 22039 22040 22041 test -n "$LDD" && break 22042 done 22043 22044 else 22045 # If it succeeded, then it was overridden by the user. We will use it 22046 # for the tool. 22047 22048 # First remove it from the list of overridden variables, so we can test 22049 # for unknown variables in the end. 22050 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22051 22052 # Check if we try to supply an empty value 22053 if test "x$LDD" = x; then 22054 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LDD= (no value)" >&5 22055 $as_echo "$as_me: Setting user supplied tool LDD= (no value)" >&6;} 22056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 22057 $as_echo_n "checking for LDD... " >&6; } 22058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22059 $as_echo "disabled" >&6; } 22060 else 22061 # Check if the provided tool contains a complete path. 22062 tool_specified="$LDD" 22063 tool_basename="${tool_specified##*/}" 22064 if test "x$tool_basename" = "x$tool_specified"; then 22065 # A command without a complete path is provided, search $PATH. 22066 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5 22067 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;} 22068 # Extract the first word of "$tool_basename", so it can be a program name with args. 22069 set dummy $tool_basename; ac_word=$2 22070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22071 $as_echo_n "checking for $ac_word... " >&6; } 22072 if ${ac_cv_path_LDD+:} false; then : 22073 $as_echo_n "(cached) " >&6 22074 else 22075 case $LDD in 22076 [\\/]* | ?:[\\/]*) 22077 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 22078 ;; 22079 *) 22080 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22081 for as_dir in $PATH 22082 do 22083 IFS=$as_save_IFS 22084 test -z "$as_dir" && as_dir=. 22085 for ac_exec_ext in '' $ac_executable_extensions; do 22086 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22087 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 22088 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22089 break 2 22090 fi 22091 done 22092 done 22093 IFS=$as_save_IFS 22094 22095 ;; 22096 esac 22097 fi 22098 LDD=$ac_cv_path_LDD 22099 if test -n "$LDD"; then 22100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 22101 $as_echo "$LDD" >&6; } 22102 else 22103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22104 $as_echo "no" >&6; } 22105 fi 22106 22107 22108 if test "x$LDD" = x; then 22109 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22110 fi 22111 else 22112 # Otherwise we believe it is a complete path. Use it as it is. 22113 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5 22114 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;} 22115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 22116 $as_echo_n "checking for LDD... " >&6; } 22117 if test ! -x "$tool_specified"; then 22118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22119 $as_echo "not found" >&6; } 22120 as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5 22121 fi 22122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22123 $as_echo "$tool_specified" >&6; } 22124 fi 22125 fi 22126 fi 22127 22128 fi 22129 22130 22131 if test "x$LDD" = "x"; then 22132 # List shared lib dependencies is used for 22133 # debug output and checking for forbidden dependencies. 22134 # We can build without it. 22135 LDD="true" 22136 fi 22137 22138 22139 # Publish this variable in the help. 22140 22141 22142 if [ -z "${OTOOL+x}" ]; then 22143 # The variable is not set by user, try to locate tool using the code snippet 22144 for ac_prog in otool 22145 do 22146 # Extract the first word of "$ac_prog", so it can be a program name with args. 22147 set dummy $ac_prog; ac_word=$2 22148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22149 $as_echo_n "checking for $ac_word... " >&6; } 22150 if ${ac_cv_path_OTOOL+:} false; then : 22151 $as_echo_n "(cached) " >&6 22152 else 22153 case $OTOOL in 22154 [\\/]* | ?:[\\/]*) 22155 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 22156 ;; 22157 *) 22158 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22159 for as_dir in $PATH 22160 do 22161 IFS=$as_save_IFS 22162 test -z "$as_dir" && as_dir=. 22163 for ac_exec_ext in '' $ac_executable_extensions; do 22164 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22165 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 22166 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22167 break 2 22168 fi 22169 done 22170 done 22171 IFS=$as_save_IFS 22172 22173 ;; 22174 esac 22175 fi 22176 OTOOL=$ac_cv_path_OTOOL 22177 if test -n "$OTOOL"; then 22178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 22179 $as_echo "$OTOOL" >&6; } 22180 else 22181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22182 $as_echo "no" >&6; } 22183 fi 22184 22185 22186 test -n "$OTOOL" && break 22187 done 22188 22189 else 22190 # The variable is set, but is it from the command line or the environment? 22191 22192 # Try to remove the string !OTOOL! from our list. 22193 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/} 22194 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22195 # If it failed, the variable was not from the command line. Ignore it, 22196 # but warn the user (except for BASH, which is always set by the calling BASH). 22197 if test "xOTOOL" != xBASH; then 22198 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5 22199 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;} 22200 fi 22201 # Try to locate tool using the code snippet 22202 for ac_prog in otool 22203 do 22204 # Extract the first word of "$ac_prog", so it can be a program name with args. 22205 set dummy $ac_prog; ac_word=$2 22206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22207 $as_echo_n "checking for $ac_word... " >&6; } 22208 if ${ac_cv_path_OTOOL+:} false; then : 22209 $as_echo_n "(cached) " >&6 22210 else 22211 case $OTOOL in 22212 [\\/]* | ?:[\\/]*) 22213 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 22214 ;; 22215 *) 22216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22217 for as_dir in $PATH 22218 do 22219 IFS=$as_save_IFS 22220 test -z "$as_dir" && as_dir=. 22221 for ac_exec_ext in '' $ac_executable_extensions; do 22222 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22223 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 22224 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22225 break 2 22226 fi 22227 done 22228 done 22229 IFS=$as_save_IFS 22230 22231 ;; 22232 esac 22233 fi 22234 OTOOL=$ac_cv_path_OTOOL 22235 if test -n "$OTOOL"; then 22236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 22237 $as_echo "$OTOOL" >&6; } 22238 else 22239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22240 $as_echo "no" >&6; } 22241 fi 22242 22243 22244 test -n "$OTOOL" && break 22245 done 22246 22247 else 22248 # If it succeeded, then it was overridden by the user. We will use it 22249 # for the tool. 22250 22251 # First remove it from the list of overridden variables, so we can test 22252 # for unknown variables in the end. 22253 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22254 22255 # Check if we try to supply an empty value 22256 if test "x$OTOOL" = x; then 22257 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OTOOL= (no value)" >&5 22258 $as_echo "$as_me: Setting user supplied tool OTOOL= (no value)" >&6;} 22259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 22260 $as_echo_n "checking for OTOOL... " >&6; } 22261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22262 $as_echo "disabled" >&6; } 22263 else 22264 # Check if the provided tool contains a complete path. 22265 tool_specified="$OTOOL" 22266 tool_basename="${tool_specified##*/}" 22267 if test "x$tool_basename" = "x$tool_specified"; then 22268 # A command without a complete path is provided, search $PATH. 22269 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5 22270 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;} 22271 # Extract the first word of "$tool_basename", so it can be a program name with args. 22272 set dummy $tool_basename; ac_word=$2 22273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22274 $as_echo_n "checking for $ac_word... " >&6; } 22275 if ${ac_cv_path_OTOOL+:} false; then : 22276 $as_echo_n "(cached) " >&6 22277 else 22278 case $OTOOL in 22279 [\\/]* | ?:[\\/]*) 22280 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 22281 ;; 22282 *) 22283 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22284 for as_dir in $PATH 22285 do 22286 IFS=$as_save_IFS 22287 test -z "$as_dir" && as_dir=. 22288 for ac_exec_ext in '' $ac_executable_extensions; do 22289 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22290 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 22291 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22292 break 2 22293 fi 22294 done 22295 done 22296 IFS=$as_save_IFS 22297 22298 ;; 22299 esac 22300 fi 22301 OTOOL=$ac_cv_path_OTOOL 22302 if test -n "$OTOOL"; then 22303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 22304 $as_echo "$OTOOL" >&6; } 22305 else 22306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22307 $as_echo "no" >&6; } 22308 fi 22309 22310 22311 if test "x$OTOOL" = x; then 22312 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22313 fi 22314 else 22315 # Otherwise we believe it is a complete path. Use it as it is. 22316 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5 22317 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;} 22318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 22319 $as_echo_n "checking for OTOOL... " >&6; } 22320 if test ! -x "$tool_specified"; then 22321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22322 $as_echo "not found" >&6; } 22323 as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5 22324 fi 22325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22326 $as_echo "$tool_specified" >&6; } 22327 fi 22328 fi 22329 fi 22330 22331 fi 22332 22333 22334 if test "x$OTOOL" = "x"; then 22335 OTOOL="true" 22336 fi 22337 22338 22339 # Publish this variable in the help. 22340 22341 22342 if [ -z "${READELF+x}" ]; then 22343 # The variable is not set by user, try to locate tool using the code snippet 22344 for ac_prog in greadelf readelf 22345 do 22346 # Extract the first word of "$ac_prog", so it can be a program name with args. 22347 set dummy $ac_prog; ac_word=$2 22348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22349 $as_echo_n "checking for $ac_word... " >&6; } 22350 if ${ac_cv_path_READELF+:} false; then : 22351 $as_echo_n "(cached) " >&6 22352 else 22353 case $READELF in 22354 [\\/]* | ?:[\\/]*) 22355 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22356 ;; 22357 *) 22358 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22359 for as_dir in $PATH 22360 do 22361 IFS=$as_save_IFS 22362 test -z "$as_dir" && as_dir=. 22363 for ac_exec_ext in '' $ac_executable_extensions; do 22364 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22365 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22366 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22367 break 2 22368 fi 22369 done 22370 done 22371 IFS=$as_save_IFS 22372 22373 ;; 22374 esac 22375 fi 22376 READELF=$ac_cv_path_READELF 22377 if test -n "$READELF"; then 22378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22379 $as_echo "$READELF" >&6; } 22380 else 22381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22382 $as_echo "no" >&6; } 22383 fi 22384 22385 22386 test -n "$READELF" && break 22387 done 22388 22389 else 22390 # The variable is set, but is it from the command line or the environment? 22391 22392 # Try to remove the string !READELF! from our list. 22393 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/} 22394 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22395 # If it failed, the variable was not from the command line. Ignore it, 22396 # but warn the user (except for BASH, which is always set by the calling BASH). 22397 if test "xREADELF" != xBASH; then 22398 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5 22399 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;} 22400 fi 22401 # Try to locate tool using the code snippet 22402 for ac_prog in greadelf readelf 22403 do 22404 # Extract the first word of "$ac_prog", so it can be a program name with args. 22405 set dummy $ac_prog; ac_word=$2 22406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22407 $as_echo_n "checking for $ac_word... " >&6; } 22408 if ${ac_cv_path_READELF+:} false; then : 22409 $as_echo_n "(cached) " >&6 22410 else 22411 case $READELF in 22412 [\\/]* | ?:[\\/]*) 22413 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22414 ;; 22415 *) 22416 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22417 for as_dir in $PATH 22418 do 22419 IFS=$as_save_IFS 22420 test -z "$as_dir" && as_dir=. 22421 for ac_exec_ext in '' $ac_executable_extensions; do 22422 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22423 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22424 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22425 break 2 22426 fi 22427 done 22428 done 22429 IFS=$as_save_IFS 22430 22431 ;; 22432 esac 22433 fi 22434 READELF=$ac_cv_path_READELF 22435 if test -n "$READELF"; then 22436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22437 $as_echo "$READELF" >&6; } 22438 else 22439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22440 $as_echo "no" >&6; } 22441 fi 22442 22443 22444 test -n "$READELF" && break 22445 done 22446 22447 else 22448 # If it succeeded, then it was overridden by the user. We will use it 22449 # for the tool. 22450 22451 # First remove it from the list of overridden variables, so we can test 22452 # for unknown variables in the end. 22453 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22454 22455 # Check if we try to supply an empty value 22456 if test "x$READELF" = x; then 22457 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READELF= (no value)" >&5 22458 $as_echo "$as_me: Setting user supplied tool READELF= (no value)" >&6;} 22459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22460 $as_echo_n "checking for READELF... " >&6; } 22461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22462 $as_echo "disabled" >&6; } 22463 else 22464 # Check if the provided tool contains a complete path. 22465 tool_specified="$READELF" 22466 tool_basename="${tool_specified##*/}" 22467 if test "x$tool_basename" = "x$tool_specified"; then 22468 # A command without a complete path is provided, search $PATH. 22469 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5 22470 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;} 22471 # Extract the first word of "$tool_basename", so it can be a program name with args. 22472 set dummy $tool_basename; ac_word=$2 22473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22474 $as_echo_n "checking for $ac_word... " >&6; } 22475 if ${ac_cv_path_READELF+:} false; then : 22476 $as_echo_n "(cached) " >&6 22477 else 22478 case $READELF in 22479 [\\/]* | ?:[\\/]*) 22480 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22481 ;; 22482 *) 22483 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22484 for as_dir in $PATH 22485 do 22486 IFS=$as_save_IFS 22487 test -z "$as_dir" && as_dir=. 22488 for ac_exec_ext in '' $ac_executable_extensions; do 22489 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22490 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22491 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22492 break 2 22493 fi 22494 done 22495 done 22496 IFS=$as_save_IFS 22497 22498 ;; 22499 esac 22500 fi 22501 READELF=$ac_cv_path_READELF 22502 if test -n "$READELF"; then 22503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22504 $as_echo "$READELF" >&6; } 22505 else 22506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22507 $as_echo "no" >&6; } 22508 fi 22509 22510 22511 if test "x$READELF" = x; then 22512 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22513 fi 22514 else 22515 # Otherwise we believe it is a complete path. Use it as it is. 22516 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5 22517 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;} 22518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22519 $as_echo_n "checking for READELF... " >&6; } 22520 if test ! -x "$tool_specified"; then 22521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22522 $as_echo "not found" >&6; } 22523 as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5 22524 fi 22525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22526 $as_echo "$tool_specified" >&6; } 22527 fi 22528 fi 22529 fi 22530 22531 fi 22532 22533 22534 22535 22536 # Publish this variable in the help. 22537 22538 22539 if [ -z "${DOT+x}" ]; then 22540 # The variable is not set by user, try to locate tool using the code snippet 22541 for ac_prog in dot 22542 do 22543 # Extract the first word of "$ac_prog", so it can be a program name with args. 22544 set dummy $ac_prog; ac_word=$2 22545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22546 $as_echo_n "checking for $ac_word... " >&6; } 22547 if ${ac_cv_path_DOT+:} false; then : 22548 $as_echo_n "(cached) " >&6 22549 else 22550 case $DOT in 22551 [\\/]* | ?:[\\/]*) 22552 ac_cv_path_DOT="$DOT" # Let the user override the test with a path. 22553 ;; 22554 *) 22555 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22556 for as_dir in $PATH 22557 do 22558 IFS=$as_save_IFS 22559 test -z "$as_dir" && as_dir=. 22560 for ac_exec_ext in '' $ac_executable_extensions; do 22561 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22562 ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" 22563 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22564 break 2 22565 fi 22566 done 22567 done 22568 IFS=$as_save_IFS 22569 22570 ;; 22571 esac 22572 fi 22573 DOT=$ac_cv_path_DOT 22574 if test -n "$DOT"; then 22575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 22576 $as_echo "$DOT" >&6; } 22577 else 22578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22579 $as_echo "no" >&6; } 22580 fi 22581 22582 22583 test -n "$DOT" && break 22584 done 22585 22586 else 22587 # The variable is set, but is it from the command line or the environment? 22588 22589 # Try to remove the string !DOT! from our list. 22590 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DOT!/} 22591 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22592 # If it failed, the variable was not from the command line. Ignore it, 22593 # but warn the user (except for BASH, which is always set by the calling BASH). 22594 if test "xDOT" != xBASH; then 22595 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DOT from the environment. Use command line variables instead." >&5 22596 $as_echo "$as_me: WARNING: Ignoring value of DOT from the environment. Use command line variables instead." >&2;} 22597 fi 22598 # Try to locate tool using the code snippet 22599 for ac_prog in dot 22600 do 22601 # Extract the first word of "$ac_prog", so it can be a program name with args. 22602 set dummy $ac_prog; ac_word=$2 22603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22604 $as_echo_n "checking for $ac_word... " >&6; } 22605 if ${ac_cv_path_DOT+:} false; then : 22606 $as_echo_n "(cached) " >&6 22607 else 22608 case $DOT in 22609 [\\/]* | ?:[\\/]*) 22610 ac_cv_path_DOT="$DOT" # Let the user override the test with a path. 22611 ;; 22612 *) 22613 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22614 for as_dir in $PATH 22615 do 22616 IFS=$as_save_IFS 22617 test -z "$as_dir" && as_dir=. 22618 for ac_exec_ext in '' $ac_executable_extensions; do 22619 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22620 ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" 22621 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22622 break 2 22623 fi 22624 done 22625 done 22626 IFS=$as_save_IFS 22627 22628 ;; 22629 esac 22630 fi 22631 DOT=$ac_cv_path_DOT 22632 if test -n "$DOT"; then 22633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 22634 $as_echo "$DOT" >&6; } 22635 else 22636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22637 $as_echo "no" >&6; } 22638 fi 22639 22640 22641 test -n "$DOT" && break 22642 done 22643 22644 else 22645 # If it succeeded, then it was overridden by the user. We will use it 22646 # for the tool. 22647 22648 # First remove it from the list of overridden variables, so we can test 22649 # for unknown variables in the end. 22650 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22651 22652 # Check if we try to supply an empty value 22653 if test "x$DOT" = x; then 22654 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DOT= (no value)" >&5 22655 $as_echo "$as_me: Setting user supplied tool DOT= (no value)" >&6;} 22656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DOT" >&5 22657 $as_echo_n "checking for DOT... " >&6; } 22658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22659 $as_echo "disabled" >&6; } 22660 else 22661 # Check if the provided tool contains a complete path. 22662 tool_specified="$DOT" 22663 tool_basename="${tool_specified##*/}" 22664 if test "x$tool_basename" = "x$tool_specified"; then 22665 # A command without a complete path is provided, search $PATH. 22666 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DOT=$tool_basename" >&5 22667 $as_echo "$as_me: Will search for user supplied tool DOT=$tool_basename" >&6;} 22668 # Extract the first word of "$tool_basename", so it can be a program name with args. 22669 set dummy $tool_basename; ac_word=$2 22670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22671 $as_echo_n "checking for $ac_word... " >&6; } 22672 if ${ac_cv_path_DOT+:} false; then : 22673 $as_echo_n "(cached) " >&6 22674 else 22675 case $DOT in 22676 [\\/]* | ?:[\\/]*) 22677 ac_cv_path_DOT="$DOT" # Let the user override the test with a path. 22678 ;; 22679 *) 22680 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22681 for as_dir in $PATH 22682 do 22683 IFS=$as_save_IFS 22684 test -z "$as_dir" && as_dir=. 22685 for ac_exec_ext in '' $ac_executable_extensions; do 22686 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22687 ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" 22688 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22689 break 2 22690 fi 22691 done 22692 done 22693 IFS=$as_save_IFS 22694 22695 ;; 22696 esac 22697 fi 22698 DOT=$ac_cv_path_DOT 22699 if test -n "$DOT"; then 22700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 22701 $as_echo "$DOT" >&6; } 22702 else 22703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22704 $as_echo "no" >&6; } 22705 fi 22706 22707 22708 if test "x$DOT" = x; then 22709 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22710 fi 22711 else 22712 # Otherwise we believe it is a complete path. Use it as it is. 22713 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DOT=$tool_specified" >&5 22714 $as_echo "$as_me: Will use user supplied tool DOT=$tool_specified" >&6;} 22715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DOT" >&5 22716 $as_echo_n "checking for DOT... " >&6; } 22717 if test ! -x "$tool_specified"; then 22718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22719 $as_echo "not found" >&6; } 22720 as_fn_error $? "User supplied tool DOT=$tool_specified does not exist or is not executable" "$LINENO" 5 22721 fi 22722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22723 $as_echo "$tool_specified" >&6; } 22724 fi 22725 fi 22726 fi 22727 22728 fi 22729 22730 22731 22732 22733 # Publish this variable in the help. 22734 22735 22736 if [ -z "${HG+x}" ]; then 22737 # The variable is not set by user, try to locate tool using the code snippet 22738 for ac_prog in hg 22739 do 22740 # Extract the first word of "$ac_prog", so it can be a program name with args. 22741 set dummy $ac_prog; ac_word=$2 22742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22743 $as_echo_n "checking for $ac_word... " >&6; } 22744 if ${ac_cv_path_HG+:} false; then : 22745 $as_echo_n "(cached) " >&6 22746 else 22747 case $HG in 22748 [\\/]* | ?:[\\/]*) 22749 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22750 ;; 22751 *) 22752 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22753 for as_dir in $PATH 22754 do 22755 IFS=$as_save_IFS 22756 test -z "$as_dir" && as_dir=. 22757 for ac_exec_ext in '' $ac_executable_extensions; do 22758 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22759 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22760 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22761 break 2 22762 fi 22763 done 22764 done 22765 IFS=$as_save_IFS 22766 22767 ;; 22768 esac 22769 fi 22770 HG=$ac_cv_path_HG 22771 if test -n "$HG"; then 22772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22773 $as_echo "$HG" >&6; } 22774 else 22775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22776 $as_echo "no" >&6; } 22777 fi 22778 22779 22780 test -n "$HG" && break 22781 done 22782 22783 else 22784 # The variable is set, but is it from the command line or the environment? 22785 22786 # Try to remove the string !HG! from our list. 22787 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/} 22788 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22789 # If it failed, the variable was not from the command line. Ignore it, 22790 # but warn the user (except for BASH, which is always set by the calling BASH). 22791 if test "xHG" != xBASH; then 22792 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5 22793 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;} 22794 fi 22795 # Try to locate tool using the code snippet 22796 for ac_prog in hg 22797 do 22798 # Extract the first word of "$ac_prog", so it can be a program name with args. 22799 set dummy $ac_prog; ac_word=$2 22800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22801 $as_echo_n "checking for $ac_word... " >&6; } 22802 if ${ac_cv_path_HG+:} false; then : 22803 $as_echo_n "(cached) " >&6 22804 else 22805 case $HG in 22806 [\\/]* | ?:[\\/]*) 22807 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22808 ;; 22809 *) 22810 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22811 for as_dir in $PATH 22812 do 22813 IFS=$as_save_IFS 22814 test -z "$as_dir" && as_dir=. 22815 for ac_exec_ext in '' $ac_executable_extensions; do 22816 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22817 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22818 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22819 break 2 22820 fi 22821 done 22822 done 22823 IFS=$as_save_IFS 22824 22825 ;; 22826 esac 22827 fi 22828 HG=$ac_cv_path_HG 22829 if test -n "$HG"; then 22830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22831 $as_echo "$HG" >&6; } 22832 else 22833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22834 $as_echo "no" >&6; } 22835 fi 22836 22837 22838 test -n "$HG" && break 22839 done 22840 22841 else 22842 # If it succeeded, then it was overridden by the user. We will use it 22843 # for the tool. 22844 22845 # First remove it from the list of overridden variables, so we can test 22846 # for unknown variables in the end. 22847 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22848 22849 # Check if we try to supply an empty value 22850 if test "x$HG" = x; then 22851 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HG= (no value)" >&5 22852 $as_echo "$as_me: Setting user supplied tool HG= (no value)" >&6;} 22853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22854 $as_echo_n "checking for HG... " >&6; } 22855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22856 $as_echo "disabled" >&6; } 22857 else 22858 # Check if the provided tool contains a complete path. 22859 tool_specified="$HG" 22860 tool_basename="${tool_specified##*/}" 22861 if test "x$tool_basename" = "x$tool_specified"; then 22862 # A command without a complete path is provided, search $PATH. 22863 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5 22864 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;} 22865 # Extract the first word of "$tool_basename", so it can be a program name with args. 22866 set dummy $tool_basename; ac_word=$2 22867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22868 $as_echo_n "checking for $ac_word... " >&6; } 22869 if ${ac_cv_path_HG+:} false; then : 22870 $as_echo_n "(cached) " >&6 22871 else 22872 case $HG in 22873 [\\/]* | ?:[\\/]*) 22874 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22875 ;; 22876 *) 22877 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22878 for as_dir in $PATH 22879 do 22880 IFS=$as_save_IFS 22881 test -z "$as_dir" && as_dir=. 22882 for ac_exec_ext in '' $ac_executable_extensions; do 22883 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22884 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22885 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22886 break 2 22887 fi 22888 done 22889 done 22890 IFS=$as_save_IFS 22891 22892 ;; 22893 esac 22894 fi 22895 HG=$ac_cv_path_HG 22896 if test -n "$HG"; then 22897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22898 $as_echo "$HG" >&6; } 22899 else 22900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22901 $as_echo "no" >&6; } 22902 fi 22903 22904 22905 if test "x$HG" = x; then 22906 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22907 fi 22908 else 22909 # Otherwise we believe it is a complete path. Use it as it is. 22910 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5 22911 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;} 22912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22913 $as_echo_n "checking for HG... " >&6; } 22914 if test ! -x "$tool_specified"; then 22915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22916 $as_echo "not found" >&6; } 22917 as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5 22918 fi 22919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22920 $as_echo "$tool_specified" >&6; } 22921 fi 22922 fi 22923 fi 22924 22925 fi 22926 22927 22928 22929 22930 # Publish this variable in the help. 22931 22932 22933 if [ -z "${STAT+x}" ]; then 22934 # The variable is not set by user, try to locate tool using the code snippet 22935 for ac_prog in stat 22936 do 22937 # Extract the first word of "$ac_prog", so it can be a program name with args. 22938 set dummy $ac_prog; ac_word=$2 22939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22940 $as_echo_n "checking for $ac_word... " >&6; } 22941 if ${ac_cv_path_STAT+:} false; then : 22942 $as_echo_n "(cached) " >&6 22943 else 22944 case $STAT in 22945 [\\/]* | ?:[\\/]*) 22946 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22947 ;; 22948 *) 22949 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22950 for as_dir in $PATH 22951 do 22952 IFS=$as_save_IFS 22953 test -z "$as_dir" && as_dir=. 22954 for ac_exec_ext in '' $ac_executable_extensions; do 22955 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22956 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22957 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22958 break 2 22959 fi 22960 done 22961 done 22962 IFS=$as_save_IFS 22963 22964 ;; 22965 esac 22966 fi 22967 STAT=$ac_cv_path_STAT 22968 if test -n "$STAT"; then 22969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22970 $as_echo "$STAT" >&6; } 22971 else 22972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22973 $as_echo "no" >&6; } 22974 fi 22975 22976 22977 test -n "$STAT" && break 22978 done 22979 22980 else 22981 # The variable is set, but is it from the command line or the environment? 22982 22983 # Try to remove the string !STAT! from our list. 22984 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/} 22985 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22986 # If it failed, the variable was not from the command line. Ignore it, 22987 # but warn the user (except for BASH, which is always set by the calling BASH). 22988 if test "xSTAT" != xBASH; then 22989 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5 22990 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;} 22991 fi 22992 # Try to locate tool using the code snippet 22993 for ac_prog in stat 22994 do 22995 # Extract the first word of "$ac_prog", so it can be a program name with args. 22996 set dummy $ac_prog; ac_word=$2 22997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22998 $as_echo_n "checking for $ac_word... " >&6; } 22999 if ${ac_cv_path_STAT+:} false; then : 23000 $as_echo_n "(cached) " >&6 23001 else 23002 case $STAT in 23003 [\\/]* | ?:[\\/]*) 23004 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 23005 ;; 23006 *) 23007 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23008 for as_dir in $PATH 23009 do 23010 IFS=$as_save_IFS 23011 test -z "$as_dir" && as_dir=. 23012 for ac_exec_ext in '' $ac_executable_extensions; do 23013 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23014 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 23015 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23016 break 2 23017 fi 23018 done 23019 done 23020 IFS=$as_save_IFS 23021 23022 ;; 23023 esac 23024 fi 23025 STAT=$ac_cv_path_STAT 23026 if test -n "$STAT"; then 23027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 23028 $as_echo "$STAT" >&6; } 23029 else 23030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23031 $as_echo "no" >&6; } 23032 fi 23033 23034 23035 test -n "$STAT" && break 23036 done 23037 23038 else 23039 # If it succeeded, then it was overridden by the user. We will use it 23040 # for the tool. 23041 23042 # First remove it from the list of overridden variables, so we can test 23043 # for unknown variables in the end. 23044 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23045 23046 # Check if we try to supply an empty value 23047 if test "x$STAT" = x; then 23048 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STAT= (no value)" >&5 23049 $as_echo "$as_me: Setting user supplied tool STAT= (no value)" >&6;} 23050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 23051 $as_echo_n "checking for STAT... " >&6; } 23052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23053 $as_echo "disabled" >&6; } 23054 else 23055 # Check if the provided tool contains a complete path. 23056 tool_specified="$STAT" 23057 tool_basename="${tool_specified##*/}" 23058 if test "x$tool_basename" = "x$tool_specified"; then 23059 # A command without a complete path is provided, search $PATH. 23060 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5 23061 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;} 23062 # Extract the first word of "$tool_basename", so it can be a program name with args. 23063 set dummy $tool_basename; ac_word=$2 23064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23065 $as_echo_n "checking for $ac_word... " >&6; } 23066 if ${ac_cv_path_STAT+:} false; then : 23067 $as_echo_n "(cached) " >&6 23068 else 23069 case $STAT in 23070 [\\/]* | ?:[\\/]*) 23071 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 23072 ;; 23073 *) 23074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23075 for as_dir in $PATH 23076 do 23077 IFS=$as_save_IFS 23078 test -z "$as_dir" && as_dir=. 23079 for ac_exec_ext in '' $ac_executable_extensions; do 23080 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23081 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 23082 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23083 break 2 23084 fi 23085 done 23086 done 23087 IFS=$as_save_IFS 23088 23089 ;; 23090 esac 23091 fi 23092 STAT=$ac_cv_path_STAT 23093 if test -n "$STAT"; then 23094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 23095 $as_echo "$STAT" >&6; } 23096 else 23097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23098 $as_echo "no" >&6; } 23099 fi 23100 23101 23102 if test "x$STAT" = x; then 23103 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23104 fi 23105 else 23106 # Otherwise we believe it is a complete path. Use it as it is. 23107 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5 23108 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;} 23109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 23110 $as_echo_n "checking for STAT... " >&6; } 23111 if test ! -x "$tool_specified"; then 23112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23113 $as_echo "not found" >&6; } 23114 as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5 23115 fi 23116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23117 $as_echo "$tool_specified" >&6; } 23118 fi 23119 fi 23120 fi 23121 23122 fi 23123 23124 23125 23126 23127 # Publish this variable in the help. 23128 23129 23130 if [ -z "${TIME+x}" ]; then 23131 # The variable is not set by user, try to locate tool using the code snippet 23132 for ac_prog in time 23133 do 23134 # Extract the first word of "$ac_prog", so it can be a program name with args. 23135 set dummy $ac_prog; ac_word=$2 23136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23137 $as_echo_n "checking for $ac_word... " >&6; } 23138 if ${ac_cv_path_TIME+:} false; then : 23139 $as_echo_n "(cached) " >&6 23140 else 23141 case $TIME in 23142 [\\/]* | ?:[\\/]*) 23143 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 23144 ;; 23145 *) 23146 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23147 for as_dir in $PATH 23148 do 23149 IFS=$as_save_IFS 23150 test -z "$as_dir" && as_dir=. 23151 for ac_exec_ext in '' $ac_executable_extensions; do 23152 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23153 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 23154 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23155 break 2 23156 fi 23157 done 23158 done 23159 IFS=$as_save_IFS 23160 23161 ;; 23162 esac 23163 fi 23164 TIME=$ac_cv_path_TIME 23165 if test -n "$TIME"; then 23166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 23167 $as_echo "$TIME" >&6; } 23168 else 23169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23170 $as_echo "no" >&6; } 23171 fi 23172 23173 23174 test -n "$TIME" && break 23175 done 23176 23177 else 23178 # The variable is set, but is it from the command line or the environment? 23179 23180 # Try to remove the string !TIME! from our list. 23181 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/} 23182 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23183 # If it failed, the variable was not from the command line. Ignore it, 23184 # but warn the user (except for BASH, which is always set by the calling BASH). 23185 if test "xTIME" != xBASH; then 23186 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5 23187 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;} 23188 fi 23189 # Try to locate tool using the code snippet 23190 for ac_prog in time 23191 do 23192 # Extract the first word of "$ac_prog", so it can be a program name with args. 23193 set dummy $ac_prog; ac_word=$2 23194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23195 $as_echo_n "checking for $ac_word... " >&6; } 23196 if ${ac_cv_path_TIME+:} false; then : 23197 $as_echo_n "(cached) " >&6 23198 else 23199 case $TIME in 23200 [\\/]* | ?:[\\/]*) 23201 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 23202 ;; 23203 *) 23204 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23205 for as_dir in $PATH 23206 do 23207 IFS=$as_save_IFS 23208 test -z "$as_dir" && as_dir=. 23209 for ac_exec_ext in '' $ac_executable_extensions; do 23210 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23211 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 23212 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23213 break 2 23214 fi 23215 done 23216 done 23217 IFS=$as_save_IFS 23218 23219 ;; 23220 esac 23221 fi 23222 TIME=$ac_cv_path_TIME 23223 if test -n "$TIME"; then 23224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 23225 $as_echo "$TIME" >&6; } 23226 else 23227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23228 $as_echo "no" >&6; } 23229 fi 23230 23231 23232 test -n "$TIME" && break 23233 done 23234 23235 else 23236 # If it succeeded, then it was overridden by the user. We will use it 23237 # for the tool. 23238 23239 # First remove it from the list of overridden variables, so we can test 23240 # for unknown variables in the end. 23241 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23242 23243 # Check if we try to supply an empty value 23244 if test "x$TIME" = x; then 23245 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TIME= (no value)" >&5 23246 $as_echo "$as_me: Setting user supplied tool TIME= (no value)" >&6;} 23247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 23248 $as_echo_n "checking for TIME... " >&6; } 23249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23250 $as_echo "disabled" >&6; } 23251 else 23252 # Check if the provided tool contains a complete path. 23253 tool_specified="$TIME" 23254 tool_basename="${tool_specified##*/}" 23255 if test "x$tool_basename" = "x$tool_specified"; then 23256 # A command without a complete path is provided, search $PATH. 23257 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5 23258 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;} 23259 # Extract the first word of "$tool_basename", so it can be a program name with args. 23260 set dummy $tool_basename; ac_word=$2 23261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23262 $as_echo_n "checking for $ac_word... " >&6; } 23263 if ${ac_cv_path_TIME+:} false; then : 23264 $as_echo_n "(cached) " >&6 23265 else 23266 case $TIME in 23267 [\\/]* | ?:[\\/]*) 23268 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 23269 ;; 23270 *) 23271 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23272 for as_dir in $PATH 23273 do 23274 IFS=$as_save_IFS 23275 test -z "$as_dir" && as_dir=. 23276 for ac_exec_ext in '' $ac_executable_extensions; do 23277 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23278 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 23279 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23280 break 2 23281 fi 23282 done 23283 done 23284 IFS=$as_save_IFS 23285 23286 ;; 23287 esac 23288 fi 23289 TIME=$ac_cv_path_TIME 23290 if test -n "$TIME"; then 23291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 23292 $as_echo "$TIME" >&6; } 23293 else 23294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23295 $as_echo "no" >&6; } 23296 fi 23297 23298 23299 if test "x$TIME" = x; then 23300 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23301 fi 23302 else 23303 # Otherwise we believe it is a complete path. Use it as it is. 23304 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5 23305 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;} 23306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 23307 $as_echo_n "checking for TIME... " >&6; } 23308 if test ! -x "$tool_specified"; then 23309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23310 $as_echo "not found" >&6; } 23311 as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5 23312 fi 23313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23314 $as_echo "$tool_specified" >&6; } 23315 fi 23316 fi 23317 fi 23318 23319 fi 23320 23321 23322 23323 23324 # Publish this variable in the help. 23325 23326 23327 if [ -z "${FLOCK+x}" ]; then 23328 # The variable is not set by user, try to locate tool using the code snippet 23329 for ac_prog in flock 23330 do 23331 # Extract the first word of "$ac_prog", so it can be a program name with args. 23332 set dummy $ac_prog; ac_word=$2 23333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23334 $as_echo_n "checking for $ac_word... " >&6; } 23335 if ${ac_cv_path_FLOCK+:} false; then : 23336 $as_echo_n "(cached) " >&6 23337 else 23338 case $FLOCK in 23339 [\\/]* | ?:[\\/]*) 23340 ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. 23341 ;; 23342 *) 23343 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23344 for as_dir in $PATH 23345 do 23346 IFS=$as_save_IFS 23347 test -z "$as_dir" && as_dir=. 23348 for ac_exec_ext in '' $ac_executable_extensions; do 23349 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23350 ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" 23351 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23352 break 2 23353 fi 23354 done 23355 done 23356 IFS=$as_save_IFS 23357 23358 ;; 23359 esac 23360 fi 23361 FLOCK=$ac_cv_path_FLOCK 23362 if test -n "$FLOCK"; then 23363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 23364 $as_echo "$FLOCK" >&6; } 23365 else 23366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23367 $as_echo "no" >&6; } 23368 fi 23369 23370 23371 test -n "$FLOCK" && break 23372 done 23373 23374 else 23375 # The variable is set, but is it from the command line or the environment? 23376 23377 # Try to remove the string !FLOCK! from our list. 23378 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FLOCK!/} 23379 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23380 # If it failed, the variable was not from the command line. Ignore it, 23381 # but warn the user (except for BASH, which is always set by the calling BASH). 23382 if test "xFLOCK" != xBASH; then 23383 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FLOCK from the environment. Use command line variables instead." >&5 23384 $as_echo "$as_me: WARNING: Ignoring value of FLOCK from the environment. Use command line variables instead." >&2;} 23385 fi 23386 # Try to locate tool using the code snippet 23387 for ac_prog in flock 23388 do 23389 # Extract the first word of "$ac_prog", so it can be a program name with args. 23390 set dummy $ac_prog; ac_word=$2 23391 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23392 $as_echo_n "checking for $ac_word... " >&6; } 23393 if ${ac_cv_path_FLOCK+:} false; then : 23394 $as_echo_n "(cached) " >&6 23395 else 23396 case $FLOCK in 23397 [\\/]* | ?:[\\/]*) 23398 ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. 23399 ;; 23400 *) 23401 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23402 for as_dir in $PATH 23403 do 23404 IFS=$as_save_IFS 23405 test -z "$as_dir" && as_dir=. 23406 for ac_exec_ext in '' $ac_executable_extensions; do 23407 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23408 ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" 23409 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23410 break 2 23411 fi 23412 done 23413 done 23414 IFS=$as_save_IFS 23415 23416 ;; 23417 esac 23418 fi 23419 FLOCK=$ac_cv_path_FLOCK 23420 if test -n "$FLOCK"; then 23421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 23422 $as_echo "$FLOCK" >&6; } 23423 else 23424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23425 $as_echo "no" >&6; } 23426 fi 23427 23428 23429 test -n "$FLOCK" && break 23430 done 23431 23432 else 23433 # If it succeeded, then it was overridden by the user. We will use it 23434 # for the tool. 23435 23436 # First remove it from the list of overridden variables, so we can test 23437 # for unknown variables in the end. 23438 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23439 23440 # Check if we try to supply an empty value 23441 if test "x$FLOCK" = x; then 23442 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FLOCK= (no value)" >&5 23443 $as_echo "$as_me: Setting user supplied tool FLOCK= (no value)" >&6;} 23444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FLOCK" >&5 23445 $as_echo_n "checking for FLOCK... " >&6; } 23446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23447 $as_echo "disabled" >&6; } 23448 else 23449 # Check if the provided tool contains a complete path. 23450 tool_specified="$FLOCK" 23451 tool_basename="${tool_specified##*/}" 23452 if test "x$tool_basename" = "x$tool_specified"; then 23453 # A command without a complete path is provided, search $PATH. 23454 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FLOCK=$tool_basename" >&5 23455 $as_echo "$as_me: Will search for user supplied tool FLOCK=$tool_basename" >&6;} 23456 # Extract the first word of "$tool_basename", so it can be a program name with args. 23457 set dummy $tool_basename; ac_word=$2 23458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23459 $as_echo_n "checking for $ac_word... " >&6; } 23460 if ${ac_cv_path_FLOCK+:} false; then : 23461 $as_echo_n "(cached) " >&6 23462 else 23463 case $FLOCK in 23464 [\\/]* | ?:[\\/]*) 23465 ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. 23466 ;; 23467 *) 23468 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23469 for as_dir in $PATH 23470 do 23471 IFS=$as_save_IFS 23472 test -z "$as_dir" && as_dir=. 23473 for ac_exec_ext in '' $ac_executable_extensions; do 23474 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23475 ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" 23476 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23477 break 2 23478 fi 23479 done 23480 done 23481 IFS=$as_save_IFS 23482 23483 ;; 23484 esac 23485 fi 23486 FLOCK=$ac_cv_path_FLOCK 23487 if test -n "$FLOCK"; then 23488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 23489 $as_echo "$FLOCK" >&6; } 23490 else 23491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23492 $as_echo "no" >&6; } 23493 fi 23494 23495 23496 if test "x$FLOCK" = x; then 23497 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23498 fi 23499 else 23500 # Otherwise we believe it is a complete path. Use it as it is. 23501 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FLOCK=$tool_specified" >&5 23502 $as_echo "$as_me: Will use user supplied tool FLOCK=$tool_specified" >&6;} 23503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FLOCK" >&5 23504 $as_echo_n "checking for FLOCK... " >&6; } 23505 if test ! -x "$tool_specified"; then 23506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23507 $as_echo "not found" >&6; } 23508 as_fn_error $? "User supplied tool FLOCK=$tool_specified does not exist or is not executable" "$LINENO" 5 23509 fi 23510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23511 $as_echo "$tool_specified" >&6; } 23512 fi 23513 fi 23514 fi 23515 23516 fi 23517 23518 23519 # Dtrace is usually found in /usr/sbin on Solaris, but that directory may not 23520 # be in the user path. 23521 23522 23523 # Publish this variable in the help. 23524 23525 23526 if [ -z "${DTRACE+x}" ]; then 23527 # The variable is not set by user, try to locate tool using the code snippet 23528 for ac_prog in dtrace 23529 do 23530 # Extract the first word of "$ac_prog", so it can be a program name with args. 23531 set dummy $ac_prog; ac_word=$2 23532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23533 $as_echo_n "checking for $ac_word... " >&6; } 23534 if ${ac_cv_path_DTRACE+:} false; then : 23535 $as_echo_n "(cached) " >&6 23536 else 23537 case $DTRACE in 23538 [\\/]* | ?:[\\/]*) 23539 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23540 ;; 23541 *) 23542 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23543 as_dummy="$PATH:/usr/sbin" 23544 for as_dir in $as_dummy 23545 do 23546 IFS=$as_save_IFS 23547 test -z "$as_dir" && as_dir=. 23548 for ac_exec_ext in '' $ac_executable_extensions; do 23549 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23550 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23552 break 2 23553 fi 23554 done 23555 done 23556 IFS=$as_save_IFS 23557 23558 ;; 23559 esac 23560 fi 23561 DTRACE=$ac_cv_path_DTRACE 23562 if test -n "$DTRACE"; then 23563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23564 $as_echo "$DTRACE" >&6; } 23565 else 23566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23567 $as_echo "no" >&6; } 23568 fi 23569 23570 23571 test -n "$DTRACE" && break 23572 done 23573 23574 else 23575 # The variable is set, but is it from the command line or the environment? 23576 23577 # Try to remove the string !DTRACE! from our list. 23578 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DTRACE!/} 23579 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23580 # If it failed, the variable was not from the command line. Ignore it, 23581 # but warn the user (except for BASH, which is always set by the calling BASH). 23582 if test "xDTRACE" != xBASH; then 23583 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&5 23584 $as_echo "$as_me: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&2;} 23585 fi 23586 # Try to locate tool using the code snippet 23587 for ac_prog in dtrace 23588 do 23589 # Extract the first word of "$ac_prog", so it can be a program name with args. 23590 set dummy $ac_prog; ac_word=$2 23591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23592 $as_echo_n "checking for $ac_word... " >&6; } 23593 if ${ac_cv_path_DTRACE+:} false; then : 23594 $as_echo_n "(cached) " >&6 23595 else 23596 case $DTRACE in 23597 [\\/]* | ?:[\\/]*) 23598 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23599 ;; 23600 *) 23601 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23602 as_dummy="$PATH:/usr/sbin" 23603 for as_dir in $as_dummy 23604 do 23605 IFS=$as_save_IFS 23606 test -z "$as_dir" && as_dir=. 23607 for ac_exec_ext in '' $ac_executable_extensions; do 23608 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23609 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23611 break 2 23612 fi 23613 done 23614 done 23615 IFS=$as_save_IFS 23616 23617 ;; 23618 esac 23619 fi 23620 DTRACE=$ac_cv_path_DTRACE 23621 if test -n "$DTRACE"; then 23622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23623 $as_echo "$DTRACE" >&6; } 23624 else 23625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23626 $as_echo "no" >&6; } 23627 fi 23628 23629 23630 test -n "$DTRACE" && break 23631 done 23632 23633 else 23634 # If it succeeded, then it was overridden by the user. We will use it 23635 # for the tool. 23636 23637 # First remove it from the list of overridden variables, so we can test 23638 # for unknown variables in the end. 23639 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23640 23641 # Check if we try to supply an empty value 23642 if test "x$DTRACE" = x; then 23643 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DTRACE= (no value)" >&5 23644 $as_echo "$as_me: Setting user supplied tool DTRACE= (no value)" >&6;} 23645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 23646 $as_echo_n "checking for DTRACE... " >&6; } 23647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23648 $as_echo "disabled" >&6; } 23649 else 23650 # Check if the provided tool contains a complete path. 23651 tool_specified="$DTRACE" 23652 tool_basename="${tool_specified##*/}" 23653 if test "x$tool_basename" = "x$tool_specified"; then 23654 # A command without a complete path is provided, search $PATH. 23655 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DTRACE=$tool_basename" >&5 23656 $as_echo "$as_me: Will search for user supplied tool DTRACE=$tool_basename" >&6;} 23657 # Extract the first word of "$tool_basename", so it can be a program name with args. 23658 set dummy $tool_basename; ac_word=$2 23659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23660 $as_echo_n "checking for $ac_word... " >&6; } 23661 if ${ac_cv_path_DTRACE+:} false; then : 23662 $as_echo_n "(cached) " >&6 23663 else 23664 case $DTRACE in 23665 [\\/]* | ?:[\\/]*) 23666 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23667 ;; 23668 *) 23669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23670 for as_dir in $PATH 23671 do 23672 IFS=$as_save_IFS 23673 test -z "$as_dir" && as_dir=. 23674 for ac_exec_ext in '' $ac_executable_extensions; do 23675 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23676 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23677 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23678 break 2 23679 fi 23680 done 23681 done 23682 IFS=$as_save_IFS 23683 23684 ;; 23685 esac 23686 fi 23687 DTRACE=$ac_cv_path_DTRACE 23688 if test -n "$DTRACE"; then 23689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23690 $as_echo "$DTRACE" >&6; } 23691 else 23692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23693 $as_echo "no" >&6; } 23694 fi 23695 23696 23697 if test "x$DTRACE" = x; then 23698 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23699 fi 23700 else 23701 # Otherwise we believe it is a complete path. Use it as it is. 23702 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DTRACE=$tool_specified" >&5 23703 $as_echo "$as_me: Will use user supplied tool DTRACE=$tool_specified" >&6;} 23704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 23705 $as_echo_n "checking for DTRACE... " >&6; } 23706 if test ! -x "$tool_specified"; then 23707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23708 $as_echo "not found" >&6; } 23709 as_fn_error $? "User supplied tool DTRACE=$tool_specified does not exist or is not executable" "$LINENO" 5 23710 fi 23711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23712 $as_echo "$tool_specified" >&6; } 23713 fi 23714 fi 23715 fi 23716 23717 fi 23718 23719 23720 23721 23722 # Publish this variable in the help. 23723 23724 23725 if [ -z "${PATCH+x}" ]; then 23726 # The variable is not set by user, try to locate tool using the code snippet 23727 for ac_prog in gpatch patch 23728 do 23729 # Extract the first word of "$ac_prog", so it can be a program name with args. 23730 set dummy $ac_prog; ac_word=$2 23731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23732 $as_echo_n "checking for $ac_word... " >&6; } 23733 if ${ac_cv_path_PATCH+:} false; then : 23734 $as_echo_n "(cached) " >&6 23735 else 23736 case $PATCH in 23737 [\\/]* | ?:[\\/]*) 23738 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23739 ;; 23740 *) 23741 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23742 for as_dir in $PATH 23743 do 23744 IFS=$as_save_IFS 23745 test -z "$as_dir" && as_dir=. 23746 for ac_exec_ext in '' $ac_executable_extensions; do 23747 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23748 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23749 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23750 break 2 23751 fi 23752 done 23753 done 23754 IFS=$as_save_IFS 23755 23756 ;; 23757 esac 23758 fi 23759 PATCH=$ac_cv_path_PATCH 23760 if test -n "$PATCH"; then 23761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23762 $as_echo "$PATCH" >&6; } 23763 else 23764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23765 $as_echo "no" >&6; } 23766 fi 23767 23768 23769 test -n "$PATCH" && break 23770 done 23771 23772 else 23773 # The variable is set, but is it from the command line or the environment? 23774 23775 # Try to remove the string !PATCH! from our list. 23776 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PATCH!/} 23777 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23778 # If it failed, the variable was not from the command line. Ignore it, 23779 # but warn the user (except for BASH, which is always set by the calling BASH). 23780 if test "xPATCH" != xBASH; then 23781 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&5 23782 $as_echo "$as_me: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&2;} 23783 fi 23784 # Try to locate tool using the code snippet 23785 for ac_prog in gpatch patch 23786 do 23787 # Extract the first word of "$ac_prog", so it can be a program name with args. 23788 set dummy $ac_prog; ac_word=$2 23789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23790 $as_echo_n "checking for $ac_word... " >&6; } 23791 if ${ac_cv_path_PATCH+:} false; then : 23792 $as_echo_n "(cached) " >&6 23793 else 23794 case $PATCH in 23795 [\\/]* | ?:[\\/]*) 23796 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23797 ;; 23798 *) 23799 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23800 for as_dir in $PATH 23801 do 23802 IFS=$as_save_IFS 23803 test -z "$as_dir" && as_dir=. 23804 for ac_exec_ext in '' $ac_executable_extensions; do 23805 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23806 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23807 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23808 break 2 23809 fi 23810 done 23811 done 23812 IFS=$as_save_IFS 23813 23814 ;; 23815 esac 23816 fi 23817 PATCH=$ac_cv_path_PATCH 23818 if test -n "$PATCH"; then 23819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23820 $as_echo "$PATCH" >&6; } 23821 else 23822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23823 $as_echo "no" >&6; } 23824 fi 23825 23826 23827 test -n "$PATCH" && break 23828 done 23829 23830 else 23831 # If it succeeded, then it was overridden by the user. We will use it 23832 # for the tool. 23833 23834 # First remove it from the list of overridden variables, so we can test 23835 # for unknown variables in the end. 23836 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23837 23838 # Check if we try to supply an empty value 23839 if test "x$PATCH" = x; then 23840 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PATCH= (no value)" >&5 23841 $as_echo "$as_me: Setting user supplied tool PATCH= (no value)" >&6;} 23842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23843 $as_echo_n "checking for PATCH... " >&6; } 23844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23845 $as_echo "disabled" >&6; } 23846 else 23847 # Check if the provided tool contains a complete path. 23848 tool_specified="$PATCH" 23849 tool_basename="${tool_specified##*/}" 23850 if test "x$tool_basename" = "x$tool_specified"; then 23851 # A command without a complete path is provided, search $PATH. 23852 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PATCH=$tool_basename" >&5 23853 $as_echo "$as_me: Will search for user supplied tool PATCH=$tool_basename" >&6;} 23854 # Extract the first word of "$tool_basename", so it can be a program name with args. 23855 set dummy $tool_basename; ac_word=$2 23856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23857 $as_echo_n "checking for $ac_word... " >&6; } 23858 if ${ac_cv_path_PATCH+:} false; then : 23859 $as_echo_n "(cached) " >&6 23860 else 23861 case $PATCH in 23862 [\\/]* | ?:[\\/]*) 23863 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23864 ;; 23865 *) 23866 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23867 for as_dir in $PATH 23868 do 23869 IFS=$as_save_IFS 23870 test -z "$as_dir" && as_dir=. 23871 for ac_exec_ext in '' $ac_executable_extensions; do 23872 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23873 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23874 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23875 break 2 23876 fi 23877 done 23878 done 23879 IFS=$as_save_IFS 23880 23881 ;; 23882 esac 23883 fi 23884 PATCH=$ac_cv_path_PATCH 23885 if test -n "$PATCH"; then 23886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23887 $as_echo "$PATCH" >&6; } 23888 else 23889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23890 $as_echo "no" >&6; } 23891 fi 23892 23893 23894 if test "x$PATCH" = x; then 23895 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23896 fi 23897 else 23898 # Otherwise we believe it is a complete path. Use it as it is. 23899 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PATCH=$tool_specified" >&5 23900 $as_echo "$as_me: Will use user supplied tool PATCH=$tool_specified" >&6;} 23901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23902 $as_echo_n "checking for PATCH... " >&6; } 23903 if test ! -x "$tool_specified"; then 23904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23905 $as_echo "not found" >&6; } 23906 as_fn_error $? "User supplied tool PATCH=$tool_specified does not exist or is not executable" "$LINENO" 5 23907 fi 23908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23909 $as_echo "$tool_specified" >&6; } 23910 fi 23911 fi 23912 fi 23913 23914 fi 23915 23916 23917 # Check if it's GNU time 23918 IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'` 23919 if test "x$IS_GNU_TIME" != x; then 23920 IS_GNU_TIME=yes 23921 else 23922 IS_GNU_TIME=no 23923 fi 23924 23925 23926 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 23927 23928 23929 23930 # Publish this variable in the help. 23931 23932 23933 if [ -z "${DSYMUTIL+x}" ]; then 23934 # The variable is not set by user, try to locate tool using the code snippet 23935 for ac_prog in dsymutil 23936 do 23937 # Extract the first word of "$ac_prog", so it can be a program name with args. 23938 set dummy $ac_prog; ac_word=$2 23939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23940 $as_echo_n "checking for $ac_word... " >&6; } 23941 if ${ac_cv_path_DSYMUTIL+:} false; then : 23942 $as_echo_n "(cached) " >&6 23943 else 23944 case $DSYMUTIL in 23945 [\\/]* | ?:[\\/]*) 23946 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23947 ;; 23948 *) 23949 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23950 for as_dir in $PATH 23951 do 23952 IFS=$as_save_IFS 23953 test -z "$as_dir" && as_dir=. 23954 for ac_exec_ext in '' $ac_executable_extensions; do 23955 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23956 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23957 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23958 break 2 23959 fi 23960 done 23961 done 23962 IFS=$as_save_IFS 23963 23964 ;; 23965 esac 23966 fi 23967 DSYMUTIL=$ac_cv_path_DSYMUTIL 23968 if test -n "$DSYMUTIL"; then 23969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23970 $as_echo "$DSYMUTIL" >&6; } 23971 else 23972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23973 $as_echo "no" >&6; } 23974 fi 23975 23976 23977 test -n "$DSYMUTIL" && break 23978 done 23979 23980 else 23981 # The variable is set, but is it from the command line or the environment? 23982 23983 # Try to remove the string !DSYMUTIL! from our list. 23984 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/} 23985 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23986 # If it failed, the variable was not from the command line. Ignore it, 23987 # but warn the user (except for BASH, which is always set by the calling BASH). 23988 if test "xDSYMUTIL" != xBASH; then 23989 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5 23990 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;} 23991 fi 23992 # Try to locate tool using the code snippet 23993 for ac_prog in dsymutil 23994 do 23995 # Extract the first word of "$ac_prog", so it can be a program name with args. 23996 set dummy $ac_prog; ac_word=$2 23997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23998 $as_echo_n "checking for $ac_word... " >&6; } 23999 if ${ac_cv_path_DSYMUTIL+:} false; then : 24000 $as_echo_n "(cached) " >&6 24001 else 24002 case $DSYMUTIL in 24003 [\\/]* | ?:[\\/]*) 24004 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 24005 ;; 24006 *) 24007 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24008 for as_dir in $PATH 24009 do 24010 IFS=$as_save_IFS 24011 test -z "$as_dir" && as_dir=. 24012 for ac_exec_ext in '' $ac_executable_extensions; do 24013 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24014 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 24015 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24016 break 2 24017 fi 24018 done 24019 done 24020 IFS=$as_save_IFS 24021 24022 ;; 24023 esac 24024 fi 24025 DSYMUTIL=$ac_cv_path_DSYMUTIL 24026 if test -n "$DSYMUTIL"; then 24027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 24028 $as_echo "$DSYMUTIL" >&6; } 24029 else 24030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24031 $as_echo "no" >&6; } 24032 fi 24033 24034 24035 test -n "$DSYMUTIL" && break 24036 done 24037 24038 else 24039 # If it succeeded, then it was overridden by the user. We will use it 24040 # for the tool. 24041 24042 # First remove it from the list of overridden variables, so we can test 24043 # for unknown variables in the end. 24044 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24045 24046 # Check if we try to supply an empty value 24047 if test "x$DSYMUTIL" = x; then 24048 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DSYMUTIL= (no value)" >&5 24049 $as_echo "$as_me: Setting user supplied tool DSYMUTIL= (no value)" >&6;} 24050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 24051 $as_echo_n "checking for DSYMUTIL... " >&6; } 24052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24053 $as_echo "disabled" >&6; } 24054 else 24055 # Check if the provided tool contains a complete path. 24056 tool_specified="$DSYMUTIL" 24057 tool_basename="${tool_specified##*/}" 24058 if test "x$tool_basename" = "x$tool_specified"; then 24059 # A command without a complete path is provided, search $PATH. 24060 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5 24061 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;} 24062 # Extract the first word of "$tool_basename", so it can be a program name with args. 24063 set dummy $tool_basename; ac_word=$2 24064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24065 $as_echo_n "checking for $ac_word... " >&6; } 24066 if ${ac_cv_path_DSYMUTIL+:} false; then : 24067 $as_echo_n "(cached) " >&6 24068 else 24069 case $DSYMUTIL in 24070 [\\/]* | ?:[\\/]*) 24071 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 24072 ;; 24073 *) 24074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24075 for as_dir in $PATH 24076 do 24077 IFS=$as_save_IFS 24078 test -z "$as_dir" && as_dir=. 24079 for ac_exec_ext in '' $ac_executable_extensions; do 24080 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24081 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 24082 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24083 break 2 24084 fi 24085 done 24086 done 24087 IFS=$as_save_IFS 24088 24089 ;; 24090 esac 24091 fi 24092 DSYMUTIL=$ac_cv_path_DSYMUTIL 24093 if test -n "$DSYMUTIL"; then 24094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 24095 $as_echo "$DSYMUTIL" >&6; } 24096 else 24097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24098 $as_echo "no" >&6; } 24099 fi 24100 24101 24102 if test "x$DSYMUTIL" = x; then 24103 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24104 fi 24105 else 24106 # Otherwise we believe it is a complete path. Use it as it is. 24107 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5 24108 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;} 24109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 24110 $as_echo_n "checking for DSYMUTIL... " >&6; } 24111 if test ! -x "$tool_specified"; then 24112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24113 $as_echo "not found" >&6; } 24114 as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5 24115 fi 24116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24117 $as_echo "$tool_specified" >&6; } 24118 fi 24119 fi 24120 fi 24121 24122 fi 24123 24124 24125 24126 if test "x$DSYMUTIL" = x; then 24127 as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5 24128 fi 24129 24130 24131 24132 24133 24134 # Publish this variable in the help. 24135 24136 24137 if [ -z "${XATTR+x}" ]; then 24138 # The variable is not set by user, try to locate tool using the code snippet 24139 for ac_prog in xattr 24140 do 24141 # Extract the first word of "$ac_prog", so it can be a program name with args. 24142 set dummy $ac_prog; ac_word=$2 24143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24144 $as_echo_n "checking for $ac_word... " >&6; } 24145 if ${ac_cv_path_XATTR+:} false; then : 24146 $as_echo_n "(cached) " >&6 24147 else 24148 case $XATTR in 24149 [\\/]* | ?:[\\/]*) 24150 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 24151 ;; 24152 *) 24153 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24154 for as_dir in $PATH 24155 do 24156 IFS=$as_save_IFS 24157 test -z "$as_dir" && as_dir=. 24158 for ac_exec_ext in '' $ac_executable_extensions; do 24159 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24160 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 24161 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24162 break 2 24163 fi 24164 done 24165 done 24166 IFS=$as_save_IFS 24167 24168 ;; 24169 esac 24170 fi 24171 XATTR=$ac_cv_path_XATTR 24172 if test -n "$XATTR"; then 24173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 24174 $as_echo "$XATTR" >&6; } 24175 else 24176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24177 $as_echo "no" >&6; } 24178 fi 24179 24180 24181 test -n "$XATTR" && break 24182 done 24183 24184 else 24185 # The variable is set, but is it from the command line or the environment? 24186 24187 # Try to remove the string !XATTR! from our list. 24188 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/} 24189 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 24190 # If it failed, the variable was not from the command line. Ignore it, 24191 # but warn the user (except for BASH, which is always set by the calling BASH). 24192 if test "xXATTR" != xBASH; then 24193 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5 24194 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;} 24195 fi 24196 # Try to locate tool using the code snippet 24197 for ac_prog in xattr 24198 do 24199 # Extract the first word of "$ac_prog", so it can be a program name with args. 24200 set dummy $ac_prog; ac_word=$2 24201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24202 $as_echo_n "checking for $ac_word... " >&6; } 24203 if ${ac_cv_path_XATTR+:} false; then : 24204 $as_echo_n "(cached) " >&6 24205 else 24206 case $XATTR in 24207 [\\/]* | ?:[\\/]*) 24208 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 24209 ;; 24210 *) 24211 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24212 for as_dir in $PATH 24213 do 24214 IFS=$as_save_IFS 24215 test -z "$as_dir" && as_dir=. 24216 for ac_exec_ext in '' $ac_executable_extensions; do 24217 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24218 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 24219 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24220 break 2 24221 fi 24222 done 24223 done 24224 IFS=$as_save_IFS 24225 24226 ;; 24227 esac 24228 fi 24229 XATTR=$ac_cv_path_XATTR 24230 if test -n "$XATTR"; then 24231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 24232 $as_echo "$XATTR" >&6; } 24233 else 24234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24235 $as_echo "no" >&6; } 24236 fi 24237 24238 24239 test -n "$XATTR" && break 24240 done 24241 24242 else 24243 # If it succeeded, then it was overridden by the user. We will use it 24244 # for the tool. 24245 24246 # First remove it from the list of overridden variables, so we can test 24247 # for unknown variables in the end. 24248 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24249 24250 # Check if we try to supply an empty value 24251 if test "x$XATTR" = x; then 24252 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XATTR= (no value)" >&5 24253 $as_echo "$as_me: Setting user supplied tool XATTR= (no value)" >&6;} 24254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 24255 $as_echo_n "checking for XATTR... " >&6; } 24256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24257 $as_echo "disabled" >&6; } 24258 else 24259 # Check if the provided tool contains a complete path. 24260 tool_specified="$XATTR" 24261 tool_basename="${tool_specified##*/}" 24262 if test "x$tool_basename" = "x$tool_specified"; then 24263 # A command without a complete path is provided, search $PATH. 24264 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5 24265 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;} 24266 # Extract the first word of "$tool_basename", so it can be a program name with args. 24267 set dummy $tool_basename; ac_word=$2 24268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24269 $as_echo_n "checking for $ac_word... " >&6; } 24270 if ${ac_cv_path_XATTR+:} false; then : 24271 $as_echo_n "(cached) " >&6 24272 else 24273 case $XATTR in 24274 [\\/]* | ?:[\\/]*) 24275 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 24276 ;; 24277 *) 24278 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24279 for as_dir in $PATH 24280 do 24281 IFS=$as_save_IFS 24282 test -z "$as_dir" && as_dir=. 24283 for ac_exec_ext in '' $ac_executable_extensions; do 24284 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24285 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 24286 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24287 break 2 24288 fi 24289 done 24290 done 24291 IFS=$as_save_IFS 24292 24293 ;; 24294 esac 24295 fi 24296 XATTR=$ac_cv_path_XATTR 24297 if test -n "$XATTR"; then 24298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 24299 $as_echo "$XATTR" >&6; } 24300 else 24301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24302 $as_echo "no" >&6; } 24303 fi 24304 24305 24306 if test "x$XATTR" = x; then 24307 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24308 fi 24309 else 24310 # Otherwise we believe it is a complete path. Use it as it is. 24311 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5 24312 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;} 24313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 24314 $as_echo_n "checking for XATTR... " >&6; } 24315 if test ! -x "$tool_specified"; then 24316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24317 $as_echo "not found" >&6; } 24318 as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5 24319 fi 24320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24321 $as_echo "$tool_specified" >&6; } 24322 fi 24323 fi 24324 fi 24325 24326 fi 24327 24328 24329 24330 if test "x$XATTR" = x; then 24331 as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5 24332 fi 24333 24334 24335 24336 24337 # Publish this variable in the help. 24338 24339 24340 if [ -z "${CODESIGN+x}" ]; then 24341 # The variable is not set by user, try to locate tool using the code snippet 24342 for ac_prog in codesign 24343 do 24344 # Extract the first word of "$ac_prog", so it can be a program name with args. 24345 set dummy $ac_prog; ac_word=$2 24346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24347 $as_echo_n "checking for $ac_word... " >&6; } 24348 if ${ac_cv_path_CODESIGN+:} false; then : 24349 $as_echo_n "(cached) " >&6 24350 else 24351 case $CODESIGN in 24352 [\\/]* | ?:[\\/]*) 24353 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 24354 ;; 24355 *) 24356 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24357 for as_dir in $PATH 24358 do 24359 IFS=$as_save_IFS 24360 test -z "$as_dir" && as_dir=. 24361 for ac_exec_ext in '' $ac_executable_extensions; do 24362 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24363 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 24364 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24365 break 2 24366 fi 24367 done 24368 done 24369 IFS=$as_save_IFS 24370 24371 ;; 24372 esac 24373 fi 24374 CODESIGN=$ac_cv_path_CODESIGN 24375 if test -n "$CODESIGN"; then 24376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 24377 $as_echo "$CODESIGN" >&6; } 24378 else 24379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24380 $as_echo "no" >&6; } 24381 fi 24382 24383 24384 test -n "$CODESIGN" && break 24385 done 24386 24387 else 24388 # The variable is set, but is it from the command line or the environment? 24389 24390 # Try to remove the string !CODESIGN! from our list. 24391 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/} 24392 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 24393 # If it failed, the variable was not from the command line. Ignore it, 24394 # but warn the user (except for BASH, which is always set by the calling BASH). 24395 if test "xCODESIGN" != xBASH; then 24396 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5 24397 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;} 24398 fi 24399 # Try to locate tool using the code snippet 24400 for ac_prog in codesign 24401 do 24402 # Extract the first word of "$ac_prog", so it can be a program name with args. 24403 set dummy $ac_prog; ac_word=$2 24404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24405 $as_echo_n "checking for $ac_word... " >&6; } 24406 if ${ac_cv_path_CODESIGN+:} false; then : 24407 $as_echo_n "(cached) " >&6 24408 else 24409 case $CODESIGN in 24410 [\\/]* | ?:[\\/]*) 24411 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 24412 ;; 24413 *) 24414 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24415 for as_dir in $PATH 24416 do 24417 IFS=$as_save_IFS 24418 test -z "$as_dir" && as_dir=. 24419 for ac_exec_ext in '' $ac_executable_extensions; do 24420 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24421 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 24422 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24423 break 2 24424 fi 24425 done 24426 done 24427 IFS=$as_save_IFS 24428 24429 ;; 24430 esac 24431 fi 24432 CODESIGN=$ac_cv_path_CODESIGN 24433 if test -n "$CODESIGN"; then 24434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 24435 $as_echo "$CODESIGN" >&6; } 24436 else 24437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24438 $as_echo "no" >&6; } 24439 fi 24440 24441 24442 test -n "$CODESIGN" && break 24443 done 24444 24445 else 24446 # If it succeeded, then it was overridden by the user. We will use it 24447 # for the tool. 24448 24449 # First remove it from the list of overridden variables, so we can test 24450 # for unknown variables in the end. 24451 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24452 24453 # Check if we try to supply an empty value 24454 if test "x$CODESIGN" = x; then 24455 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CODESIGN= (no value)" >&5 24456 $as_echo "$as_me: Setting user supplied tool CODESIGN= (no value)" >&6;} 24457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 24458 $as_echo_n "checking for CODESIGN... " >&6; } 24459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24460 $as_echo "disabled" >&6; } 24461 else 24462 # Check if the provided tool contains a complete path. 24463 tool_specified="$CODESIGN" 24464 tool_basename="${tool_specified##*/}" 24465 if test "x$tool_basename" = "x$tool_specified"; then 24466 # A command without a complete path is provided, search $PATH. 24467 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5 24468 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;} 24469 # Extract the first word of "$tool_basename", so it can be a program name with args. 24470 set dummy $tool_basename; ac_word=$2 24471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24472 $as_echo_n "checking for $ac_word... " >&6; } 24473 if ${ac_cv_path_CODESIGN+:} false; then : 24474 $as_echo_n "(cached) " >&6 24475 else 24476 case $CODESIGN in 24477 [\\/]* | ?:[\\/]*) 24478 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 24479 ;; 24480 *) 24481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24482 for as_dir in $PATH 24483 do 24484 IFS=$as_save_IFS 24485 test -z "$as_dir" && as_dir=. 24486 for ac_exec_ext in '' $ac_executable_extensions; do 24487 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24488 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 24489 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24490 break 2 24491 fi 24492 done 24493 done 24494 IFS=$as_save_IFS 24495 24496 ;; 24497 esac 24498 fi 24499 CODESIGN=$ac_cv_path_CODESIGN 24500 if test -n "$CODESIGN"; then 24501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 24502 $as_echo "$CODESIGN" >&6; } 24503 else 24504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24505 $as_echo "no" >&6; } 24506 fi 24507 24508 24509 if test "x$CODESIGN" = x; then 24510 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24511 fi 24512 else 24513 # Otherwise we believe it is a complete path. Use it as it is. 24514 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5 24515 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;} 24516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 24517 $as_echo_n "checking for CODESIGN... " >&6; } 24518 if test ! -x "$tool_specified"; then 24519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24520 $as_echo "not found" >&6; } 24521 as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5 24522 fi 24523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24524 $as_echo "$tool_specified" >&6; } 24525 fi 24526 fi 24527 fi 24528 24529 fi 24530 24531 24532 if test "x$CODESIGN" != "x"; then 24533 # Verify that the openjdk_codesign certificate is present 24534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5 24535 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; } 24536 $RM codesign-testfile 24537 $TOUCH codesign-testfile 24538 $CODESIGN -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN= 24539 $RM codesign-testfile 24540 if test "x$CODESIGN" = x; then 24541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24542 $as_echo "no" >&6; } 24543 else 24544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24545 $as_echo "yes" >&6; } 24546 fi 24547 fi 24548 24549 24550 24551 # Publish this variable in the help. 24552 24553 24554 if [ -z "${SETFILE+x}" ]; then 24555 # The variable is not set by user, try to locate tool using the code snippet 24556 for ac_prog in SetFile 24557 do 24558 # Extract the first word of "$ac_prog", so it can be a program name with args. 24559 set dummy $ac_prog; ac_word=$2 24560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24561 $as_echo_n "checking for $ac_word... " >&6; } 24562 if ${ac_cv_path_SETFILE+:} false; then : 24563 $as_echo_n "(cached) " >&6 24564 else 24565 case $SETFILE in 24566 [\\/]* | ?:[\\/]*) 24567 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24568 ;; 24569 *) 24570 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24571 for as_dir in $PATH 24572 do 24573 IFS=$as_save_IFS 24574 test -z "$as_dir" && as_dir=. 24575 for ac_exec_ext in '' $ac_executable_extensions; do 24576 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24577 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24578 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24579 break 2 24580 fi 24581 done 24582 done 24583 IFS=$as_save_IFS 24584 24585 ;; 24586 esac 24587 fi 24588 SETFILE=$ac_cv_path_SETFILE 24589 if test -n "$SETFILE"; then 24590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24591 $as_echo "$SETFILE" >&6; } 24592 else 24593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24594 $as_echo "no" >&6; } 24595 fi 24596 24597 24598 test -n "$SETFILE" && break 24599 done 24600 24601 else 24602 # The variable is set, but is it from the command line or the environment? 24603 24604 # Try to remove the string !SETFILE! from our list. 24605 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/} 24606 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 24607 # If it failed, the variable was not from the command line. Ignore it, 24608 # but warn the user (except for BASH, which is always set by the calling BASH). 24609 if test "xSETFILE" != xBASH; then 24610 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5 24611 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;} 24612 fi 24613 # Try to locate tool using the code snippet 24614 for ac_prog in SetFile 24615 do 24616 # Extract the first word of "$ac_prog", so it can be a program name with args. 24617 set dummy $ac_prog; ac_word=$2 24618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24619 $as_echo_n "checking for $ac_word... " >&6; } 24620 if ${ac_cv_path_SETFILE+:} false; then : 24621 $as_echo_n "(cached) " >&6 24622 else 24623 case $SETFILE in 24624 [\\/]* | ?:[\\/]*) 24625 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24626 ;; 24627 *) 24628 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24629 for as_dir in $PATH 24630 do 24631 IFS=$as_save_IFS 24632 test -z "$as_dir" && as_dir=. 24633 for ac_exec_ext in '' $ac_executable_extensions; do 24634 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24635 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24636 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24637 break 2 24638 fi 24639 done 24640 done 24641 IFS=$as_save_IFS 24642 24643 ;; 24644 esac 24645 fi 24646 SETFILE=$ac_cv_path_SETFILE 24647 if test -n "$SETFILE"; then 24648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24649 $as_echo "$SETFILE" >&6; } 24650 else 24651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24652 $as_echo "no" >&6; } 24653 fi 24654 24655 24656 test -n "$SETFILE" && break 24657 done 24658 24659 else 24660 # If it succeeded, then it was overridden by the user. We will use it 24661 # for the tool. 24662 24663 # First remove it from the list of overridden variables, so we can test 24664 # for unknown variables in the end. 24665 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24666 24667 # Check if we try to supply an empty value 24668 if test "x$SETFILE" = x; then 24669 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SETFILE= (no value)" >&5 24670 $as_echo "$as_me: Setting user supplied tool SETFILE= (no value)" >&6;} 24671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 24672 $as_echo_n "checking for SETFILE... " >&6; } 24673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24674 $as_echo "disabled" >&6; } 24675 else 24676 # Check if the provided tool contains a complete path. 24677 tool_specified="$SETFILE" 24678 tool_basename="${tool_specified##*/}" 24679 if test "x$tool_basename" = "x$tool_specified"; then 24680 # A command without a complete path is provided, search $PATH. 24681 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5 24682 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;} 24683 # Extract the first word of "$tool_basename", so it can be a program name with args. 24684 set dummy $tool_basename; ac_word=$2 24685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24686 $as_echo_n "checking for $ac_word... " >&6; } 24687 if ${ac_cv_path_SETFILE+:} false; then : 24688 $as_echo_n "(cached) " >&6 24689 else 24690 case $SETFILE in 24691 [\\/]* | ?:[\\/]*) 24692 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24693 ;; 24694 *) 24695 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24696 for as_dir in $PATH 24697 do 24698 IFS=$as_save_IFS 24699 test -z "$as_dir" && as_dir=. 24700 for ac_exec_ext in '' $ac_executable_extensions; do 24701 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24702 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24703 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24704 break 2 24705 fi 24706 done 24707 done 24708 IFS=$as_save_IFS 24709 24710 ;; 24711 esac 24712 fi 24713 SETFILE=$ac_cv_path_SETFILE 24714 if test -n "$SETFILE"; then 24715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24716 $as_echo "$SETFILE" >&6; } 24717 else 24718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24719 $as_echo "no" >&6; } 24720 fi 24721 24722 24723 if test "x$SETFILE" = x; then 24724 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24725 fi 24726 else 24727 # Otherwise we believe it is a complete path. Use it as it is. 24728 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5 24729 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;} 24730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 24731 $as_echo_n "checking for SETFILE... " >&6; } 24732 if test ! -x "$tool_specified"; then 24733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24734 $as_echo "not found" >&6; } 24735 as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5 24736 fi 24737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24738 $as_echo "$tool_specified" >&6; } 24739 fi 24740 fi 24741 fi 24742 24743 fi 24744 24745 24746 24747 if test "x$SETFILE" = x; then 24748 as_fn_error $? "Could not find required tool for SETFILE" "$LINENO" 5 24749 fi 24750 24751 24752 fi 24753 24754 24755 # Check bash version 24756 # Extra [ ] to stop m4 mangling 24757 BASH_VER=`$BASH --version | $SED -n -e 's/^.*bash.*ersion *\([0-9.]*\).*$/\1/ p'` 24758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking bash version" >&5 24759 $as_echo_n "checking bash version... " >&6; } 24760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH_VER" >&5 24761 $as_echo "$BASH_VER" >&6; } 24762 24763 BASH_MAJOR=`$ECHO $BASH_VER | $CUT -d . -f 1` 24764 BASH_MINOR=`$ECHO $BASH_VER | $CUT -d . -f 2` 24765 if test $BASH_MAJOR -lt 3 || (test $BASH_MAJOR -eq 3 && test $BASH_MINOR -lt 2); then 24766 as_fn_error $? "bash version 3.2 or better is required" "$LINENO" 5 24767 fi 24768 24769 # Test if bash supports pipefail. 24770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports pipefail" >&5 24771 $as_echo_n "checking if bash supports pipefail... " >&6; } 24772 if ${BASH} -c 'set -o pipefail'; then 24773 BASH_ARGS="$BASH_ARGS -o pipefail" 24774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24775 $as_echo "yes" >&6; } 24776 else 24777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24778 $as_echo "no" >&6; } 24779 fi 24780 24781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports errexit (-e)" >&5 24782 $as_echo_n "checking if bash supports errexit (-e)... " >&6; } 24783 if ${BASH} -e -c 'true'; then 24784 BASH_ARGS="$BASH_ARGS -e" 24785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24786 $as_echo "yes" >&6; } 24787 else 24788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24789 $as_echo "no" >&6; } 24790 fi 24791 24792 24793 24794 24795 # Check if pkg-config is available. 24796 24797 24798 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 24799 if test -n "$ac_tool_prefix"; then 24800 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 24801 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 24802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24803 $as_echo_n "checking for $ac_word... " >&6; } 24804 if ${ac_cv_path_PKG_CONFIG+:} false; then : 24805 $as_echo_n "(cached) " >&6 24806 else 24807 case $PKG_CONFIG in 24808 [\\/]* | ?:[\\/]*) 24809 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. 24810 ;; 24811 *) 24812 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24813 for as_dir in $PATH 24814 do 24815 IFS=$as_save_IFS 24816 test -z "$as_dir" && as_dir=. 24817 for ac_exec_ext in '' $ac_executable_extensions; do 24818 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24819 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24820 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24821 break 2 24822 fi 24823 done 24824 done 24825 IFS=$as_save_IFS 24826 24827 ;; 24828 esac 24829 fi 24830 PKG_CONFIG=$ac_cv_path_PKG_CONFIG 24831 if test -n "$PKG_CONFIG"; then 24832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 24833 $as_echo "$PKG_CONFIG" >&6; } 24834 else 24835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24836 $as_echo "no" >&6; } 24837 fi 24838 24839 24840 fi 24841 if test -z "$ac_cv_path_PKG_CONFIG"; then 24842 ac_pt_PKG_CONFIG=$PKG_CONFIG 24843 # Extract the first word of "pkg-config", so it can be a program name with args. 24844 set dummy pkg-config; ac_word=$2 24845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24846 $as_echo_n "checking for $ac_word... " >&6; } 24847 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : 24848 $as_echo_n "(cached) " >&6 24849 else 24850 case $ac_pt_PKG_CONFIG in 24851 [\\/]* | ?:[\\/]*) 24852 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. 24853 ;; 24854 *) 24855 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24856 for as_dir in $PATH 24857 do 24858 IFS=$as_save_IFS 24859 test -z "$as_dir" && as_dir=. 24860 for ac_exec_ext in '' $ac_executable_extensions; do 24861 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24862 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24863 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24864 break 2 24865 fi 24866 done 24867 done 24868 IFS=$as_save_IFS 24869 24870 ;; 24871 esac 24872 fi 24873 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG 24874 if test -n "$ac_pt_PKG_CONFIG"; then 24875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 24876 $as_echo "$ac_pt_PKG_CONFIG" >&6; } 24877 else 24878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24879 $as_echo "no" >&6; } 24880 fi 24881 24882 if test "x$ac_pt_PKG_CONFIG" = x; then 24883 PKG_CONFIG="" 24884 else 24885 case $cross_compiling:$ac_tool_warned in 24886 yes:) 24887 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 24888 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 24889 ac_tool_warned=yes ;; 24890 esac 24891 PKG_CONFIG=$ac_pt_PKG_CONFIG 24892 fi 24893 else 24894 PKG_CONFIG="$ac_cv_path_PKG_CONFIG" 24895 fi 24896 24897 fi 24898 if test -n "$PKG_CONFIG"; then 24899 _pkg_min_version=0.9.0 24900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 24901 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } 24902 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 24903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24904 $as_echo "yes" >&6; } 24905 else 24906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24907 $as_echo "no" >&6; } 24908 PKG_CONFIG="" 24909 fi 24910 24911 fi 24912 24913 # After basic tools have been setup, we can check build os specific details. 24914 24915 ############################################################################### 24916 24917 # Note that this is the build platform OS version! 24918 24919 OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`" 24920 OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`" 24921 OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`" 24922 OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`" 24923 24924 24925 24926 24927 24928 # Misc basic settings 24929 24930 24931 # Check whether --with-default-make-target was given. 24932 if test "${with_default_make_target+set}" = set; then : 24933 withval=$with_default_make_target; 24934 fi 24935 24936 if test "x$with_default_make_target" = "x" \ 24937 || test "x$with_default_make_target" = "xyes"; then 24938 DEFAULT_MAKE_TARGET="exploded-image" 24939 elif test "x$with_default_make_target" = "xno"; then 24940 as_fn_error $? "--without-default-make-target is not a valid option" "$LINENO" 5 24941 else 24942 DEFAULT_MAKE_TARGET="$with_default_make_target" 24943 fi 24944 24945 24946 24947 24948 ############################################################################### 24949 # 24950 # Determine OpenJDK variants, options and version numbers. 24951 # 24952 ############################################################################### 24953 24954 # We need build & target for this. 24955 24956 # Should we build a JDK without a graphical UI? 24957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking headless only" >&5 24958 $as_echo_n "checking headless only... " >&6; } 24959 # Check whether --enable-headless-only was given. 24960 if test "${enable_headless_only+set}" = set; then : 24961 enableval=$enable_headless_only; 24962 fi 24963 24964 24965 if test "x$enable_headless_only" = "xyes"; then 24966 ENABLE_HEADLESS_ONLY="true" 24967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24968 $as_echo "yes" >&6; } 24969 elif test "x$enable_headless_only" = "xno"; then 24970 ENABLE_HEADLESS_ONLY="false" 24971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24972 $as_echo "no" >&6; } 24973 elif test "x$enable_headless_only" = "x"; then 24974 ENABLE_HEADLESS_ONLY="false" 24975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24976 $as_echo "no" >&6; } 24977 else 24978 as_fn_error $? "--enable-headless-only can only take yes or no" "$LINENO" 5 24979 fi 24980 24981 24982 24983 # Should we build the complete docs, or just a lightweight version? 24984 # Check whether --enable-full-docs was given. 24985 if test "${enable_full_docs+set}" = set; then : 24986 enableval=$enable_full_docs; 24987 fi 24988 24989 24990 # Verify dependencies 24991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for graphviz dot" >&5 24992 $as_echo_n "checking for graphviz dot... " >&6; } 24993 if test "x$DOT" != "x"; then 24994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24995 $as_echo "yes" >&6; } 24996 else 24997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, cannot generate full docs" >&5 24998 $as_echo "no, cannot generate full docs" >&6; } 24999 FULL_DOCS_DEP_MISSING=true 25000 fi 25001 25002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pandoc" >&5 25003 $as_echo_n "checking for pandoc... " >&6; } 25004 if test "x$PANDOC" != "x"; then 25005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25006 $as_echo "yes" >&6; } 25007 else 25008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, cannot generate full docs" >&5 25009 $as_echo "no, cannot generate full docs" >&6; } 25010 FULL_DOCS_DEP_MISSING=true 25011 fi 25012 25013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking full docs" >&5 25014 $as_echo_n "checking full docs... " >&6; } 25015 if test "x$enable_full_docs" = xyes; then 25016 if test "x$FULL_DOCS_DEP_MISSING" = "xtrue"; then 25017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 25018 $as_echo "no, missing dependencies" >&6; } 25019 25020 # Print a helpful message on how to acquire the necessary build dependency. 25021 # dot is the help tag: freetype, cups, alsa etc 25022 MISSING_DEPENDENCY=dot 25023 25024 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25025 cygwin_help $MISSING_DEPENDENCY 25026 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25027 msys_help $MISSING_DEPENDENCY 25028 else 25029 PKGHANDLER_COMMAND= 25030 25031 case $PKGHANDLER in 25032 apt-get) 25033 apt_help $MISSING_DEPENDENCY ;; 25034 yum) 25035 yum_help $MISSING_DEPENDENCY ;; 25036 brew) 25037 brew_help $MISSING_DEPENDENCY ;; 25038 port) 25039 port_help $MISSING_DEPENDENCY ;; 25040 pkgutil) 25041 pkgutil_help $MISSING_DEPENDENCY ;; 25042 pkgadd) 25043 pkgadd_help $MISSING_DEPENDENCY ;; 25044 esac 25045 25046 if test "x$PKGHANDLER_COMMAND" != x; then 25047 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 25048 fi 25049 fi 25050 25051 as_fn_error $? "Cannot enable full docs with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 25052 else 25053 ENABLE_FULL_DOCS=true 25054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 25055 $as_echo "yes, forced" >&6; } 25056 fi 25057 elif test "x$enable_full_docs" = xno; then 25058 ENABLE_FULL_DOCS=false 25059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 25060 $as_echo "no, forced" >&6; } 25061 elif test "x$enable_full_docs" = x; then 25062 # Check for prerequisites 25063 if test "x$FULL_DOCS_DEP_MISSING" = xtrue; then 25064 ENABLE_FULL_DOCS=false 25065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 25066 $as_echo "no, missing dependencies" >&6; } 25067 else 25068 ENABLE_FULL_DOCS=true 25069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 25070 $as_echo "yes, dependencies present" >&6; } 25071 fi 25072 else 25073 as_fn_error $? "--enable-full-docs can only take yes or no" "$LINENO" 5 25074 fi 25075 25076 25077 25078 # Choose cacerts source file 25079 25080 # Check whether --with-cacerts-file was given. 25081 if test "${with_cacerts_file+set}" = set; then : 25082 withval=$with_cacerts_file; 25083 fi 25084 25085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cacerts file" >&5 25086 $as_echo_n "checking for cacerts file... " >&6; } 25087 if test "x$with_cacerts_file" == x; then 25088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: default" >&5 25089 $as_echo "default" >&6; } 25090 else 25091 CACERTS_FILE=$with_cacerts_file 25092 if test ! -f "$CACERTS_FILE"; then 25093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: fail" >&5 25094 $as_echo "fail" >&6; } 25095 as_fn_error $? "Specified cacerts file \"$CACERTS_FILE\" does not exist" "$LINENO" 5 25096 fi 25097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CACERTS_FILE" >&5 25098 $as_echo "$CACERTS_FILE" >&6; } 25099 fi 25100 25101 25102 # Enable or disable unlimited crypto 25103 # Check whether --enable-unlimited-crypto was given. 25104 if test "${enable_unlimited_crypto+set}" = set; then : 25105 enableval=$enable_unlimited_crypto; 25106 else 25107 enable_unlimited_crypto=yes 25108 fi 25109 25110 if test "x$enable_unlimited_crypto" = "xyes"; then 25111 UNLIMITED_CRYPTO=true 25112 else 25113 UNLIMITED_CRYPTO=false 25114 fi 25115 25116 25117 # Should we build the serviceability agent (SA)? 25118 INCLUDE_SA=true 25119 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 25120 INCLUDE_SA=false 25121 fi 25122 if test "x$OPENJDK_TARGET_OS" = xaix ; then 25123 INCLUDE_SA=false 25124 fi 25125 25126 25127 # Compress jars 25128 COMPRESS_JARS=false 25129 25130 25131 25132 # Setup default copyright year. Mostly overridden when building close to a new year. 25133 25134 # Check whether --with-copyright-year was given. 25135 if test "${with_copyright_year+set}" = set; then : 25136 withval=$with_copyright_year; 25137 fi 25138 25139 if test "x$with_copyright_year" = xyes; then 25140 as_fn_error $? "Copyright year must have a value" "$LINENO" 5 25141 elif test "x$with_copyright_year" != x; then 25142 COPYRIGHT_YEAR="$with_copyright_year" 25143 else 25144 COPYRIGHT_YEAR=`$DATE +'%Y'` 25145 fi 25146 25147 25148 25149 # Check whether --enable-keep-packaged-modules was given. 25150 if test "${enable_keep_packaged_modules+set}" = set; then : 25151 enableval=$enable_keep_packaged_modules; 25152 fi 25153 25154 25155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if packaged modules are kept" >&5 25156 $as_echo_n "checking if packaged modules are kept... " >&6; } 25157 if test "x$enable_keep_packaged_modules" = "xyes"; then 25158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25159 $as_echo "yes" >&6; } 25160 JLINK_KEEP_PACKAGED_MODULES=true 25161 elif test "x$enable_keep_packaged_modules" = "xno"; then 25162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 25163 $as_echo "no" >&6; } 25164 JLINK_KEEP_PACKAGED_MODULES=false 25165 elif test "x$enable_keep_packaged_modules" = "x"; then 25166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 25167 $as_echo "yes (default)" >&6; } 25168 JLINK_KEEP_PACKAGED_MODULES=true 25169 else 25170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: error" >&5 25171 $as_echo "error" >&6; } 25172 as_fn_error $? "--enable-keep-packaged-modules accepts no argument" "$LINENO" 5 25173 fi 25174 25175 25176 25177 25178 # Warn user that old version arguments are deprecated. 25179 25180 25181 # Check whether --with-milestone was given. 25182 if test "${with_milestone+set}" = set; then : 25183 withval=$with_milestone; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-milestone is deprecated and will be ignored." >&5 25184 $as_echo "$as_me: WARNING: Option --with-milestone is deprecated and will be ignored." >&2;} 25185 fi 25186 25187 25188 25189 25190 # Check whether --with-update-version was given. 25191 if test "${with_update_version+set}" = set; then : 25192 withval=$with_update_version; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-update-version is deprecated and will be ignored." >&5 25193 $as_echo "$as_me: WARNING: Option --with-update-version is deprecated and will be ignored." >&2;} 25194 fi 25195 25196 25197 25198 25199 # Check whether --with-user-release-suffix was given. 25200 if test "${with_user_release_suffix+set}" = set; then : 25201 withval=$with_user_release_suffix; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-user-release-suffix is deprecated and will be ignored." >&5 25202 $as_echo "$as_me: WARNING: Option --with-user-release-suffix is deprecated and will be ignored." >&2;} 25203 fi 25204 25205 25206 25207 25208 # Check whether --with-build-number was given. 25209 if test "${with_build_number+set}" = set; then : 25210 withval=$with_build_number; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-build-number is deprecated and will be ignored." >&5 25211 $as_echo "$as_me: WARNING: Option --with-build-number is deprecated and will be ignored." >&2;} 25212 fi 25213 25214 25215 25216 # Source the version numbers file 25217 . $AUTOCONF_DIR/version-numbers 25218 25219 # Some non-version number information is set in that file 25220 25221 25222 25223 25224 25225 25226 25227 25228 25229 # Override version from arguments 25230 25231 # If --with-version-string is set, process it first. It is possible to 25232 # override parts with more specific flags, since these are processed later. 25233 25234 # Check whether --with-version-string was given. 25235 if test "${with_version_string+set}" = set; then : 25236 withval=$with_version_string; 25237 fi 25238 25239 if test "x$with_version_string" = xyes; then 25240 as_fn_error $? "--with-version-string must have a value" "$LINENO" 5 25241 elif test "x$with_version_string" != x; then 25242 # Additional [] needed to keep m4 from mangling shell constructs. 25243 if [[ $with_version_string =~ ^([0-9]+)(\.([0-9]+))?(\.([0-9]+))?(\.([0-9]+))?(-([a-zA-Z]+))?((\+)([0-9]+)?(-([-a-zA-Z0-9.]+))?)?$ ]] ; then 25244 VERSION_MAJOR=${BASH_REMATCH[1]} 25245 VERSION_MINOR=${BASH_REMATCH[3]} 25246 VERSION_SECURITY=${BASH_REMATCH[5]} 25247 VERSION_PATCH=${BASH_REMATCH[7]} 25248 VERSION_PRE=${BASH_REMATCH[9]} 25249 version_plus_separator=${BASH_REMATCH[11]} 25250 VERSION_BUILD=${BASH_REMATCH[12]} 25251 VERSION_OPT=${BASH_REMATCH[14]} 25252 # Unspecified numerical fields are interpreted as 0. 25253 if test "x$VERSION_MINOR" = x; then 25254 VERSION_MINOR=0 25255 fi 25256 if test "x$VERSION_SECURITY" = x; then 25257 VERSION_SECURITY=0 25258 fi 25259 if test "x$VERSION_PATCH" = x; then 25260 VERSION_PATCH=0 25261 fi 25262 if test "x$version_plus_separator" != x \ 25263 && test "x$VERSION_BUILD$VERSION_OPT" = x; then 25264 as_fn_error $? "Version string contains + but both 'BUILD' and 'OPT' are missing" "$LINENO" 5 25265 fi 25266 # Stop the version part process from setting default values. 25267 # We still allow them to explicitly override though. 25268 NO_DEFAULT_VERSION_PARTS=true 25269 else 25270 as_fn_error $? "--with-version-string fails to parse as a valid version string: $with_version_string" "$LINENO" 5 25271 fi 25272 fi 25273 25274 25275 # Check whether --with-version-pre was given. 25276 if test "${with_version_pre+set}" = set; then : 25277 withval=$with_version_pre; with_version_pre_present=true 25278 else 25279 with_version_pre_present=false 25280 fi 25281 25282 25283 if test "x$with_version_pre_present" = xtrue; then 25284 if test "x$with_version_pre" = xyes; then 25285 as_fn_error $? "--with-version-pre must have a value" "$LINENO" 5 25286 elif test "x$with_version_pre" = xno; then 25287 # Interpret --without-* as empty string instead of the literal "no" 25288 VERSION_PRE= 25289 else 25290 # Only [a-zA-Z] is allowed in the VERSION_PRE. Outer [ ] to quote m4. 25291 VERSION_PRE=`$ECHO "$with_version_pre" | $TR -c -d '[a-z][A-Z]'` 25292 if test "x$VERSION_PRE" != "x$with_version_pre"; then 25293 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&5 25294 $as_echo "$as_me: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&2;} 25295 fi 25296 fi 25297 else 25298 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25299 # Default is to use "internal" as pre 25300 VERSION_PRE="internal" 25301 fi 25302 fi 25303 25304 25305 # Check whether --with-version-opt was given. 25306 if test "${with_version_opt+set}" = set; then : 25307 withval=$with_version_opt; with_version_opt_present=true 25308 else 25309 with_version_opt_present=false 25310 fi 25311 25312 25313 if test "x$with_version_opt_present" = xtrue; then 25314 if test "x$with_version_opt" = xyes; then 25315 as_fn_error $? "--with-version-opt must have a value" "$LINENO" 5 25316 elif test "x$with_version_opt" = xno; then 25317 # Interpret --without-* as empty string instead of the literal "no" 25318 VERSION_OPT= 25319 else 25320 # Only [-.a-zA-Z0-9] is allowed in the VERSION_OPT. Outer [ ] to quote m4. 25321 VERSION_OPT=`$ECHO "$with_version_opt" | $TR -c -d '[a-z][A-Z][0-9].-'` 25322 if test "x$VERSION_OPT" != "x$with_version_opt"; then 25323 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&5 25324 $as_echo "$as_me: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&2;} 25325 fi 25326 fi 25327 else 25328 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25329 # Default is to calculate a string like this 'adhoc.<username>.<base dir name>' 25330 # Outer [ ] to quote m4. 25331 basedirname=`$BASENAME "$TOPDIR" | $TR -d -c '[a-z][A-Z][0-9].-'` 25332 VERSION_OPT="adhoc.$USERNAME.$basedirname" 25333 fi 25334 fi 25335 25336 25337 # Check whether --with-version-build was given. 25338 if test "${with_version_build+set}" = set; then : 25339 withval=$with_version_build; with_version_build_present=true 25340 else 25341 with_version_build_present=false 25342 fi 25343 25344 25345 if test "x$with_version_build_present" = xtrue; then 25346 if test "x$with_version_build" = xyes; then 25347 as_fn_error $? "--with-version-build must have a value" "$LINENO" 5 25348 elif test "x$with_version_build" = xno; then 25349 # Interpret --without-* as empty string instead of the literal "no" 25350 VERSION_BUILD= 25351 elif test "x$with_version_build" = x; then 25352 VERSION_BUILD= 25353 else 25354 25355 # Additional [] needed to keep m4 from mangling shell constructs. 25356 if ! [[ "$with_version_build" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25357 as_fn_error $? "\"$with_version_build\" is not a valid numerical value for VERSION_BUILD" "$LINENO" 5 25358 fi 25359 # Extract the version number without leading zeros. 25360 cleaned_value=${BASH_REMATCH[1]} 25361 if test "x$cleaned_value" = x; then 25362 # Special case for zero 25363 cleaned_value=${BASH_REMATCH[2]} 25364 fi 25365 25366 if test $cleaned_value -gt 255; then 25367 as_fn_error $? "VERSION_BUILD is given as $with_version_build. This is greater than 255 which is not allowed." "$LINENO" 5 25368 fi 25369 if test "x$cleaned_value" != "x$with_version_build"; then 25370 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&5 25371 $as_echo "$as_me: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&2;} 25372 fi 25373 VERSION_BUILD=$cleaned_value 25374 25375 fi 25376 else 25377 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25378 # Default is to not have a build number. 25379 VERSION_BUILD="" 25380 # FIXME: Until all code can cope with an empty VERSION_BUILD, set it to 0. 25381 VERSION_BUILD=0 25382 fi 25383 fi 25384 25385 25386 # Check whether --with-version-major was given. 25387 if test "${with_version_major+set}" = set; then : 25388 withval=$with_version_major; with_version_major_present=true 25389 else 25390 with_version_major_present=false 25391 fi 25392 25393 25394 if test "x$with_version_major_present" = xtrue; then 25395 if test "x$with_version_major" = xyes; then 25396 as_fn_error $? "--with-version-major must have a value" "$LINENO" 5 25397 else 25398 25399 # Additional [] needed to keep m4 from mangling shell constructs. 25400 if ! [[ "$with_version_major" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25401 as_fn_error $? "\"$with_version_major\" is not a valid numerical value for VERSION_MAJOR" "$LINENO" 5 25402 fi 25403 # Extract the version number without leading zeros. 25404 cleaned_value=${BASH_REMATCH[1]} 25405 if test "x$cleaned_value" = x; then 25406 # Special case for zero 25407 cleaned_value=${BASH_REMATCH[2]} 25408 fi 25409 25410 if test $cleaned_value -gt 255; then 25411 as_fn_error $? "VERSION_MAJOR is given as $with_version_major. This is greater than 255 which is not allowed." "$LINENO" 5 25412 fi 25413 if test "x$cleaned_value" != "x$with_version_major"; then 25414 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&5 25415 $as_echo "$as_me: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&2;} 25416 fi 25417 VERSION_MAJOR=$cleaned_value 25418 25419 fi 25420 else 25421 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25422 # Default is to get value from version-numbers 25423 VERSION_MAJOR="$DEFAULT_VERSION_MAJOR" 25424 fi 25425 fi 25426 25427 25428 # Check whether --with-version-minor was given. 25429 if test "${with_version_minor+set}" = set; then : 25430 withval=$with_version_minor; with_version_minor_present=true 25431 else 25432 with_version_minor_present=false 25433 fi 25434 25435 25436 if test "x$with_version_minor_present" = xtrue; then 25437 if test "x$with_version_minor" = xyes; then 25438 as_fn_error $? "--with-version-minor must have a value" "$LINENO" 5 25439 elif test "x$with_version_minor" = xno; then 25440 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 25441 VERSION_MINOR=0 25442 elif test "x$with_version_minor" = x; then 25443 VERSION_MINOR=0 25444 else 25445 25446 # Additional [] needed to keep m4 from mangling shell constructs. 25447 if ! [[ "$with_version_minor" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25448 as_fn_error $? "\"$with_version_minor\" is not a valid numerical value for VERSION_MINOR" "$LINENO" 5 25449 fi 25450 # Extract the version number without leading zeros. 25451 cleaned_value=${BASH_REMATCH[1]} 25452 if test "x$cleaned_value" = x; then 25453 # Special case for zero 25454 cleaned_value=${BASH_REMATCH[2]} 25455 fi 25456 25457 if test $cleaned_value -gt 255; then 25458 as_fn_error $? "VERSION_MINOR is given as $with_version_minor. This is greater than 255 which is not allowed." "$LINENO" 5 25459 fi 25460 if test "x$cleaned_value" != "x$with_version_minor"; then 25461 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&5 25462 $as_echo "$as_me: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&2;} 25463 fi 25464 VERSION_MINOR=$cleaned_value 25465 25466 fi 25467 else 25468 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25469 # Default is 0, if unspecified 25470 VERSION_MINOR=$DEFAULT_VERSION_MINOR 25471 fi 25472 fi 25473 25474 25475 # Check whether --with-version-security was given. 25476 if test "${with_version_security+set}" = set; then : 25477 withval=$with_version_security; with_version_security_present=true 25478 else 25479 with_version_security_present=false 25480 fi 25481 25482 25483 if test "x$with_version_security_present" = xtrue; then 25484 if test "x$with_version_security" = xyes; then 25485 as_fn_error $? "--with-version-security must have a value" "$LINENO" 5 25486 elif test "x$with_version_security" = xno; then 25487 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 25488 VERSION_SECURITY=0 25489 elif test "x$with_version_security" = x; then 25490 VERSION_SECURITY=0 25491 else 25492 25493 # Additional [] needed to keep m4 from mangling shell constructs. 25494 if ! [[ "$with_version_security" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25495 as_fn_error $? "\"$with_version_security\" is not a valid numerical value for VERSION_SECURITY" "$LINENO" 5 25496 fi 25497 # Extract the version number without leading zeros. 25498 cleaned_value=${BASH_REMATCH[1]} 25499 if test "x$cleaned_value" = x; then 25500 # Special case for zero 25501 cleaned_value=${BASH_REMATCH[2]} 25502 fi 25503 25504 if test $cleaned_value -gt 255; then 25505 as_fn_error $? "VERSION_SECURITY is given as $with_version_security. This is greater than 255 which is not allowed." "$LINENO" 5 25506 fi 25507 if test "x$cleaned_value" != "x$with_version_security"; then 25508 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&5 25509 $as_echo "$as_me: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&2;} 25510 fi 25511 VERSION_SECURITY=$cleaned_value 25512 25513 fi 25514 else 25515 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25516 # Default is 0, if unspecified 25517 VERSION_SECURITY=$DEFAULT_VERSION_SECURITY 25518 fi 25519 fi 25520 25521 25522 # Check whether --with-version-patch was given. 25523 if test "${with_version_patch+set}" = set; then : 25524 withval=$with_version_patch; with_version_patch_present=true 25525 else 25526 with_version_patch_present=false 25527 fi 25528 25529 25530 if test "x$with_version_patch_present" = xtrue; then 25531 if test "x$with_version_patch" = xyes; then 25532 as_fn_error $? "--with-version-patch must have a value" "$LINENO" 5 25533 elif test "x$with_version_patch" = xno; then 25534 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 25535 VERSION_PATCH=0 25536 elif test "x$with_version_patch" = x; then 25537 VERSION_PATCH=0 25538 else 25539 25540 # Additional [] needed to keep m4 from mangling shell constructs. 25541 if ! [[ "$with_version_patch" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25542 as_fn_error $? "\"$with_version_patch\" is not a valid numerical value for VERSION_PATCH" "$LINENO" 5 25543 fi 25544 # Extract the version number without leading zeros. 25545 cleaned_value=${BASH_REMATCH[1]} 25546 if test "x$cleaned_value" = x; then 25547 # Special case for zero 25548 cleaned_value=${BASH_REMATCH[2]} 25549 fi 25550 25551 if test $cleaned_value -gt 255; then 25552 as_fn_error $? "VERSION_PATCH is given as $with_version_patch. This is greater than 255 which is not allowed." "$LINENO" 5 25553 fi 25554 if test "x$cleaned_value" != "x$with_version_patch"; then 25555 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&5 25556 $as_echo "$as_me: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&2;} 25557 fi 25558 VERSION_PATCH=$cleaned_value 25559 25560 fi 25561 else 25562 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25563 # Default is 0, if unspecified 25564 VERSION_PATCH=$DEFAULT_VERSION_PATCH 25565 fi 25566 fi 25567 25568 # Calculate derived version properties 25569 25570 # Set VERSION_IS_GA based on if VERSION_PRE has a value 25571 if test "x$VERSION_PRE" = x; then 25572 VERSION_IS_GA=true 25573 else 25574 VERSION_IS_GA=false 25575 fi 25576 25577 # VERSION_NUMBER but always with exactly 4 positions, with 0 for empty positions. 25578 VERSION_NUMBER_FOUR_POSITIONS=$VERSION_MAJOR.$VERSION_MINOR.$VERSION_SECURITY.$VERSION_PATCH 25579 25580 stripped_version_number=$VERSION_NUMBER_FOUR_POSITIONS 25581 # Strip trailing zeroes from stripped_version_number 25582 for i in 1 2 3 ; do stripped_version_number=${stripped_version_number%.0} ; done 25583 VERSION_NUMBER=$stripped_version_number 25584 25585 # The complete version string, with additional build information 25586 if test "x$VERSION_BUILD$VERSION_OPT" = x; then 25587 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 25588 else 25589 # If either build or opt is set, we need a + separator 25590 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE}+$VERSION_BUILD${VERSION_OPT:+-$VERSION_OPT} 25591 fi 25592 25593 # The short version string, just VERSION_NUMBER and PRE, if present. 25594 VERSION_SHORT=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 25595 25596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version string" >&5 25597 $as_echo_n "checking for version string... " >&6; } 25598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VERSION_STRING" >&5 25599 $as_echo "$VERSION_STRING" >&6; } 25600 25601 25602 25603 25604 25605 25606 25607 25608 25609 25610 25611 25612 25613 25614 25615 ############################################################################### 25616 # 25617 # Setup BootJDK, used to bootstrap the build. 25618 # 25619 ############################################################################### 25620 25621 25622 BOOT_JDK_FOUND=no 25623 25624 # Check whether --with-boot-jdk was given. 25625 if test "${with_boot_jdk+set}" = set; then : 25626 withval=$with_boot_jdk; 25627 fi 25628 25629 25630 # We look for the Boot JDK through various means, going from more certain to 25631 # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if 25632 # we detected something (if so, the path to the jdk is in BOOT_JDK). But we 25633 # must check if this is indeed valid; otherwise we'll continue looking. 25634 25635 # Test: Is bootjdk explicitly set by command line arguments? 25636 25637 if test "x$BOOT_JDK_FOUND" = xno; then 25638 # Now execute the test 25639 25640 if test "x$with_boot_jdk" != x; then 25641 BOOT_JDK=$with_boot_jdk 25642 BOOT_JDK_FOUND=maybe 25643 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5 25644 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;} 25645 fi 25646 25647 25648 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25649 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25650 # Do we have a bin/java? 25651 if test ! -x "$BOOT_JDK/bin/java"; then 25652 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25653 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25654 BOOT_JDK_FOUND=no 25655 else 25656 # Do we have a bin/javac? 25657 if test ! -x "$BOOT_JDK/bin/javac"; then 25658 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25659 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25660 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25661 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25662 BOOT_JDK_FOUND=no 25663 else 25664 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25665 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25666 25667 # Extra M4 quote needed to protect [] in grep expression. 25668 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 25669 if test "x$FOUND_CORRECT_VERSION" = x; then 25670 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25671 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25672 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 25673 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 25674 BOOT_JDK_FOUND=no 25675 else 25676 # We're done! :-) 25677 BOOT_JDK_FOUND=yes 25678 25679 # Only process if variable expands to non-empty 25680 25681 if test "x$BOOT_JDK" != x; then 25682 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25683 25684 # Input might be given as Windows format, start by converting to 25685 # unix format. 25686 path="$BOOT_JDK" 25687 new_path=`$CYGPATH -u "$path"` 25688 25689 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25690 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25691 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25692 # "foo.exe" is OK but "foo" is an error. 25693 # 25694 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25695 # It is also a way to make sure we got the proper file name for the real test later on. 25696 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25697 if test "x$test_shortpath" = x; then 25698 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25699 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25700 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25701 fi 25702 25703 # Call helper function which possibly converts this using DOS-style short mode. 25704 # If so, the updated path is stored in $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 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25715 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25716 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25717 # Going to short mode and back again did indeed matter. Since short mode is 25718 # case insensitive, let's make it lowercase to improve readability. 25719 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25720 # Now convert it back to Unix-style (cygpath) 25721 input_path=`$CYGPATH -u "$shortmode_path"` 25722 new_path="$input_path" 25723 fi 25724 fi 25725 25726 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25727 if test "x$test_cygdrive_prefix" = x; then 25728 # As a simple fix, exclude /usr/bin since it's not a real path. 25729 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25730 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25731 # a path prefixed by /cygdrive for fixpath to work. 25732 new_path="$CYGWIN_ROOT_PATH$input_path" 25733 fi 25734 fi 25735 25736 25737 if test "x$path" != "x$new_path"; then 25738 BOOT_JDK="$new_path" 25739 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25740 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25741 fi 25742 25743 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25744 25745 path="$BOOT_JDK" 25746 has_colon=`$ECHO $path | $GREP ^.:` 25747 new_path="$path" 25748 if test "x$has_colon" = x; then 25749 # Not in mixed or Windows style, start by that. 25750 new_path=`cmd //c echo $path` 25751 fi 25752 25753 25754 input_path="$new_path" 25755 # Check if we need to convert this using DOS-style short mode. If the path 25756 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25757 # take no chances and rewrite it. 25758 # Note: m4 eats our [], so we need to use [ and ] instead. 25759 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25760 if test "x$has_forbidden_chars" != x; then 25761 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25762 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25763 fi 25764 25765 25766 windows_path="$new_path" 25767 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25768 unix_path=`$CYGPATH -u "$windows_path"` 25769 new_path="$unix_path" 25770 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25771 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25772 new_path="$unix_path" 25773 fi 25774 25775 if test "x$path" != "x$new_path"; then 25776 BOOT_JDK="$new_path" 25777 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25778 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25779 fi 25780 25781 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25782 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25783 25784 else 25785 # We're on a unix platform. Hooray! :) 25786 path="$BOOT_JDK" 25787 has_space=`$ECHO "$path" | $GREP " "` 25788 if test "x$has_space" != x; then 25789 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25790 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25791 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25792 fi 25793 25794 # Use eval to expand a potential ~ 25795 eval path="$path" 25796 if test ! -f "$path" && test ! -d "$path"; then 25797 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25798 fi 25799 25800 if test -d "$path"; then 25801 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25802 else 25803 dir="`$DIRNAME "$path"`" 25804 base="`$BASENAME "$path"`" 25805 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25806 fi 25807 fi 25808 fi 25809 25810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25811 $as_echo_n "checking for Boot JDK... " >&6; } 25812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25813 $as_echo "$BOOT_JDK" >&6; } 25814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25815 $as_echo_n "checking Boot JDK version... " >&6; } 25816 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25818 $as_echo "$BOOT_JDK_VERSION" >&6; } 25819 fi # end check jdk version 25820 fi # end check javac 25821 fi # end check java 25822 fi # end check boot jdk found 25823 fi 25824 25825 if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then 25826 # Having specified an argument which is incorrect will produce an instant failure; 25827 # we should not go on looking 25828 as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5 25829 fi 25830 25831 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 25832 25833 if test "x$BOOT_JDK_FOUND" = xno; then 25834 # Now execute the test 25835 25836 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 25837 # First check at user selected default 25838 25839 if test "x$BOOT_JDK_FOUND" = xno; then 25840 # Now execute the test 25841 25842 if test -x /usr/libexec/java_home; then 25843 BOOT_JDK=`/usr/libexec/java_home ` 25844 BOOT_JDK_FOUND=maybe 25845 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5 25846 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;} 25847 fi 25848 25849 25850 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25851 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25852 # Do we have a bin/java? 25853 if test ! -x "$BOOT_JDK/bin/java"; then 25854 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25855 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25856 BOOT_JDK_FOUND=no 25857 else 25858 # Do we have a bin/javac? 25859 if test ! -x "$BOOT_JDK/bin/javac"; then 25860 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25861 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25862 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25863 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25864 BOOT_JDK_FOUND=no 25865 else 25866 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25867 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25868 25869 # Extra M4 quote needed to protect [] in grep expression. 25870 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 25871 if test "x$FOUND_CORRECT_VERSION" = x; then 25872 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25873 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25874 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 25875 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 25876 BOOT_JDK_FOUND=no 25877 else 25878 # We're done! :-) 25879 BOOT_JDK_FOUND=yes 25880 25881 # Only process if variable expands to non-empty 25882 25883 if test "x$BOOT_JDK" != x; then 25884 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25885 25886 # Input might be given as Windows format, start by converting to 25887 # unix format. 25888 path="$BOOT_JDK" 25889 new_path=`$CYGPATH -u "$path"` 25890 25891 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25892 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25893 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25894 # "foo.exe" is OK but "foo" is an error. 25895 # 25896 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25897 # It is also a way to make sure we got the proper file name for the real test later on. 25898 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25899 if test "x$test_shortpath" = x; then 25900 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25901 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25902 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25903 fi 25904 25905 # Call helper function which possibly converts this using DOS-style short mode. 25906 # If so, the updated path is stored in $new_path. 25907 25908 input_path="$new_path" 25909 # Check if we need to convert this using DOS-style short mode. If the path 25910 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25911 # take no chances and rewrite it. 25912 # Note: m4 eats our [], so we need to use [ and ] instead. 25913 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25914 if test "x$has_forbidden_chars" != x; then 25915 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25916 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25917 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25918 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25919 # Going to short mode and back again did indeed matter. Since short mode is 25920 # case insensitive, let's make it lowercase to improve readability. 25921 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25922 # Now convert it back to Unix-style (cygpath) 25923 input_path=`$CYGPATH -u "$shortmode_path"` 25924 new_path="$input_path" 25925 fi 25926 fi 25927 25928 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25929 if test "x$test_cygdrive_prefix" = x; then 25930 # As a simple fix, exclude /usr/bin since it's not a real path. 25931 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25932 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25933 # a path prefixed by /cygdrive for fixpath to work. 25934 new_path="$CYGWIN_ROOT_PATH$input_path" 25935 fi 25936 fi 25937 25938 25939 if test "x$path" != "x$new_path"; then 25940 BOOT_JDK="$new_path" 25941 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25942 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25943 fi 25944 25945 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25946 25947 path="$BOOT_JDK" 25948 has_colon=`$ECHO $path | $GREP ^.:` 25949 new_path="$path" 25950 if test "x$has_colon" = x; then 25951 # Not in mixed or Windows style, start by that. 25952 new_path=`cmd //c echo $path` 25953 fi 25954 25955 25956 input_path="$new_path" 25957 # Check if we need to convert this using DOS-style short mode. If the path 25958 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25959 # take no chances and rewrite it. 25960 # Note: m4 eats our [], so we need to use [ and ] instead. 25961 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25962 if test "x$has_forbidden_chars" != x; then 25963 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25964 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25965 fi 25966 25967 25968 windows_path="$new_path" 25969 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25970 unix_path=`$CYGPATH -u "$windows_path"` 25971 new_path="$unix_path" 25972 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25973 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25974 new_path="$unix_path" 25975 fi 25976 25977 if test "x$path" != "x$new_path"; then 25978 BOOT_JDK="$new_path" 25979 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25980 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25981 fi 25982 25983 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25984 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25985 25986 else 25987 # We're on a unix platform. Hooray! :) 25988 path="$BOOT_JDK" 25989 has_space=`$ECHO "$path" | $GREP " "` 25990 if test "x$has_space" != x; then 25991 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25992 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25993 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25994 fi 25995 25996 # Use eval to expand a potential ~ 25997 eval path="$path" 25998 if test ! -f "$path" && test ! -d "$path"; then 25999 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26000 fi 26001 26002 if test -d "$path"; then 26003 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26004 else 26005 dir="`$DIRNAME "$path"`" 26006 base="`$BASENAME "$path"`" 26007 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26008 fi 26009 fi 26010 fi 26011 26012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26013 $as_echo_n "checking for Boot JDK... " >&6; } 26014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26015 $as_echo "$BOOT_JDK" >&6; } 26016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26017 $as_echo_n "checking Boot JDK version... " >&6; } 26018 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26020 $as_echo "$BOOT_JDK_VERSION" >&6; } 26021 fi # end check jdk version 26022 fi # end check javac 26023 fi # end check java 26024 fi # end check boot jdk found 26025 fi 26026 26027 # If that did not work out (e.g. too old), try explicit versions instead 26028 26029 if test "x$BOOT_JDK_FOUND" = xno; then 26030 # Now execute the test 26031 26032 if test -x /usr/libexec/java_home; then 26033 BOOT_JDK=`/usr/libexec/java_home -v 1.9` 26034 BOOT_JDK_FOUND=maybe 26035 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5 26036 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;} 26037 fi 26038 26039 26040 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26041 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26042 # Do we have a bin/java? 26043 if test ! -x "$BOOT_JDK/bin/java"; then 26044 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26045 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26046 BOOT_JDK_FOUND=no 26047 else 26048 # Do we have a bin/javac? 26049 if test ! -x "$BOOT_JDK/bin/javac"; then 26050 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26051 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26052 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26053 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26054 BOOT_JDK_FOUND=no 26055 else 26056 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26057 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26058 26059 # Extra M4 quote needed to protect [] in grep expression. 26060 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 26061 if test "x$FOUND_CORRECT_VERSION" = x; then 26062 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26063 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26064 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 26065 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 26066 BOOT_JDK_FOUND=no 26067 else 26068 # We're done! :-) 26069 BOOT_JDK_FOUND=yes 26070 26071 # Only process if variable expands to non-empty 26072 26073 if test "x$BOOT_JDK" != x; then 26074 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26075 26076 # Input might be given as Windows format, start by converting to 26077 # unix format. 26078 path="$BOOT_JDK" 26079 new_path=`$CYGPATH -u "$path"` 26080 26081 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26082 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26083 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26084 # "foo.exe" is OK but "foo" is an error. 26085 # 26086 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26087 # It is also a way to make sure we got the proper file name for the real test later on. 26088 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26089 if test "x$test_shortpath" = x; then 26090 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26091 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26092 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26093 fi 26094 26095 # Call helper function which possibly converts this using DOS-style short mode. 26096 # If so, the updated path is stored in $new_path. 26097 26098 input_path="$new_path" 26099 # Check if we need to convert this using DOS-style short mode. If the path 26100 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26101 # take no chances and rewrite it. 26102 # Note: m4 eats our [], so we need to use [ and ] instead. 26103 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26104 if test "x$has_forbidden_chars" != x; then 26105 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26106 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26107 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26108 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26109 # Going to short mode and back again did indeed matter. Since short mode is 26110 # case insensitive, let's make it lowercase to improve readability. 26111 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26112 # Now convert it back to Unix-style (cygpath) 26113 input_path=`$CYGPATH -u "$shortmode_path"` 26114 new_path="$input_path" 26115 fi 26116 fi 26117 26118 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26119 if test "x$test_cygdrive_prefix" = x; then 26120 # As a simple fix, exclude /usr/bin since it's not a real path. 26121 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26122 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26123 # a path prefixed by /cygdrive for fixpath to work. 26124 new_path="$CYGWIN_ROOT_PATH$input_path" 26125 fi 26126 fi 26127 26128 26129 if test "x$path" != "x$new_path"; then 26130 BOOT_JDK="$new_path" 26131 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26132 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26133 fi 26134 26135 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26136 26137 path="$BOOT_JDK" 26138 has_colon=`$ECHO $path | $GREP ^.:` 26139 new_path="$path" 26140 if test "x$has_colon" = x; then 26141 # Not in mixed or Windows style, start by that. 26142 new_path=`cmd //c echo $path` 26143 fi 26144 26145 26146 input_path="$new_path" 26147 # Check if we need to convert this using DOS-style short mode. If the path 26148 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26149 # take no chances and rewrite it. 26150 # Note: m4 eats our [], so we need to use [ and ] instead. 26151 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26152 if test "x$has_forbidden_chars" != x; then 26153 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26154 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26155 fi 26156 26157 26158 windows_path="$new_path" 26159 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26160 unix_path=`$CYGPATH -u "$windows_path"` 26161 new_path="$unix_path" 26162 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26163 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26164 new_path="$unix_path" 26165 fi 26166 26167 if test "x$path" != "x$new_path"; then 26168 BOOT_JDK="$new_path" 26169 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26170 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26171 fi 26172 26173 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26174 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26175 26176 else 26177 # We're on a unix platform. Hooray! :) 26178 path="$BOOT_JDK" 26179 has_space=`$ECHO "$path" | $GREP " "` 26180 if test "x$has_space" != x; then 26181 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26182 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26183 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26184 fi 26185 26186 # Use eval to expand a potential ~ 26187 eval path="$path" 26188 if test ! -f "$path" && test ! -d "$path"; then 26189 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26190 fi 26191 26192 if test -d "$path"; then 26193 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26194 else 26195 dir="`$DIRNAME "$path"`" 26196 base="`$BASENAME "$path"`" 26197 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26198 fi 26199 fi 26200 fi 26201 26202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26203 $as_echo_n "checking for Boot JDK... " >&6; } 26204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26205 $as_echo "$BOOT_JDK" >&6; } 26206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26207 $as_echo_n "checking Boot JDK version... " >&6; } 26208 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26210 $as_echo "$BOOT_JDK_VERSION" >&6; } 26211 fi # end check jdk version 26212 fi # end check javac 26213 fi # end check java 26214 fi # end check boot jdk found 26215 fi 26216 26217 26218 if test "x$BOOT_JDK_FOUND" = xno; then 26219 # Now execute the test 26220 26221 if test -x /usr/libexec/java_home; then 26222 BOOT_JDK=`/usr/libexec/java_home -v 1.8` 26223 BOOT_JDK_FOUND=maybe 26224 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5 26225 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;} 26226 fi 26227 26228 26229 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26230 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26231 # Do we have a bin/java? 26232 if test ! -x "$BOOT_JDK/bin/java"; then 26233 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26234 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26235 BOOT_JDK_FOUND=no 26236 else 26237 # Do we have a bin/javac? 26238 if test ! -x "$BOOT_JDK/bin/javac"; then 26239 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26240 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26241 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26242 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26243 BOOT_JDK_FOUND=no 26244 else 26245 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26246 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26247 26248 # Extra M4 quote needed to protect [] in grep expression. 26249 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 26250 if test "x$FOUND_CORRECT_VERSION" = x; then 26251 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26252 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26253 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 26254 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 26255 BOOT_JDK_FOUND=no 26256 else 26257 # We're done! :-) 26258 BOOT_JDK_FOUND=yes 26259 26260 # Only process if variable expands to non-empty 26261 26262 if test "x$BOOT_JDK" != x; then 26263 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26264 26265 # Input might be given as Windows format, start by converting to 26266 # unix format. 26267 path="$BOOT_JDK" 26268 new_path=`$CYGPATH -u "$path"` 26269 26270 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26271 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26272 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26273 # "foo.exe" is OK but "foo" is an error. 26274 # 26275 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26276 # It is also a way to make sure we got the proper file name for the real test later on. 26277 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26278 if test "x$test_shortpath" = x; then 26279 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26280 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26281 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26282 fi 26283 26284 # Call helper function which possibly converts this using DOS-style short mode. 26285 # If so, the updated path is stored in $new_path. 26286 26287 input_path="$new_path" 26288 # Check if we need to convert this using DOS-style short mode. If the path 26289 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26290 # take no chances and rewrite it. 26291 # Note: m4 eats our [], so we need to use [ and ] instead. 26292 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26293 if test "x$has_forbidden_chars" != x; then 26294 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26295 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26296 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26297 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26298 # Going to short mode and back again did indeed matter. Since short mode is 26299 # case insensitive, let's make it lowercase to improve readability. 26300 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26301 # Now convert it back to Unix-style (cygpath) 26302 input_path=`$CYGPATH -u "$shortmode_path"` 26303 new_path="$input_path" 26304 fi 26305 fi 26306 26307 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26308 if test "x$test_cygdrive_prefix" = x; then 26309 # As a simple fix, exclude /usr/bin since it's not a real path. 26310 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26311 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26312 # a path prefixed by /cygdrive for fixpath to work. 26313 new_path="$CYGWIN_ROOT_PATH$input_path" 26314 fi 26315 fi 26316 26317 26318 if test "x$path" != "x$new_path"; then 26319 BOOT_JDK="$new_path" 26320 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26321 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26322 fi 26323 26324 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26325 26326 path="$BOOT_JDK" 26327 has_colon=`$ECHO $path | $GREP ^.:` 26328 new_path="$path" 26329 if test "x$has_colon" = x; then 26330 # Not in mixed or Windows style, start by that. 26331 new_path=`cmd //c echo $path` 26332 fi 26333 26334 26335 input_path="$new_path" 26336 # Check if we need to convert this using DOS-style short mode. If the path 26337 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26338 # take no chances and rewrite it. 26339 # Note: m4 eats our [], so we need to use [ and ] instead. 26340 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26341 if test "x$has_forbidden_chars" != x; then 26342 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26343 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26344 fi 26345 26346 26347 windows_path="$new_path" 26348 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26349 unix_path=`$CYGPATH -u "$windows_path"` 26350 new_path="$unix_path" 26351 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26352 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26353 new_path="$unix_path" 26354 fi 26355 26356 if test "x$path" != "x$new_path"; then 26357 BOOT_JDK="$new_path" 26358 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26359 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26360 fi 26361 26362 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26363 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26364 26365 else 26366 # We're on a unix platform. Hooray! :) 26367 path="$BOOT_JDK" 26368 has_space=`$ECHO "$path" | $GREP " "` 26369 if test "x$has_space" != x; then 26370 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26371 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26372 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26373 fi 26374 26375 # Use eval to expand a potential ~ 26376 eval path="$path" 26377 if test ! -f "$path" && test ! -d "$path"; then 26378 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26379 fi 26380 26381 if test -d "$path"; then 26382 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26383 else 26384 dir="`$DIRNAME "$path"`" 26385 base="`$BASENAME "$path"`" 26386 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26387 fi 26388 fi 26389 fi 26390 26391 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26392 $as_echo_n "checking for Boot JDK... " >&6; } 26393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26394 $as_echo "$BOOT_JDK" >&6; } 26395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26396 $as_echo_n "checking Boot JDK version... " >&6; } 26397 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26399 $as_echo "$BOOT_JDK_VERSION" >&6; } 26400 fi # end check jdk version 26401 fi # end check javac 26402 fi # end check java 26403 fi # end check boot jdk found 26404 fi 26405 26406 26407 if test "x$BOOT_JDK_FOUND" = xno; then 26408 # Now execute the test 26409 26410 if test -x /usr/libexec/java_home; then 26411 BOOT_JDK=`/usr/libexec/java_home -v 1.7` 26412 BOOT_JDK_FOUND=maybe 26413 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5 26414 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;} 26415 fi 26416 26417 26418 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26419 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26420 # Do we have a bin/java? 26421 if test ! -x "$BOOT_JDK/bin/java"; then 26422 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26423 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26424 BOOT_JDK_FOUND=no 26425 else 26426 # Do we have a bin/javac? 26427 if test ! -x "$BOOT_JDK/bin/javac"; then 26428 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26429 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26430 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26431 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26432 BOOT_JDK_FOUND=no 26433 else 26434 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26435 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26436 26437 # Extra M4 quote needed to protect [] in grep expression. 26438 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 26439 if test "x$FOUND_CORRECT_VERSION" = x; then 26440 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26441 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26442 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 26443 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 26444 BOOT_JDK_FOUND=no 26445 else 26446 # We're done! :-) 26447 BOOT_JDK_FOUND=yes 26448 26449 # Only process if variable expands to non-empty 26450 26451 if test "x$BOOT_JDK" != x; then 26452 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26453 26454 # Input might be given as Windows format, start by converting to 26455 # unix format. 26456 path="$BOOT_JDK" 26457 new_path=`$CYGPATH -u "$path"` 26458 26459 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26460 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26461 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26462 # "foo.exe" is OK but "foo" is an error. 26463 # 26464 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26465 # It is also a way to make sure we got the proper file name for the real test later on. 26466 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26467 if test "x$test_shortpath" = x; then 26468 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26469 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26470 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26471 fi 26472 26473 # Call helper function which possibly converts this using DOS-style short mode. 26474 # If so, the updated path is stored in $new_path. 26475 26476 input_path="$new_path" 26477 # Check if we need to convert this using DOS-style short mode. If the path 26478 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26479 # take no chances and rewrite it. 26480 # Note: m4 eats our [], so we need to use [ and ] instead. 26481 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26482 if test "x$has_forbidden_chars" != x; then 26483 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26484 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26485 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26486 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26487 # Going to short mode and back again did indeed matter. Since short mode is 26488 # case insensitive, let's make it lowercase to improve readability. 26489 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26490 # Now convert it back to Unix-style (cygpath) 26491 input_path=`$CYGPATH -u "$shortmode_path"` 26492 new_path="$input_path" 26493 fi 26494 fi 26495 26496 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26497 if test "x$test_cygdrive_prefix" = x; then 26498 # As a simple fix, exclude /usr/bin since it's not a real path. 26499 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26500 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26501 # a path prefixed by /cygdrive for fixpath to work. 26502 new_path="$CYGWIN_ROOT_PATH$input_path" 26503 fi 26504 fi 26505 26506 26507 if test "x$path" != "x$new_path"; then 26508 BOOT_JDK="$new_path" 26509 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26510 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26511 fi 26512 26513 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26514 26515 path="$BOOT_JDK" 26516 has_colon=`$ECHO $path | $GREP ^.:` 26517 new_path="$path" 26518 if test "x$has_colon" = x; then 26519 # Not in mixed or Windows style, start by that. 26520 new_path=`cmd //c echo $path` 26521 fi 26522 26523 26524 input_path="$new_path" 26525 # Check if we need to convert this using DOS-style short mode. If the path 26526 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26527 # take no chances and rewrite it. 26528 # Note: m4 eats our [], so we need to use [ and ] instead. 26529 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26530 if test "x$has_forbidden_chars" != x; then 26531 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26532 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26533 fi 26534 26535 26536 windows_path="$new_path" 26537 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26538 unix_path=`$CYGPATH -u "$windows_path"` 26539 new_path="$unix_path" 26540 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26541 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26542 new_path="$unix_path" 26543 fi 26544 26545 if test "x$path" != "x$new_path"; then 26546 BOOT_JDK="$new_path" 26547 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26548 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26549 fi 26550 26551 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26552 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26553 26554 else 26555 # We're on a unix platform. Hooray! :) 26556 path="$BOOT_JDK" 26557 has_space=`$ECHO "$path" | $GREP " "` 26558 if test "x$has_space" != x; then 26559 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26560 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26561 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26562 fi 26563 26564 # Use eval to expand a potential ~ 26565 eval path="$path" 26566 if test ! -f "$path" && test ! -d "$path"; then 26567 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26568 fi 26569 26570 if test -d "$path"; then 26571 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26572 else 26573 dir="`$DIRNAME "$path"`" 26574 base="`$BASENAME "$path"`" 26575 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26576 fi 26577 fi 26578 fi 26579 26580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26581 $as_echo_n "checking for Boot JDK... " >&6; } 26582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26583 $as_echo "$BOOT_JDK" >&6; } 26584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26585 $as_echo_n "checking Boot JDK version... " >&6; } 26586 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26588 $as_echo "$BOOT_JDK_VERSION" >&6; } 26589 fi # end check jdk version 26590 fi # end check javac 26591 fi # end check java 26592 fi # end check boot jdk found 26593 fi 26594 26595 fi 26596 26597 26598 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26599 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26600 # Do we have a bin/java? 26601 if test ! -x "$BOOT_JDK/bin/java"; then 26602 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26603 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26604 BOOT_JDK_FOUND=no 26605 else 26606 # Do we have a bin/javac? 26607 if test ! -x "$BOOT_JDK/bin/javac"; then 26608 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26609 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26610 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26611 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26612 BOOT_JDK_FOUND=no 26613 else 26614 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26615 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26616 26617 # Extra M4 quote needed to protect [] in grep expression. 26618 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 26619 if test "x$FOUND_CORRECT_VERSION" = x; then 26620 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26621 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26622 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 26623 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 26624 BOOT_JDK_FOUND=no 26625 else 26626 # We're done! :-) 26627 BOOT_JDK_FOUND=yes 26628 26629 # Only process if variable expands to non-empty 26630 26631 if test "x$BOOT_JDK" != x; then 26632 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26633 26634 # Input might be given as Windows format, start by converting to 26635 # unix format. 26636 path="$BOOT_JDK" 26637 new_path=`$CYGPATH -u "$path"` 26638 26639 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26640 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26641 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26642 # "foo.exe" is OK but "foo" is an error. 26643 # 26644 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26645 # It is also a way to make sure we got the proper file name for the real test later on. 26646 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26647 if test "x$test_shortpath" = x; then 26648 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26649 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26650 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26651 fi 26652 26653 # Call helper function which possibly converts this using DOS-style short mode. 26654 # If so, the updated path is stored in $new_path. 26655 26656 input_path="$new_path" 26657 # Check if we need to convert this using DOS-style short mode. If the path 26658 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26659 # take no chances and rewrite it. 26660 # Note: m4 eats our [], so we need to use [ and ] instead. 26661 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26662 if test "x$has_forbidden_chars" != x; then 26663 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26664 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26665 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26666 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26667 # Going to short mode and back again did indeed matter. Since short mode is 26668 # case insensitive, let's make it lowercase to improve readability. 26669 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26670 # Now convert it back to Unix-style (cygpath) 26671 input_path=`$CYGPATH -u "$shortmode_path"` 26672 new_path="$input_path" 26673 fi 26674 fi 26675 26676 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26677 if test "x$test_cygdrive_prefix" = x; then 26678 # As a simple fix, exclude /usr/bin since it's not a real path. 26679 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26680 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26681 # a path prefixed by /cygdrive for fixpath to work. 26682 new_path="$CYGWIN_ROOT_PATH$input_path" 26683 fi 26684 fi 26685 26686 26687 if test "x$path" != "x$new_path"; then 26688 BOOT_JDK="$new_path" 26689 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26690 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26691 fi 26692 26693 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26694 26695 path="$BOOT_JDK" 26696 has_colon=`$ECHO $path | $GREP ^.:` 26697 new_path="$path" 26698 if test "x$has_colon" = x; then 26699 # Not in mixed or Windows style, start by that. 26700 new_path=`cmd //c echo $path` 26701 fi 26702 26703 26704 input_path="$new_path" 26705 # Check if we need to convert this using DOS-style short mode. If the path 26706 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26707 # take no chances and rewrite it. 26708 # Note: m4 eats our [], so we need to use [ and ] instead. 26709 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26710 if test "x$has_forbidden_chars" != x; then 26711 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26712 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26713 fi 26714 26715 26716 windows_path="$new_path" 26717 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26718 unix_path=`$CYGPATH -u "$windows_path"` 26719 new_path="$unix_path" 26720 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26721 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26722 new_path="$unix_path" 26723 fi 26724 26725 if test "x$path" != "x$new_path"; then 26726 BOOT_JDK="$new_path" 26727 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26728 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26729 fi 26730 26731 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26732 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26733 26734 else 26735 # We're on a unix platform. Hooray! :) 26736 path="$BOOT_JDK" 26737 has_space=`$ECHO "$path" | $GREP " "` 26738 if test "x$has_space" != x; then 26739 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26740 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26741 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26742 fi 26743 26744 # Use eval to expand a potential ~ 26745 eval path="$path" 26746 if test ! -f "$path" && test ! -d "$path"; then 26747 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26748 fi 26749 26750 if test -d "$path"; then 26751 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26752 else 26753 dir="`$DIRNAME "$path"`" 26754 base="`$BASENAME "$path"`" 26755 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26756 fi 26757 fi 26758 fi 26759 26760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26761 $as_echo_n "checking for Boot JDK... " >&6; } 26762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26763 $as_echo "$BOOT_JDK" >&6; } 26764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26765 $as_echo_n "checking Boot JDK version... " >&6; } 26766 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26768 $as_echo "$BOOT_JDK_VERSION" >&6; } 26769 fi # end check jdk version 26770 fi # end check javac 26771 fi # end check java 26772 fi # end check boot jdk found 26773 fi 26774 26775 26776 # Test: Is $JAVA_HOME set? 26777 26778 if test "x$BOOT_JDK_FOUND" = xno; then 26779 # Now execute the test 26780 26781 if test "x$JAVA_HOME" != x; then 26782 JAVA_HOME_PROCESSED="$JAVA_HOME" 26783 26784 # Only process if variable expands to non-empty 26785 26786 if test "x$JAVA_HOME_PROCESSED" != x; then 26787 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26788 26789 # Input might be given as Windows format, start by converting to 26790 # unix format. 26791 path="$JAVA_HOME_PROCESSED" 26792 new_path=`$CYGPATH -u "$path"` 26793 26794 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26795 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26796 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26797 # "foo.exe" is OK but "foo" is an error. 26798 # 26799 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26800 # It is also a way to make sure we got the proper file name for the real test later on. 26801 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26802 if test "x$test_shortpath" = x; then 26803 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26804 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26805 as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5 26806 fi 26807 26808 # Call helper function which possibly converts this using DOS-style short mode. 26809 # If so, the updated path is stored in $new_path. 26810 26811 input_path="$new_path" 26812 # Check if we need to convert this using DOS-style short mode. If the path 26813 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26814 # take no chances and rewrite it. 26815 # Note: m4 eats our [], so we need to use [ and ] instead. 26816 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26817 if test "x$has_forbidden_chars" != x; then 26818 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26819 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26820 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26821 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26822 # Going to short mode and back again did indeed matter. Since short mode is 26823 # case insensitive, let's make it lowercase to improve readability. 26824 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26825 # Now convert it back to Unix-style (cygpath) 26826 input_path=`$CYGPATH -u "$shortmode_path"` 26827 new_path="$input_path" 26828 fi 26829 fi 26830 26831 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26832 if test "x$test_cygdrive_prefix" = x; then 26833 # As a simple fix, exclude /usr/bin since it's not a real path. 26834 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26835 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26836 # a path prefixed by /cygdrive for fixpath to work. 26837 new_path="$CYGWIN_ROOT_PATH$input_path" 26838 fi 26839 fi 26840 26841 26842 if test "x$path" != "x$new_path"; then 26843 JAVA_HOME_PROCESSED="$new_path" 26844 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26845 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26846 fi 26847 26848 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26849 26850 path="$JAVA_HOME_PROCESSED" 26851 has_colon=`$ECHO $path | $GREP ^.:` 26852 new_path="$path" 26853 if test "x$has_colon" = x; then 26854 # Not in mixed or Windows style, start by that. 26855 new_path=`cmd //c echo $path` 26856 fi 26857 26858 26859 input_path="$new_path" 26860 # Check if we need to convert this using DOS-style short mode. If the path 26861 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26862 # take no chances and rewrite it. 26863 # Note: m4 eats our [], so we need to use [ and ] instead. 26864 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26865 if test "x$has_forbidden_chars" != x; then 26866 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26867 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26868 fi 26869 26870 26871 windows_path="$new_path" 26872 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26873 unix_path=`$CYGPATH -u "$windows_path"` 26874 new_path="$unix_path" 26875 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26876 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26877 new_path="$unix_path" 26878 fi 26879 26880 if test "x$path" != "x$new_path"; then 26881 JAVA_HOME_PROCESSED="$new_path" 26882 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26883 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26884 fi 26885 26886 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26887 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26888 26889 else 26890 # We're on a unix platform. Hooray! :) 26891 path="$JAVA_HOME_PROCESSED" 26892 has_space=`$ECHO "$path" | $GREP " "` 26893 if test "x$has_space" != x; then 26894 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26895 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26896 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26897 fi 26898 26899 # Use eval to expand a potential ~ 26900 eval path="$path" 26901 if test ! -f "$path" && test ! -d "$path"; then 26902 as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5 26903 fi 26904 26905 if test -d "$path"; then 26906 JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`" 26907 else 26908 dir="`$DIRNAME "$path"`" 26909 base="`$BASENAME "$path"`" 26910 JAVA_HOME_PROCESSED="`cd "$dir"; $THEPWDCMD -L`/$base" 26911 fi 26912 fi 26913 fi 26914 26915 if test ! -d "$JAVA_HOME_PROCESSED"; then 26916 { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5 26917 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;} 26918 else 26919 # Aha, the user has set a JAVA_HOME 26920 # let us use that as the Boot JDK. 26921 BOOT_JDK="$JAVA_HOME_PROCESSED" 26922 BOOT_JDK_FOUND=maybe 26923 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5 26924 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;} 26925 fi 26926 fi 26927 26928 26929 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26930 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26931 # Do we have a bin/java? 26932 if test ! -x "$BOOT_JDK/bin/java"; then 26933 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26934 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26935 BOOT_JDK_FOUND=no 26936 else 26937 # Do we have a bin/javac? 26938 if test ! -x "$BOOT_JDK/bin/javac"; then 26939 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26940 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26941 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26942 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26943 BOOT_JDK_FOUND=no 26944 else 26945 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26946 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26947 26948 # Extra M4 quote needed to protect [] in grep expression. 26949 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 26950 if test "x$FOUND_CORRECT_VERSION" = x; then 26951 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26952 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26953 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 26954 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 26955 BOOT_JDK_FOUND=no 26956 else 26957 # We're done! :-) 26958 BOOT_JDK_FOUND=yes 26959 26960 # Only process if variable expands to non-empty 26961 26962 if test "x$BOOT_JDK" != x; then 26963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26964 26965 # Input might be given as Windows format, start by converting to 26966 # unix format. 26967 path="$BOOT_JDK" 26968 new_path=`$CYGPATH -u "$path"` 26969 26970 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26971 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26972 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26973 # "foo.exe" is OK but "foo" is an error. 26974 # 26975 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26976 # It is also a way to make sure we got the proper file name for the real test later on. 26977 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26978 if test "x$test_shortpath" = x; then 26979 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26980 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26981 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26982 fi 26983 26984 # Call helper function which possibly converts this using DOS-style short mode. 26985 # If so, the updated path is stored in $new_path. 26986 26987 input_path="$new_path" 26988 # Check if we need to convert this using DOS-style short mode. If the path 26989 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26990 # take no chances and rewrite it. 26991 # Note: m4 eats our [], so we need to use [ and ] instead. 26992 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26993 if test "x$has_forbidden_chars" != x; then 26994 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26995 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26996 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26997 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26998 # Going to short mode and back again did indeed matter. Since short mode is 26999 # case insensitive, let's make it lowercase to improve readability. 27000 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27001 # Now convert it back to Unix-style (cygpath) 27002 input_path=`$CYGPATH -u "$shortmode_path"` 27003 new_path="$input_path" 27004 fi 27005 fi 27006 27007 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27008 if test "x$test_cygdrive_prefix" = x; then 27009 # As a simple fix, exclude /usr/bin since it's not a real path. 27010 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27011 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27012 # a path prefixed by /cygdrive for fixpath to work. 27013 new_path="$CYGWIN_ROOT_PATH$input_path" 27014 fi 27015 fi 27016 27017 27018 if test "x$path" != "x$new_path"; then 27019 BOOT_JDK="$new_path" 27020 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27021 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27022 fi 27023 27024 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27025 27026 path="$BOOT_JDK" 27027 has_colon=`$ECHO $path | $GREP ^.:` 27028 new_path="$path" 27029 if test "x$has_colon" = x; then 27030 # Not in mixed or Windows style, start by that. 27031 new_path=`cmd //c echo $path` 27032 fi 27033 27034 27035 input_path="$new_path" 27036 # Check if we need to convert this using DOS-style short mode. If the path 27037 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27038 # take no chances and rewrite it. 27039 # Note: m4 eats our [], so we need to use [ and ] instead. 27040 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27041 if test "x$has_forbidden_chars" != x; then 27042 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27043 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27044 fi 27045 27046 27047 windows_path="$new_path" 27048 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27049 unix_path=`$CYGPATH -u "$windows_path"` 27050 new_path="$unix_path" 27051 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27052 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27053 new_path="$unix_path" 27054 fi 27055 27056 if test "x$path" != "x$new_path"; then 27057 BOOT_JDK="$new_path" 27058 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27059 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27060 fi 27061 27062 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27063 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27064 27065 else 27066 # We're on a unix platform. Hooray! :) 27067 path="$BOOT_JDK" 27068 has_space=`$ECHO "$path" | $GREP " "` 27069 if test "x$has_space" != x; then 27070 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27071 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27072 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27073 fi 27074 27075 # Use eval to expand a potential ~ 27076 eval path="$path" 27077 if test ! -f "$path" && test ! -d "$path"; then 27078 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27079 fi 27080 27081 if test -d "$path"; then 27082 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27083 else 27084 dir="`$DIRNAME "$path"`" 27085 base="`$BASENAME "$path"`" 27086 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27087 fi 27088 fi 27089 fi 27090 27091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27092 $as_echo_n "checking for Boot JDK... " >&6; } 27093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27094 $as_echo "$BOOT_JDK" >&6; } 27095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27096 $as_echo_n "checking Boot JDK version... " >&6; } 27097 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27099 $as_echo "$BOOT_JDK_VERSION" >&6; } 27100 fi # end check jdk version 27101 fi # end check javac 27102 fi # end check java 27103 fi # end check boot jdk found 27104 fi 27105 27106 27107 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 27108 27109 if test "x$BOOT_JDK_FOUND" = xno; then 27110 # Now execute the test 27111 27112 # Extract the first word of "javac", so it can be a program name with args. 27113 set dummy javac; ac_word=$2 27114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27115 $as_echo_n "checking for $ac_word... " >&6; } 27116 if ${ac_cv_path_JAVAC_CHECK+:} false; then : 27117 $as_echo_n "(cached) " >&6 27118 else 27119 case $JAVAC_CHECK in 27120 [\\/]* | ?:[\\/]*) 27121 ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path. 27122 ;; 27123 *) 27124 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27125 for as_dir in $PATH 27126 do 27127 IFS=$as_save_IFS 27128 test -z "$as_dir" && as_dir=. 27129 for ac_exec_ext in '' $ac_executable_extensions; do 27130 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 27131 ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext" 27132 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27133 break 2 27134 fi 27135 done 27136 done 27137 IFS=$as_save_IFS 27138 27139 ;; 27140 esac 27141 fi 27142 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK 27143 if test -n "$JAVAC_CHECK"; then 27144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5 27145 $as_echo "$JAVAC_CHECK" >&6; } 27146 else 27147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27148 $as_echo "no" >&6; } 27149 fi 27150 27151 27152 # Extract the first word of "java", so it can be a program name with args. 27153 set dummy java; ac_word=$2 27154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27155 $as_echo_n "checking for $ac_word... " >&6; } 27156 if ${ac_cv_path_JAVA_CHECK+:} false; then : 27157 $as_echo_n "(cached) " >&6 27158 else 27159 case $JAVA_CHECK in 27160 [\\/]* | ?:[\\/]*) 27161 ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path. 27162 ;; 27163 *) 27164 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27165 for as_dir in $PATH 27166 do 27167 IFS=$as_save_IFS 27168 test -z "$as_dir" && as_dir=. 27169 for ac_exec_ext in '' $ac_executable_extensions; do 27170 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 27171 ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext" 27172 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27173 break 2 27174 fi 27175 done 27176 done 27177 IFS=$as_save_IFS 27178 27179 ;; 27180 esac 27181 fi 27182 JAVA_CHECK=$ac_cv_path_JAVA_CHECK 27183 if test -n "$JAVA_CHECK"; then 27184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5 27185 $as_echo "$JAVA_CHECK" >&6; } 27186 else 27187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27188 $as_echo "no" >&6; } 27189 fi 27190 27191 27192 BINARY="$JAVAC_CHECK" 27193 if test "x$JAVAC_CHECK" = x; then 27194 BINARY="$JAVA_CHECK" 27195 fi 27196 if test "x$BINARY" != x; then 27197 # So there is a java(c) binary, it might be part of a JDK. 27198 # Lets find the JDK/JRE directory by following symbolic links. 27199 # Linux/GNU systems often have links from /usr/bin/java to 27200 # /etc/alternatives/java to the real JDK binary. 27201 27202 if test "x$OPENJDK_BUILD_OS" != xwindows; then 27203 # Follow a chain of symbolic links. Use readlink 27204 # where it exists, else fall back to horribly 27205 # complicated shell code. 27206 if test "x$READLINK_TESTED" != yes; then 27207 # On MacOSX there is a readlink tool with a different 27208 # purpose than the GNU readlink tool. Check the found readlink. 27209 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 27210 if test "x$ISGNU" = x; then 27211 # A readlink that we do not know how to use. 27212 # Are there other non-GNU readlinks out there? 27213 READLINK_TESTED=yes 27214 READLINK= 27215 fi 27216 fi 27217 27218 if test "x$READLINK" != x; then 27219 BINARY=`$READLINK -f $BINARY` 27220 else 27221 # Save the current directory for restoring afterwards 27222 STARTDIR=$PWD 27223 COUNTER=0 27224 sym_link_dir=`$DIRNAME $BINARY` 27225 sym_link_file=`$BASENAME $BINARY` 27226 cd $sym_link_dir 27227 # Use -P flag to resolve symlinks in directories. 27228 cd `$THEPWDCMD -P` 27229 sym_link_dir=`$THEPWDCMD -P` 27230 # Resolve file symlinks 27231 while test $COUNTER -lt 20; do 27232 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 27233 if test "x$ISLINK" == x; then 27234 # This is not a symbolic link! We are done! 27235 break 27236 fi 27237 # Again resolve directory symlinks since the target of the just found 27238 # link could be in a different directory 27239 cd `$DIRNAME $ISLINK` 27240 sym_link_dir=`$THEPWDCMD -P` 27241 sym_link_file=`$BASENAME $ISLINK` 27242 let COUNTER=COUNTER+1 27243 done 27244 cd $STARTDIR 27245 BINARY=$sym_link_dir/$sym_link_file 27246 fi 27247 fi 27248 27249 BOOT_JDK=`dirname "$BINARY"` 27250 BOOT_JDK=`cd "$BOOT_JDK/.."; pwd` 27251 if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then 27252 # Looks like we found ourselves an JDK 27253 BOOT_JDK_FOUND=maybe 27254 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5 27255 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;} 27256 fi 27257 fi 27258 27259 27260 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27261 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27262 # Do we have a bin/java? 27263 if test ! -x "$BOOT_JDK/bin/java"; then 27264 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27265 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27266 BOOT_JDK_FOUND=no 27267 else 27268 # Do we have a bin/javac? 27269 if test ! -x "$BOOT_JDK/bin/javac"; then 27270 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27271 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27272 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27273 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27274 BOOT_JDK_FOUND=no 27275 else 27276 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27277 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27278 27279 # Extra M4 quote needed to protect [] in grep expression. 27280 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 27281 if test "x$FOUND_CORRECT_VERSION" = x; then 27282 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27283 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27284 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 27285 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 27286 BOOT_JDK_FOUND=no 27287 else 27288 # We're done! :-) 27289 BOOT_JDK_FOUND=yes 27290 27291 # Only process if variable expands to non-empty 27292 27293 if test "x$BOOT_JDK" != x; then 27294 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27295 27296 # Input might be given as Windows format, start by converting to 27297 # unix format. 27298 path="$BOOT_JDK" 27299 new_path=`$CYGPATH -u "$path"` 27300 27301 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27302 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27303 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27304 # "foo.exe" is OK but "foo" is an error. 27305 # 27306 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27307 # It is also a way to make sure we got the proper file name for the real test later on. 27308 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27309 if test "x$test_shortpath" = x; then 27310 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27311 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27312 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27313 fi 27314 27315 # Call helper function which possibly converts this using DOS-style short mode. 27316 # If so, the updated path is stored in $new_path. 27317 27318 input_path="$new_path" 27319 # Check if we need to convert this using DOS-style short mode. If the path 27320 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27321 # take no chances and rewrite it. 27322 # Note: m4 eats our [], so we need to use [ and ] instead. 27323 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27324 if test "x$has_forbidden_chars" != x; then 27325 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27326 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27327 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27328 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27329 # Going to short mode and back again did indeed matter. Since short mode is 27330 # case insensitive, let's make it lowercase to improve readability. 27331 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27332 # Now convert it back to Unix-style (cygpath) 27333 input_path=`$CYGPATH -u "$shortmode_path"` 27334 new_path="$input_path" 27335 fi 27336 fi 27337 27338 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27339 if test "x$test_cygdrive_prefix" = x; then 27340 # As a simple fix, exclude /usr/bin since it's not a real path. 27341 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27342 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27343 # a path prefixed by /cygdrive for fixpath to work. 27344 new_path="$CYGWIN_ROOT_PATH$input_path" 27345 fi 27346 fi 27347 27348 27349 if test "x$path" != "x$new_path"; then 27350 BOOT_JDK="$new_path" 27351 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27352 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27353 fi 27354 27355 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27356 27357 path="$BOOT_JDK" 27358 has_colon=`$ECHO $path | $GREP ^.:` 27359 new_path="$path" 27360 if test "x$has_colon" = x; then 27361 # Not in mixed or Windows style, start by that. 27362 new_path=`cmd //c echo $path` 27363 fi 27364 27365 27366 input_path="$new_path" 27367 # Check if we need to convert this using DOS-style short mode. If the path 27368 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27369 # take no chances and rewrite it. 27370 # Note: m4 eats our [], so we need to use [ and ] instead. 27371 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27372 if test "x$has_forbidden_chars" != x; then 27373 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27374 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27375 fi 27376 27377 27378 windows_path="$new_path" 27379 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27380 unix_path=`$CYGPATH -u "$windows_path"` 27381 new_path="$unix_path" 27382 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27383 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27384 new_path="$unix_path" 27385 fi 27386 27387 if test "x$path" != "x$new_path"; then 27388 BOOT_JDK="$new_path" 27389 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27390 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27391 fi 27392 27393 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27394 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27395 27396 else 27397 # We're on a unix platform. Hooray! :) 27398 path="$BOOT_JDK" 27399 has_space=`$ECHO "$path" | $GREP " "` 27400 if test "x$has_space" != x; then 27401 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27402 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27403 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27404 fi 27405 27406 # Use eval to expand a potential ~ 27407 eval path="$path" 27408 if test ! -f "$path" && test ! -d "$path"; then 27409 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27410 fi 27411 27412 if test -d "$path"; then 27413 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27414 else 27415 dir="`$DIRNAME "$path"`" 27416 base="`$BASENAME "$path"`" 27417 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27418 fi 27419 fi 27420 fi 27421 27422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27423 $as_echo_n "checking for Boot JDK... " >&6; } 27424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27425 $as_echo "$BOOT_JDK" >&6; } 27426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27427 $as_echo_n "checking Boot JDK version... " >&6; } 27428 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27430 $as_echo "$BOOT_JDK_VERSION" >&6; } 27431 fi # end check jdk version 27432 fi # end check javac 27433 fi # end check java 27434 fi # end check boot jdk found 27435 fi 27436 27437 27438 # Test: Is there a JDK installed in default, well-known locations? 27439 27440 if test "x$BOOT_JDK_FOUND" = xno; then 27441 # Now execute the test 27442 27443 if test "x$OPENJDK_TARGET_OS" = xwindows; then 27444 27445 if test "x$BOOT_JDK_FOUND" = xno; then 27446 # Now execute the test 27447 27448 if test "x$ProgramW6432" != x; then 27449 VIRTUAL_DIR="$ProgramW6432/Java" 27450 27451 windows_path="$VIRTUAL_DIR" 27452 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27453 unix_path=`$CYGPATH -u "$windows_path"` 27454 VIRTUAL_DIR="$unix_path" 27455 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27456 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27457 VIRTUAL_DIR="$unix_path" 27458 fi 27459 27460 27461 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27462 BOOT_JDK_SUFFIX="" 27463 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27464 if test "x$ALL_JDKS_FOUND" != x; then 27465 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27466 27467 if test "x$BOOT_JDK_FOUND" = xno; then 27468 # Now execute the test 27469 27470 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27471 if test -d "$BOOT_JDK"; then 27472 BOOT_JDK_FOUND=maybe 27473 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27474 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27475 fi 27476 27477 27478 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27479 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27480 # Do we have a bin/java? 27481 if test ! -x "$BOOT_JDK/bin/java"; then 27482 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27483 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27484 BOOT_JDK_FOUND=no 27485 else 27486 # Do we have a bin/javac? 27487 if test ! -x "$BOOT_JDK/bin/javac"; then 27488 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27489 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27490 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27491 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27492 BOOT_JDK_FOUND=no 27493 else 27494 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27495 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27496 27497 # Extra M4 quote needed to protect [] in grep expression. 27498 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 27499 if test "x$FOUND_CORRECT_VERSION" = x; then 27500 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27501 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27502 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 27503 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 27504 BOOT_JDK_FOUND=no 27505 else 27506 # We're done! :-) 27507 BOOT_JDK_FOUND=yes 27508 27509 # Only process if variable expands to non-empty 27510 27511 if test "x$BOOT_JDK" != x; then 27512 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27513 27514 # Input might be given as Windows format, start by converting to 27515 # unix format. 27516 path="$BOOT_JDK" 27517 new_path=`$CYGPATH -u "$path"` 27518 27519 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27520 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27521 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27522 # "foo.exe" is OK but "foo" is an error. 27523 # 27524 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27525 # It is also a way to make sure we got the proper file name for the real test later on. 27526 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27527 if test "x$test_shortpath" = x; then 27528 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27529 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27530 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27531 fi 27532 27533 # Call helper function which possibly converts this using DOS-style short mode. 27534 # If so, the updated path is stored in $new_path. 27535 27536 input_path="$new_path" 27537 # Check if we need to convert this using DOS-style short mode. If the path 27538 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27539 # take no chances and rewrite it. 27540 # Note: m4 eats our [], so we need to use [ and ] instead. 27541 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27542 if test "x$has_forbidden_chars" != x; then 27543 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27544 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27545 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27546 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27547 # Going to short mode and back again did indeed matter. Since short mode is 27548 # case insensitive, let's make it lowercase to improve readability. 27549 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27550 # Now convert it back to Unix-style (cygpath) 27551 input_path=`$CYGPATH -u "$shortmode_path"` 27552 new_path="$input_path" 27553 fi 27554 fi 27555 27556 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27557 if test "x$test_cygdrive_prefix" = x; then 27558 # As a simple fix, exclude /usr/bin since it's not a real path. 27559 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27560 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27561 # a path prefixed by /cygdrive for fixpath to work. 27562 new_path="$CYGWIN_ROOT_PATH$input_path" 27563 fi 27564 fi 27565 27566 27567 if test "x$path" != "x$new_path"; then 27568 BOOT_JDK="$new_path" 27569 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27570 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27571 fi 27572 27573 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27574 27575 path="$BOOT_JDK" 27576 has_colon=`$ECHO $path | $GREP ^.:` 27577 new_path="$path" 27578 if test "x$has_colon" = x; then 27579 # Not in mixed or Windows style, start by that. 27580 new_path=`cmd //c echo $path` 27581 fi 27582 27583 27584 input_path="$new_path" 27585 # Check if we need to convert this using DOS-style short mode. If the path 27586 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27587 # take no chances and rewrite it. 27588 # Note: m4 eats our [], so we need to use [ and ] instead. 27589 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27590 if test "x$has_forbidden_chars" != x; then 27591 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27592 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27593 fi 27594 27595 27596 windows_path="$new_path" 27597 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27598 unix_path=`$CYGPATH -u "$windows_path"` 27599 new_path="$unix_path" 27600 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27601 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27602 new_path="$unix_path" 27603 fi 27604 27605 if test "x$path" != "x$new_path"; then 27606 BOOT_JDK="$new_path" 27607 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27608 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27609 fi 27610 27611 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27612 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27613 27614 else 27615 # We're on a unix platform. Hooray! :) 27616 path="$BOOT_JDK" 27617 has_space=`$ECHO "$path" | $GREP " "` 27618 if test "x$has_space" != x; then 27619 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27620 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27621 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27622 fi 27623 27624 # Use eval to expand a potential ~ 27625 eval path="$path" 27626 if test ! -f "$path" && test ! -d "$path"; then 27627 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27628 fi 27629 27630 if test -d "$path"; then 27631 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27632 else 27633 dir="`$DIRNAME "$path"`" 27634 base="`$BASENAME "$path"`" 27635 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27636 fi 27637 fi 27638 fi 27639 27640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27641 $as_echo_n "checking for Boot JDK... " >&6; } 27642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27643 $as_echo "$BOOT_JDK" >&6; } 27644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27645 $as_echo_n "checking Boot JDK version... " >&6; } 27646 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27648 $as_echo "$BOOT_JDK_VERSION" >&6; } 27649 fi # end check jdk version 27650 fi # end check javac 27651 fi # end check java 27652 fi # end check boot jdk found 27653 fi 27654 27655 done 27656 fi 27657 27658 fi 27659 27660 27661 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27662 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27663 # Do we have a bin/java? 27664 if test ! -x "$BOOT_JDK/bin/java"; then 27665 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27666 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27667 BOOT_JDK_FOUND=no 27668 else 27669 # Do we have a bin/javac? 27670 if test ! -x "$BOOT_JDK/bin/javac"; then 27671 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27672 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27673 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27674 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27675 BOOT_JDK_FOUND=no 27676 else 27677 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27678 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27679 27680 # Extra M4 quote needed to protect [] in grep expression. 27681 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 27682 if test "x$FOUND_CORRECT_VERSION" = x; then 27683 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27684 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27685 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 27686 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 27687 BOOT_JDK_FOUND=no 27688 else 27689 # We're done! :-) 27690 BOOT_JDK_FOUND=yes 27691 27692 # Only process if variable expands to non-empty 27693 27694 if test "x$BOOT_JDK" != x; then 27695 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27696 27697 # Input might be given as Windows format, start by converting to 27698 # unix format. 27699 path="$BOOT_JDK" 27700 new_path=`$CYGPATH -u "$path"` 27701 27702 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27703 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27704 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27705 # "foo.exe" is OK but "foo" is an error. 27706 # 27707 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27708 # It is also a way to make sure we got the proper file name for the real test later on. 27709 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27710 if test "x$test_shortpath" = x; then 27711 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27712 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27713 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27714 fi 27715 27716 # Call helper function which possibly converts this using DOS-style short mode. 27717 # If so, the updated path is stored in $new_path. 27718 27719 input_path="$new_path" 27720 # Check if we need to convert this using DOS-style short mode. If the path 27721 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27722 # take no chances and rewrite it. 27723 # Note: m4 eats our [], so we need to use [ and ] instead. 27724 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27725 if test "x$has_forbidden_chars" != x; then 27726 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27727 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27728 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27729 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27730 # Going to short mode and back again did indeed matter. Since short mode is 27731 # case insensitive, let's make it lowercase to improve readability. 27732 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27733 # Now convert it back to Unix-style (cygpath) 27734 input_path=`$CYGPATH -u "$shortmode_path"` 27735 new_path="$input_path" 27736 fi 27737 fi 27738 27739 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27740 if test "x$test_cygdrive_prefix" = x; then 27741 # As a simple fix, exclude /usr/bin since it's not a real path. 27742 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27743 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27744 # a path prefixed by /cygdrive for fixpath to work. 27745 new_path="$CYGWIN_ROOT_PATH$input_path" 27746 fi 27747 fi 27748 27749 27750 if test "x$path" != "x$new_path"; then 27751 BOOT_JDK="$new_path" 27752 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27753 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27754 fi 27755 27756 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27757 27758 path="$BOOT_JDK" 27759 has_colon=`$ECHO $path | $GREP ^.:` 27760 new_path="$path" 27761 if test "x$has_colon" = x; then 27762 # Not in mixed or Windows style, start by that. 27763 new_path=`cmd //c echo $path` 27764 fi 27765 27766 27767 input_path="$new_path" 27768 # Check if we need to convert this using DOS-style short mode. If the path 27769 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27770 # take no chances and rewrite it. 27771 # Note: m4 eats our [], so we need to use [ and ] instead. 27772 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27773 if test "x$has_forbidden_chars" != x; then 27774 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27775 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27776 fi 27777 27778 27779 windows_path="$new_path" 27780 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27781 unix_path=`$CYGPATH -u "$windows_path"` 27782 new_path="$unix_path" 27783 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27784 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27785 new_path="$unix_path" 27786 fi 27787 27788 if test "x$path" != "x$new_path"; then 27789 BOOT_JDK="$new_path" 27790 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27791 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27792 fi 27793 27794 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27795 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27796 27797 else 27798 # We're on a unix platform. Hooray! :) 27799 path="$BOOT_JDK" 27800 has_space=`$ECHO "$path" | $GREP " "` 27801 if test "x$has_space" != x; then 27802 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27803 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27804 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27805 fi 27806 27807 # Use eval to expand a potential ~ 27808 eval path="$path" 27809 if test ! -f "$path" && test ! -d "$path"; then 27810 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27811 fi 27812 27813 if test -d "$path"; then 27814 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27815 else 27816 dir="`$DIRNAME "$path"`" 27817 base="`$BASENAME "$path"`" 27818 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27819 fi 27820 fi 27821 fi 27822 27823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27824 $as_echo_n "checking for Boot JDK... " >&6; } 27825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27826 $as_echo "$BOOT_JDK" >&6; } 27827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27828 $as_echo_n "checking Boot JDK version... " >&6; } 27829 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27831 $as_echo "$BOOT_JDK_VERSION" >&6; } 27832 fi # end check jdk version 27833 fi # end check javac 27834 fi # end check java 27835 fi # end check boot jdk found 27836 fi 27837 27838 27839 if test "x$BOOT_JDK_FOUND" = xno; then 27840 # Now execute the test 27841 27842 if test "x$PROGRAMW6432" != x; then 27843 VIRTUAL_DIR="$PROGRAMW6432/Java" 27844 27845 windows_path="$VIRTUAL_DIR" 27846 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27847 unix_path=`$CYGPATH -u "$windows_path"` 27848 VIRTUAL_DIR="$unix_path" 27849 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27850 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27851 VIRTUAL_DIR="$unix_path" 27852 fi 27853 27854 27855 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27856 BOOT_JDK_SUFFIX="" 27857 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27858 if test "x$ALL_JDKS_FOUND" != x; then 27859 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27860 27861 if test "x$BOOT_JDK_FOUND" = xno; then 27862 # Now execute the test 27863 27864 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27865 if test -d "$BOOT_JDK"; then 27866 BOOT_JDK_FOUND=maybe 27867 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27868 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27869 fi 27870 27871 27872 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27873 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27874 # Do we have a bin/java? 27875 if test ! -x "$BOOT_JDK/bin/java"; then 27876 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27877 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27878 BOOT_JDK_FOUND=no 27879 else 27880 # Do we have a bin/javac? 27881 if test ! -x "$BOOT_JDK/bin/javac"; then 27882 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27883 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27884 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27885 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27886 BOOT_JDK_FOUND=no 27887 else 27888 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27889 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27890 27891 # Extra M4 quote needed to protect [] in grep expression. 27892 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 27893 if test "x$FOUND_CORRECT_VERSION" = x; then 27894 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27895 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27896 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 27897 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 27898 BOOT_JDK_FOUND=no 27899 else 27900 # We're done! :-) 27901 BOOT_JDK_FOUND=yes 27902 27903 # Only process if variable expands to non-empty 27904 27905 if test "x$BOOT_JDK" != x; then 27906 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27907 27908 # Input might be given as Windows format, start by converting to 27909 # unix format. 27910 path="$BOOT_JDK" 27911 new_path=`$CYGPATH -u "$path"` 27912 27913 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27914 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27915 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27916 # "foo.exe" is OK but "foo" is an error. 27917 # 27918 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27919 # It is also a way to make sure we got the proper file name for the real test later on. 27920 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27921 if test "x$test_shortpath" = x; then 27922 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27923 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27924 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27925 fi 27926 27927 # Call helper function which possibly converts this using DOS-style short mode. 27928 # If so, the updated path is stored in $new_path. 27929 27930 input_path="$new_path" 27931 # Check if we need to convert this using DOS-style short mode. If the path 27932 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27933 # take no chances and rewrite it. 27934 # Note: m4 eats our [], so we need to use [ and ] instead. 27935 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27936 if test "x$has_forbidden_chars" != x; then 27937 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27938 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27939 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27940 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27941 # Going to short mode and back again did indeed matter. Since short mode is 27942 # case insensitive, let's make it lowercase to improve readability. 27943 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27944 # Now convert it back to Unix-style (cygpath) 27945 input_path=`$CYGPATH -u "$shortmode_path"` 27946 new_path="$input_path" 27947 fi 27948 fi 27949 27950 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27951 if test "x$test_cygdrive_prefix" = x; then 27952 # As a simple fix, exclude /usr/bin since it's not a real path. 27953 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27954 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27955 # a path prefixed by /cygdrive for fixpath to work. 27956 new_path="$CYGWIN_ROOT_PATH$input_path" 27957 fi 27958 fi 27959 27960 27961 if test "x$path" != "x$new_path"; then 27962 BOOT_JDK="$new_path" 27963 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27964 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27965 fi 27966 27967 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27968 27969 path="$BOOT_JDK" 27970 has_colon=`$ECHO $path | $GREP ^.:` 27971 new_path="$path" 27972 if test "x$has_colon" = x; then 27973 # Not in mixed or Windows style, start by that. 27974 new_path=`cmd //c echo $path` 27975 fi 27976 27977 27978 input_path="$new_path" 27979 # Check if we need to convert this using DOS-style short mode. If the path 27980 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27981 # take no chances and rewrite it. 27982 # Note: m4 eats our [], so we need to use [ and ] instead. 27983 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27984 if test "x$has_forbidden_chars" != x; then 27985 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27986 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27987 fi 27988 27989 27990 windows_path="$new_path" 27991 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27992 unix_path=`$CYGPATH -u "$windows_path"` 27993 new_path="$unix_path" 27994 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27995 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27996 new_path="$unix_path" 27997 fi 27998 27999 if test "x$path" != "x$new_path"; then 28000 BOOT_JDK="$new_path" 28001 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28002 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28003 fi 28004 28005 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28006 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28007 28008 else 28009 # We're on a unix platform. Hooray! :) 28010 path="$BOOT_JDK" 28011 has_space=`$ECHO "$path" | $GREP " "` 28012 if test "x$has_space" != x; then 28013 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28014 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28015 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28016 fi 28017 28018 # Use eval to expand a potential ~ 28019 eval path="$path" 28020 if test ! -f "$path" && test ! -d "$path"; then 28021 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28022 fi 28023 28024 if test -d "$path"; then 28025 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28026 else 28027 dir="`$DIRNAME "$path"`" 28028 base="`$BASENAME "$path"`" 28029 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28030 fi 28031 fi 28032 fi 28033 28034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28035 $as_echo_n "checking for Boot JDK... " >&6; } 28036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28037 $as_echo "$BOOT_JDK" >&6; } 28038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28039 $as_echo_n "checking Boot JDK version... " >&6; } 28040 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28042 $as_echo "$BOOT_JDK_VERSION" >&6; } 28043 fi # end check jdk version 28044 fi # end check javac 28045 fi # end check java 28046 fi # end check boot jdk found 28047 fi 28048 28049 done 28050 fi 28051 28052 fi 28053 28054 28055 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28056 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28057 # Do we have a bin/java? 28058 if test ! -x "$BOOT_JDK/bin/java"; then 28059 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28060 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28061 BOOT_JDK_FOUND=no 28062 else 28063 # Do we have a bin/javac? 28064 if test ! -x "$BOOT_JDK/bin/javac"; then 28065 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28066 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28067 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28068 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28069 BOOT_JDK_FOUND=no 28070 else 28071 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28072 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28073 28074 # Extra M4 quote needed to protect [] in grep expression. 28075 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 28076 if test "x$FOUND_CORRECT_VERSION" = x; then 28077 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28078 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28079 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 28080 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 28081 BOOT_JDK_FOUND=no 28082 else 28083 # We're done! :-) 28084 BOOT_JDK_FOUND=yes 28085 28086 # Only process if variable expands to non-empty 28087 28088 if test "x$BOOT_JDK" != x; then 28089 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28090 28091 # Input might be given as Windows format, start by converting to 28092 # unix format. 28093 path="$BOOT_JDK" 28094 new_path=`$CYGPATH -u "$path"` 28095 28096 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28097 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28098 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28099 # "foo.exe" is OK but "foo" is an error. 28100 # 28101 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28102 # It is also a way to make sure we got the proper file name for the real test later on. 28103 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28104 if test "x$test_shortpath" = x; then 28105 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28106 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28107 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28108 fi 28109 28110 # Call helper function which possibly converts this using DOS-style short mode. 28111 # If so, the updated path is stored in $new_path. 28112 28113 input_path="$new_path" 28114 # Check if we need to convert this using DOS-style short mode. If the path 28115 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28116 # take no chances and rewrite it. 28117 # Note: m4 eats our [], so we need to use [ and ] instead. 28118 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28119 if test "x$has_forbidden_chars" != x; then 28120 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28121 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28122 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28123 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28124 # Going to short mode and back again did indeed matter. Since short mode is 28125 # case insensitive, let's make it lowercase to improve readability. 28126 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28127 # Now convert it back to Unix-style (cygpath) 28128 input_path=`$CYGPATH -u "$shortmode_path"` 28129 new_path="$input_path" 28130 fi 28131 fi 28132 28133 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28134 if test "x$test_cygdrive_prefix" = x; then 28135 # As a simple fix, exclude /usr/bin since it's not a real path. 28136 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28137 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28138 # a path prefixed by /cygdrive for fixpath to work. 28139 new_path="$CYGWIN_ROOT_PATH$input_path" 28140 fi 28141 fi 28142 28143 28144 if test "x$path" != "x$new_path"; then 28145 BOOT_JDK="$new_path" 28146 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28147 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28148 fi 28149 28150 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28151 28152 path="$BOOT_JDK" 28153 has_colon=`$ECHO $path | $GREP ^.:` 28154 new_path="$path" 28155 if test "x$has_colon" = x; then 28156 # Not in mixed or Windows style, start by that. 28157 new_path=`cmd //c echo $path` 28158 fi 28159 28160 28161 input_path="$new_path" 28162 # Check if we need to convert this using DOS-style short mode. If the path 28163 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28164 # take no chances and rewrite it. 28165 # Note: m4 eats our [], so we need to use [ and ] instead. 28166 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28167 if test "x$has_forbidden_chars" != x; then 28168 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28169 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28170 fi 28171 28172 28173 windows_path="$new_path" 28174 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28175 unix_path=`$CYGPATH -u "$windows_path"` 28176 new_path="$unix_path" 28177 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28178 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28179 new_path="$unix_path" 28180 fi 28181 28182 if test "x$path" != "x$new_path"; then 28183 BOOT_JDK="$new_path" 28184 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28185 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28186 fi 28187 28188 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28189 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28190 28191 else 28192 # We're on a unix platform. Hooray! :) 28193 path="$BOOT_JDK" 28194 has_space=`$ECHO "$path" | $GREP " "` 28195 if test "x$has_space" != x; then 28196 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28197 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28198 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28199 fi 28200 28201 # Use eval to expand a potential ~ 28202 eval path="$path" 28203 if test ! -f "$path" && test ! -d "$path"; then 28204 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28205 fi 28206 28207 if test -d "$path"; then 28208 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28209 else 28210 dir="`$DIRNAME "$path"`" 28211 base="`$BASENAME "$path"`" 28212 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28213 fi 28214 fi 28215 fi 28216 28217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28218 $as_echo_n "checking for Boot JDK... " >&6; } 28219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28220 $as_echo "$BOOT_JDK" >&6; } 28221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28222 $as_echo_n "checking Boot JDK version... " >&6; } 28223 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28225 $as_echo "$BOOT_JDK_VERSION" >&6; } 28226 fi # end check jdk version 28227 fi # end check javac 28228 fi # end check java 28229 fi # end check boot jdk found 28230 fi 28231 28232 28233 if test "x$BOOT_JDK_FOUND" = xno; then 28234 # Now execute the test 28235 28236 if test "x$PROGRAMFILES" != x; then 28237 VIRTUAL_DIR="$PROGRAMFILES/Java" 28238 28239 windows_path="$VIRTUAL_DIR" 28240 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28241 unix_path=`$CYGPATH -u "$windows_path"` 28242 VIRTUAL_DIR="$unix_path" 28243 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28244 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28245 VIRTUAL_DIR="$unix_path" 28246 fi 28247 28248 28249 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 28250 BOOT_JDK_SUFFIX="" 28251 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28252 if test "x$ALL_JDKS_FOUND" != x; then 28253 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28254 28255 if test "x$BOOT_JDK_FOUND" = xno; then 28256 # Now execute the test 28257 28258 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28259 if test -d "$BOOT_JDK"; then 28260 BOOT_JDK_FOUND=maybe 28261 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28262 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28263 fi 28264 28265 28266 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28267 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28268 # Do we have a bin/java? 28269 if test ! -x "$BOOT_JDK/bin/java"; then 28270 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28271 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28272 BOOT_JDK_FOUND=no 28273 else 28274 # Do we have a bin/javac? 28275 if test ! -x "$BOOT_JDK/bin/javac"; then 28276 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28277 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28278 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28279 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28280 BOOT_JDK_FOUND=no 28281 else 28282 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28283 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28284 28285 # Extra M4 quote needed to protect [] in grep expression. 28286 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 28287 if test "x$FOUND_CORRECT_VERSION" = x; then 28288 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28289 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28290 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 28291 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 28292 BOOT_JDK_FOUND=no 28293 else 28294 # We're done! :-) 28295 BOOT_JDK_FOUND=yes 28296 28297 # Only process if variable expands to non-empty 28298 28299 if test "x$BOOT_JDK" != x; then 28300 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28301 28302 # Input might be given as Windows format, start by converting to 28303 # unix format. 28304 path="$BOOT_JDK" 28305 new_path=`$CYGPATH -u "$path"` 28306 28307 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28308 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28309 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28310 # "foo.exe" is OK but "foo" is an error. 28311 # 28312 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28313 # It is also a way to make sure we got the proper file name for the real test later on. 28314 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28315 if test "x$test_shortpath" = x; then 28316 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28317 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28318 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28319 fi 28320 28321 # Call helper function which possibly converts this using DOS-style short mode. 28322 # If so, the updated path is stored in $new_path. 28323 28324 input_path="$new_path" 28325 # Check if we need to convert this using DOS-style short mode. If the path 28326 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28327 # take no chances and rewrite it. 28328 # Note: m4 eats our [], so we need to use [ and ] instead. 28329 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28330 if test "x$has_forbidden_chars" != x; then 28331 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28332 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28333 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28334 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28335 # Going to short mode and back again did indeed matter. Since short mode is 28336 # case insensitive, let's make it lowercase to improve readability. 28337 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28338 # Now convert it back to Unix-style (cygpath) 28339 input_path=`$CYGPATH -u "$shortmode_path"` 28340 new_path="$input_path" 28341 fi 28342 fi 28343 28344 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28345 if test "x$test_cygdrive_prefix" = x; then 28346 # As a simple fix, exclude /usr/bin since it's not a real path. 28347 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28348 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28349 # a path prefixed by /cygdrive for fixpath to work. 28350 new_path="$CYGWIN_ROOT_PATH$input_path" 28351 fi 28352 fi 28353 28354 28355 if test "x$path" != "x$new_path"; then 28356 BOOT_JDK="$new_path" 28357 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28358 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28359 fi 28360 28361 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28362 28363 path="$BOOT_JDK" 28364 has_colon=`$ECHO $path | $GREP ^.:` 28365 new_path="$path" 28366 if test "x$has_colon" = x; then 28367 # Not in mixed or Windows style, start by that. 28368 new_path=`cmd //c echo $path` 28369 fi 28370 28371 28372 input_path="$new_path" 28373 # Check if we need to convert this using DOS-style short mode. If the path 28374 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28375 # take no chances and rewrite it. 28376 # Note: m4 eats our [], so we need to use [ and ] instead. 28377 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28378 if test "x$has_forbidden_chars" != x; then 28379 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28380 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28381 fi 28382 28383 28384 windows_path="$new_path" 28385 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28386 unix_path=`$CYGPATH -u "$windows_path"` 28387 new_path="$unix_path" 28388 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28389 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28390 new_path="$unix_path" 28391 fi 28392 28393 if test "x$path" != "x$new_path"; then 28394 BOOT_JDK="$new_path" 28395 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28396 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28397 fi 28398 28399 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28400 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28401 28402 else 28403 # We're on a unix platform. Hooray! :) 28404 path="$BOOT_JDK" 28405 has_space=`$ECHO "$path" | $GREP " "` 28406 if test "x$has_space" != x; then 28407 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28408 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28409 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28410 fi 28411 28412 # Use eval to expand a potential ~ 28413 eval path="$path" 28414 if test ! -f "$path" && test ! -d "$path"; then 28415 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28416 fi 28417 28418 if test -d "$path"; then 28419 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28420 else 28421 dir="`$DIRNAME "$path"`" 28422 base="`$BASENAME "$path"`" 28423 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28424 fi 28425 fi 28426 fi 28427 28428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28429 $as_echo_n "checking for Boot JDK... " >&6; } 28430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28431 $as_echo "$BOOT_JDK" >&6; } 28432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28433 $as_echo_n "checking Boot JDK version... " >&6; } 28434 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28436 $as_echo "$BOOT_JDK_VERSION" >&6; } 28437 fi # end check jdk version 28438 fi # end check javac 28439 fi # end check java 28440 fi # end check boot jdk found 28441 fi 28442 28443 done 28444 fi 28445 28446 fi 28447 28448 28449 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28450 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28451 # Do we have a bin/java? 28452 if test ! -x "$BOOT_JDK/bin/java"; then 28453 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28454 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28455 BOOT_JDK_FOUND=no 28456 else 28457 # Do we have a bin/javac? 28458 if test ! -x "$BOOT_JDK/bin/javac"; then 28459 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28460 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28461 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28462 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28463 BOOT_JDK_FOUND=no 28464 else 28465 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28466 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28467 28468 # Extra M4 quote needed to protect [] in grep expression. 28469 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 28470 if test "x$FOUND_CORRECT_VERSION" = x; then 28471 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28472 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28473 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 28474 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 28475 BOOT_JDK_FOUND=no 28476 else 28477 # We're done! :-) 28478 BOOT_JDK_FOUND=yes 28479 28480 # Only process if variable expands to non-empty 28481 28482 if test "x$BOOT_JDK" != x; then 28483 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28484 28485 # Input might be given as Windows format, start by converting to 28486 # unix format. 28487 path="$BOOT_JDK" 28488 new_path=`$CYGPATH -u "$path"` 28489 28490 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28491 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28492 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28493 # "foo.exe" is OK but "foo" is an error. 28494 # 28495 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28496 # It is also a way to make sure we got the proper file name for the real test later on. 28497 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28498 if test "x$test_shortpath" = x; then 28499 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28500 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28501 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28502 fi 28503 28504 # Call helper function which possibly converts this using DOS-style short mode. 28505 # If so, the updated path is stored in $new_path. 28506 28507 input_path="$new_path" 28508 # Check if we need to convert this using DOS-style short mode. If the path 28509 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28510 # take no chances and rewrite it. 28511 # Note: m4 eats our [], so we need to use [ and ] instead. 28512 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28513 if test "x$has_forbidden_chars" != x; then 28514 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28515 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28516 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28517 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28518 # Going to short mode and back again did indeed matter. Since short mode is 28519 # case insensitive, let's make it lowercase to improve readability. 28520 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28521 # Now convert it back to Unix-style (cygpath) 28522 input_path=`$CYGPATH -u "$shortmode_path"` 28523 new_path="$input_path" 28524 fi 28525 fi 28526 28527 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28528 if test "x$test_cygdrive_prefix" = x; then 28529 # As a simple fix, exclude /usr/bin since it's not a real path. 28530 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28531 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28532 # a path prefixed by /cygdrive for fixpath to work. 28533 new_path="$CYGWIN_ROOT_PATH$input_path" 28534 fi 28535 fi 28536 28537 28538 if test "x$path" != "x$new_path"; then 28539 BOOT_JDK="$new_path" 28540 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28541 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28542 fi 28543 28544 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28545 28546 path="$BOOT_JDK" 28547 has_colon=`$ECHO $path | $GREP ^.:` 28548 new_path="$path" 28549 if test "x$has_colon" = x; then 28550 # Not in mixed or Windows style, start by that. 28551 new_path=`cmd //c echo $path` 28552 fi 28553 28554 28555 input_path="$new_path" 28556 # Check if we need to convert this using DOS-style short mode. If the path 28557 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28558 # take no chances and rewrite it. 28559 # Note: m4 eats our [], so we need to use [ and ] instead. 28560 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28561 if test "x$has_forbidden_chars" != x; then 28562 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28563 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28564 fi 28565 28566 28567 windows_path="$new_path" 28568 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28569 unix_path=`$CYGPATH -u "$windows_path"` 28570 new_path="$unix_path" 28571 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28572 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28573 new_path="$unix_path" 28574 fi 28575 28576 if test "x$path" != "x$new_path"; then 28577 BOOT_JDK="$new_path" 28578 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28579 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28580 fi 28581 28582 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28583 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28584 28585 else 28586 # We're on a unix platform. Hooray! :) 28587 path="$BOOT_JDK" 28588 has_space=`$ECHO "$path" | $GREP " "` 28589 if test "x$has_space" != x; then 28590 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28591 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28592 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28593 fi 28594 28595 # Use eval to expand a potential ~ 28596 eval path="$path" 28597 if test ! -f "$path" && test ! -d "$path"; then 28598 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28599 fi 28600 28601 if test -d "$path"; then 28602 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28603 else 28604 dir="`$DIRNAME "$path"`" 28605 base="`$BASENAME "$path"`" 28606 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28607 fi 28608 fi 28609 fi 28610 28611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28612 $as_echo_n "checking for Boot JDK... " >&6; } 28613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28614 $as_echo "$BOOT_JDK" >&6; } 28615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28616 $as_echo_n "checking Boot JDK version... " >&6; } 28617 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28619 $as_echo "$BOOT_JDK_VERSION" >&6; } 28620 fi # end check jdk version 28621 fi # end check javac 28622 fi # end check java 28623 fi # end check boot jdk found 28624 fi 28625 28626 28627 if test "x$BOOT_JDK_FOUND" = xno; then 28628 # Now execute the test 28629 28630 if test "x$ProgramFiles" != x; then 28631 VIRTUAL_DIR="$ProgramFiles/Java" 28632 28633 windows_path="$VIRTUAL_DIR" 28634 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28635 unix_path=`$CYGPATH -u "$windows_path"` 28636 VIRTUAL_DIR="$unix_path" 28637 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28638 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28639 VIRTUAL_DIR="$unix_path" 28640 fi 28641 28642 28643 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 28644 BOOT_JDK_SUFFIX="" 28645 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28646 if test "x$ALL_JDKS_FOUND" != x; then 28647 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28648 28649 if test "x$BOOT_JDK_FOUND" = xno; then 28650 # Now execute the test 28651 28652 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28653 if test -d "$BOOT_JDK"; then 28654 BOOT_JDK_FOUND=maybe 28655 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28656 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28657 fi 28658 28659 28660 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28661 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28662 # Do we have a bin/java? 28663 if test ! -x "$BOOT_JDK/bin/java"; then 28664 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28665 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28666 BOOT_JDK_FOUND=no 28667 else 28668 # Do we have a bin/javac? 28669 if test ! -x "$BOOT_JDK/bin/javac"; then 28670 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28671 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28672 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28673 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28674 BOOT_JDK_FOUND=no 28675 else 28676 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28677 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28678 28679 # Extra M4 quote needed to protect [] in grep expression. 28680 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 28681 if test "x$FOUND_CORRECT_VERSION" = x; then 28682 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28683 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28684 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 28685 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 28686 BOOT_JDK_FOUND=no 28687 else 28688 # We're done! :-) 28689 BOOT_JDK_FOUND=yes 28690 28691 # Only process if variable expands to non-empty 28692 28693 if test "x$BOOT_JDK" != x; then 28694 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28695 28696 # Input might be given as Windows format, start by converting to 28697 # unix format. 28698 path="$BOOT_JDK" 28699 new_path=`$CYGPATH -u "$path"` 28700 28701 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28702 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28703 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28704 # "foo.exe" is OK but "foo" is an error. 28705 # 28706 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28707 # It is also a way to make sure we got the proper file name for the real test later on. 28708 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28709 if test "x$test_shortpath" = x; then 28710 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28711 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28712 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28713 fi 28714 28715 # Call helper function which possibly converts this using DOS-style short mode. 28716 # If so, the updated path is stored in $new_path. 28717 28718 input_path="$new_path" 28719 # Check if we need to convert this using DOS-style short mode. If the path 28720 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28721 # take no chances and rewrite it. 28722 # Note: m4 eats our [], so we need to use [ and ] instead. 28723 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28724 if test "x$has_forbidden_chars" != x; then 28725 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28726 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28727 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28728 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28729 # Going to short mode and back again did indeed matter. Since short mode is 28730 # case insensitive, let's make it lowercase to improve readability. 28731 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28732 # Now convert it back to Unix-style (cygpath) 28733 input_path=`$CYGPATH -u "$shortmode_path"` 28734 new_path="$input_path" 28735 fi 28736 fi 28737 28738 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28739 if test "x$test_cygdrive_prefix" = x; then 28740 # As a simple fix, exclude /usr/bin since it's not a real path. 28741 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28742 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28743 # a path prefixed by /cygdrive for fixpath to work. 28744 new_path="$CYGWIN_ROOT_PATH$input_path" 28745 fi 28746 fi 28747 28748 28749 if test "x$path" != "x$new_path"; then 28750 BOOT_JDK="$new_path" 28751 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28752 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28753 fi 28754 28755 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28756 28757 path="$BOOT_JDK" 28758 has_colon=`$ECHO $path | $GREP ^.:` 28759 new_path="$path" 28760 if test "x$has_colon" = x; then 28761 # Not in mixed or Windows style, start by that. 28762 new_path=`cmd //c echo $path` 28763 fi 28764 28765 28766 input_path="$new_path" 28767 # Check if we need to convert this using DOS-style short mode. If the path 28768 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28769 # take no chances and rewrite it. 28770 # Note: m4 eats our [], so we need to use [ and ] instead. 28771 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28772 if test "x$has_forbidden_chars" != x; then 28773 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28774 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28775 fi 28776 28777 28778 windows_path="$new_path" 28779 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28780 unix_path=`$CYGPATH -u "$windows_path"` 28781 new_path="$unix_path" 28782 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28783 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28784 new_path="$unix_path" 28785 fi 28786 28787 if test "x$path" != "x$new_path"; then 28788 BOOT_JDK="$new_path" 28789 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28790 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28791 fi 28792 28793 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28794 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28795 28796 else 28797 # We're on a unix platform. Hooray! :) 28798 path="$BOOT_JDK" 28799 has_space=`$ECHO "$path" | $GREP " "` 28800 if test "x$has_space" != x; then 28801 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28802 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28803 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28804 fi 28805 28806 # Use eval to expand a potential ~ 28807 eval path="$path" 28808 if test ! -f "$path" && test ! -d "$path"; then 28809 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28810 fi 28811 28812 if test -d "$path"; then 28813 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28814 else 28815 dir="`$DIRNAME "$path"`" 28816 base="`$BASENAME "$path"`" 28817 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28818 fi 28819 fi 28820 fi 28821 28822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28823 $as_echo_n "checking for Boot JDK... " >&6; } 28824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28825 $as_echo "$BOOT_JDK" >&6; } 28826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28827 $as_echo_n "checking Boot JDK version... " >&6; } 28828 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28830 $as_echo "$BOOT_JDK_VERSION" >&6; } 28831 fi # end check jdk version 28832 fi # end check javac 28833 fi # end check java 28834 fi # end check boot jdk found 28835 fi 28836 28837 done 28838 fi 28839 28840 fi 28841 28842 28843 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28844 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28845 # Do we have a bin/java? 28846 if test ! -x "$BOOT_JDK/bin/java"; then 28847 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28848 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28849 BOOT_JDK_FOUND=no 28850 else 28851 # Do we have a bin/javac? 28852 if test ! -x "$BOOT_JDK/bin/javac"; then 28853 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28854 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28855 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28856 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28857 BOOT_JDK_FOUND=no 28858 else 28859 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28860 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28861 28862 # Extra M4 quote needed to protect [] in grep expression. 28863 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 28864 if test "x$FOUND_CORRECT_VERSION" = x; then 28865 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28866 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28867 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 28868 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 28869 BOOT_JDK_FOUND=no 28870 else 28871 # We're done! :-) 28872 BOOT_JDK_FOUND=yes 28873 28874 # Only process if variable expands to non-empty 28875 28876 if test "x$BOOT_JDK" != x; then 28877 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28878 28879 # Input might be given as Windows format, start by converting to 28880 # unix format. 28881 path="$BOOT_JDK" 28882 new_path=`$CYGPATH -u "$path"` 28883 28884 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28885 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28886 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28887 # "foo.exe" is OK but "foo" is an error. 28888 # 28889 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28890 # It is also a way to make sure we got the proper file name for the real test later on. 28891 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28892 if test "x$test_shortpath" = x; then 28893 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28894 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28895 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28896 fi 28897 28898 # Call helper function which possibly converts this using DOS-style short mode. 28899 # If so, the updated path is stored in $new_path. 28900 28901 input_path="$new_path" 28902 # Check if we need to convert this using DOS-style short mode. If the path 28903 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28904 # take no chances and rewrite it. 28905 # Note: m4 eats our [], so we need to use [ and ] instead. 28906 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28907 if test "x$has_forbidden_chars" != x; then 28908 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28909 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28910 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28911 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28912 # Going to short mode and back again did indeed matter. Since short mode is 28913 # case insensitive, let's make it lowercase to improve readability. 28914 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28915 # Now convert it back to Unix-style (cygpath) 28916 input_path=`$CYGPATH -u "$shortmode_path"` 28917 new_path="$input_path" 28918 fi 28919 fi 28920 28921 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28922 if test "x$test_cygdrive_prefix" = x; then 28923 # As a simple fix, exclude /usr/bin since it's not a real path. 28924 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28925 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28926 # a path prefixed by /cygdrive for fixpath to work. 28927 new_path="$CYGWIN_ROOT_PATH$input_path" 28928 fi 28929 fi 28930 28931 28932 if test "x$path" != "x$new_path"; then 28933 BOOT_JDK="$new_path" 28934 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28935 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28936 fi 28937 28938 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28939 28940 path="$BOOT_JDK" 28941 has_colon=`$ECHO $path | $GREP ^.:` 28942 new_path="$path" 28943 if test "x$has_colon" = x; then 28944 # Not in mixed or Windows style, start by that. 28945 new_path=`cmd //c echo $path` 28946 fi 28947 28948 28949 input_path="$new_path" 28950 # Check if we need to convert this using DOS-style short mode. If the path 28951 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28952 # take no chances and rewrite it. 28953 # Note: m4 eats our [], so we need to use [ and ] instead. 28954 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28955 if test "x$has_forbidden_chars" != x; then 28956 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28957 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28958 fi 28959 28960 28961 windows_path="$new_path" 28962 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28963 unix_path=`$CYGPATH -u "$windows_path"` 28964 new_path="$unix_path" 28965 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28966 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28967 new_path="$unix_path" 28968 fi 28969 28970 if test "x$path" != "x$new_path"; then 28971 BOOT_JDK="$new_path" 28972 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28973 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28974 fi 28975 28976 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28977 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28978 28979 else 28980 # We're on a unix platform. Hooray! :) 28981 path="$BOOT_JDK" 28982 has_space=`$ECHO "$path" | $GREP " "` 28983 if test "x$has_space" != x; then 28984 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28985 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28986 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28987 fi 28988 28989 # Use eval to expand a potential ~ 28990 eval path="$path" 28991 if test ! -f "$path" && test ! -d "$path"; then 28992 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28993 fi 28994 28995 if test -d "$path"; then 28996 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28997 else 28998 dir="`$DIRNAME "$path"`" 28999 base="`$BASENAME "$path"`" 29000 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29001 fi 29002 fi 29003 fi 29004 29005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29006 $as_echo_n "checking for Boot JDK... " >&6; } 29007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29008 $as_echo "$BOOT_JDK" >&6; } 29009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29010 $as_echo_n "checking Boot JDK version... " >&6; } 29011 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29013 $as_echo "$BOOT_JDK_VERSION" >&6; } 29014 fi # end check jdk version 29015 fi # end check javac 29016 fi # end check java 29017 fi # end check boot jdk found 29018 fi 29019 29020 29021 if test "x$BOOT_JDK_FOUND" = xno; then 29022 # Now execute the test 29023 29024 BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java" 29025 BOOT_JDK_SUFFIX="" 29026 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29027 if test "x$ALL_JDKS_FOUND" != x; then 29028 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29029 29030 if test "x$BOOT_JDK_FOUND" = xno; then 29031 # Now execute the test 29032 29033 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29034 if test -d "$BOOT_JDK"; then 29035 BOOT_JDK_FOUND=maybe 29036 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29037 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29038 fi 29039 29040 29041 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29042 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29043 # Do we have a bin/java? 29044 if test ! -x "$BOOT_JDK/bin/java"; then 29045 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29046 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29047 BOOT_JDK_FOUND=no 29048 else 29049 # Do we have a bin/javac? 29050 if test ! -x "$BOOT_JDK/bin/javac"; then 29051 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29052 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29053 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29054 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29055 BOOT_JDK_FOUND=no 29056 else 29057 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29058 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29059 29060 # Extra M4 quote needed to protect [] in grep expression. 29061 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 29062 if test "x$FOUND_CORRECT_VERSION" = x; then 29063 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29064 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29065 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 29066 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 29067 BOOT_JDK_FOUND=no 29068 else 29069 # We're done! :-) 29070 BOOT_JDK_FOUND=yes 29071 29072 # Only process if variable expands to non-empty 29073 29074 if test "x$BOOT_JDK" != x; then 29075 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29076 29077 # Input might be given as Windows format, start by converting to 29078 # unix format. 29079 path="$BOOT_JDK" 29080 new_path=`$CYGPATH -u "$path"` 29081 29082 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29083 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29084 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29085 # "foo.exe" is OK but "foo" is an error. 29086 # 29087 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29088 # It is also a way to make sure we got the proper file name for the real test later on. 29089 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29090 if test "x$test_shortpath" = x; then 29091 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29092 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29093 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29094 fi 29095 29096 # Call helper function which possibly converts this using DOS-style short mode. 29097 # If so, the updated path is stored in $new_path. 29098 29099 input_path="$new_path" 29100 # Check if we need to convert this using DOS-style short mode. If the path 29101 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29102 # take no chances and rewrite it. 29103 # Note: m4 eats our [], so we need to use [ and ] instead. 29104 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29105 if test "x$has_forbidden_chars" != x; then 29106 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29107 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29108 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29109 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29110 # Going to short mode and back again did indeed matter. Since short mode is 29111 # case insensitive, let's make it lowercase to improve readability. 29112 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29113 # Now convert it back to Unix-style (cygpath) 29114 input_path=`$CYGPATH -u "$shortmode_path"` 29115 new_path="$input_path" 29116 fi 29117 fi 29118 29119 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29120 if test "x$test_cygdrive_prefix" = x; then 29121 # As a simple fix, exclude /usr/bin since it's not a real path. 29122 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29123 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29124 # a path prefixed by /cygdrive for fixpath to work. 29125 new_path="$CYGWIN_ROOT_PATH$input_path" 29126 fi 29127 fi 29128 29129 29130 if test "x$path" != "x$new_path"; then 29131 BOOT_JDK="$new_path" 29132 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29133 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29134 fi 29135 29136 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29137 29138 path="$BOOT_JDK" 29139 has_colon=`$ECHO $path | $GREP ^.:` 29140 new_path="$path" 29141 if test "x$has_colon" = x; then 29142 # Not in mixed or Windows style, start by that. 29143 new_path=`cmd //c echo $path` 29144 fi 29145 29146 29147 input_path="$new_path" 29148 # Check if we need to convert this using DOS-style short mode. If the path 29149 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29150 # take no chances and rewrite it. 29151 # Note: m4 eats our [], so we need to use [ and ] instead. 29152 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29153 if test "x$has_forbidden_chars" != x; then 29154 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29155 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29156 fi 29157 29158 29159 windows_path="$new_path" 29160 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29161 unix_path=`$CYGPATH -u "$windows_path"` 29162 new_path="$unix_path" 29163 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29164 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29165 new_path="$unix_path" 29166 fi 29167 29168 if test "x$path" != "x$new_path"; then 29169 BOOT_JDK="$new_path" 29170 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29171 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29172 fi 29173 29174 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29175 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29176 29177 else 29178 # We're on a unix platform. Hooray! :) 29179 path="$BOOT_JDK" 29180 has_space=`$ECHO "$path" | $GREP " "` 29181 if test "x$has_space" != x; then 29182 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29183 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29184 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29185 fi 29186 29187 # Use eval to expand a potential ~ 29188 eval path="$path" 29189 if test ! -f "$path" && test ! -d "$path"; then 29190 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29191 fi 29192 29193 if test -d "$path"; then 29194 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29195 else 29196 dir="`$DIRNAME "$path"`" 29197 base="`$BASENAME "$path"`" 29198 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29199 fi 29200 fi 29201 fi 29202 29203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29204 $as_echo_n "checking for Boot JDK... " >&6; } 29205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29206 $as_echo "$BOOT_JDK" >&6; } 29207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29208 $as_echo_n "checking Boot JDK version... " >&6; } 29209 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29211 $as_echo "$BOOT_JDK_VERSION" >&6; } 29212 fi # end check jdk version 29213 fi # end check javac 29214 fi # end check java 29215 fi # end check boot jdk found 29216 fi 29217 29218 done 29219 fi 29220 29221 29222 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29223 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29224 # Do we have a bin/java? 29225 if test ! -x "$BOOT_JDK/bin/java"; then 29226 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29227 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29228 BOOT_JDK_FOUND=no 29229 else 29230 # Do we have a bin/javac? 29231 if test ! -x "$BOOT_JDK/bin/javac"; then 29232 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29233 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29234 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29235 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29236 BOOT_JDK_FOUND=no 29237 else 29238 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29239 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29240 29241 # Extra M4 quote needed to protect [] in grep expression. 29242 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 29243 if test "x$FOUND_CORRECT_VERSION" = x; then 29244 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29245 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29246 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 29247 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 29248 BOOT_JDK_FOUND=no 29249 else 29250 # We're done! :-) 29251 BOOT_JDK_FOUND=yes 29252 29253 # Only process if variable expands to non-empty 29254 29255 if test "x$BOOT_JDK" != x; then 29256 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29257 29258 # Input might be given as Windows format, start by converting to 29259 # unix format. 29260 path="$BOOT_JDK" 29261 new_path=`$CYGPATH -u "$path"` 29262 29263 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29264 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29265 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29266 # "foo.exe" is OK but "foo" is an error. 29267 # 29268 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29269 # It is also a way to make sure we got the proper file name for the real test later on. 29270 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29271 if test "x$test_shortpath" = x; then 29272 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29273 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29274 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29275 fi 29276 29277 # Call helper function which possibly converts this using DOS-style short mode. 29278 # If so, the updated path is stored in $new_path. 29279 29280 input_path="$new_path" 29281 # Check if we need to convert this using DOS-style short mode. If the path 29282 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29283 # take no chances and rewrite it. 29284 # Note: m4 eats our [], so we need to use [ and ] instead. 29285 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29286 if test "x$has_forbidden_chars" != x; then 29287 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29288 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29289 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29290 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29291 # Going to short mode and back again did indeed matter. Since short mode is 29292 # case insensitive, let's make it lowercase to improve readability. 29293 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29294 # Now convert it back to Unix-style (cygpath) 29295 input_path=`$CYGPATH -u "$shortmode_path"` 29296 new_path="$input_path" 29297 fi 29298 fi 29299 29300 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29301 if test "x$test_cygdrive_prefix" = x; then 29302 # As a simple fix, exclude /usr/bin since it's not a real path. 29303 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29304 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29305 # a path prefixed by /cygdrive for fixpath to work. 29306 new_path="$CYGWIN_ROOT_PATH$input_path" 29307 fi 29308 fi 29309 29310 29311 if test "x$path" != "x$new_path"; then 29312 BOOT_JDK="$new_path" 29313 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29314 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29315 fi 29316 29317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29318 29319 path="$BOOT_JDK" 29320 has_colon=`$ECHO $path | $GREP ^.:` 29321 new_path="$path" 29322 if test "x$has_colon" = x; then 29323 # Not in mixed or Windows style, start by that. 29324 new_path=`cmd //c echo $path` 29325 fi 29326 29327 29328 input_path="$new_path" 29329 # Check if we need to convert this using DOS-style short mode. If the path 29330 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29331 # take no chances and rewrite it. 29332 # Note: m4 eats our [], so we need to use [ and ] instead. 29333 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29334 if test "x$has_forbidden_chars" != x; then 29335 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29336 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29337 fi 29338 29339 29340 windows_path="$new_path" 29341 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29342 unix_path=`$CYGPATH -u "$windows_path"` 29343 new_path="$unix_path" 29344 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29345 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29346 new_path="$unix_path" 29347 fi 29348 29349 if test "x$path" != "x$new_path"; then 29350 BOOT_JDK="$new_path" 29351 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29352 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29353 fi 29354 29355 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29356 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29357 29358 else 29359 # We're on a unix platform. Hooray! :) 29360 path="$BOOT_JDK" 29361 has_space=`$ECHO "$path" | $GREP " "` 29362 if test "x$has_space" != x; then 29363 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29364 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29365 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29366 fi 29367 29368 # Use eval to expand a potential ~ 29369 eval path="$path" 29370 if test ! -f "$path" && test ! -d "$path"; then 29371 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29372 fi 29373 29374 if test -d "$path"; then 29375 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29376 else 29377 dir="`$DIRNAME "$path"`" 29378 base="`$BASENAME "$path"`" 29379 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29380 fi 29381 fi 29382 fi 29383 29384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29385 $as_echo_n "checking for Boot JDK... " >&6; } 29386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29387 $as_echo "$BOOT_JDK" >&6; } 29388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29389 $as_echo_n "checking Boot JDK version... " >&6; } 29390 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29392 $as_echo "$BOOT_JDK_VERSION" >&6; } 29393 fi # end check jdk version 29394 fi # end check javac 29395 fi # end check java 29396 fi # end check boot jdk found 29397 fi 29398 29399 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 29400 29401 if test "x$BOOT_JDK_FOUND" = xno; then 29402 # Now execute the test 29403 29404 BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines" 29405 BOOT_JDK_SUFFIX="/Contents/Home" 29406 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29407 if test "x$ALL_JDKS_FOUND" != x; then 29408 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29409 29410 if test "x$BOOT_JDK_FOUND" = xno; then 29411 # Now execute the test 29412 29413 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29414 if test -d "$BOOT_JDK"; then 29415 BOOT_JDK_FOUND=maybe 29416 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29417 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29418 fi 29419 29420 29421 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29422 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29423 # Do we have a bin/java? 29424 if test ! -x "$BOOT_JDK/bin/java"; then 29425 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29426 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29427 BOOT_JDK_FOUND=no 29428 else 29429 # Do we have a bin/javac? 29430 if test ! -x "$BOOT_JDK/bin/javac"; then 29431 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29432 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29433 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29434 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29435 BOOT_JDK_FOUND=no 29436 else 29437 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29438 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29439 29440 # Extra M4 quote needed to protect [] in grep expression. 29441 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 29442 if test "x$FOUND_CORRECT_VERSION" = x; then 29443 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29444 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29445 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 29446 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 29447 BOOT_JDK_FOUND=no 29448 else 29449 # We're done! :-) 29450 BOOT_JDK_FOUND=yes 29451 29452 # Only process if variable expands to non-empty 29453 29454 if test "x$BOOT_JDK" != x; then 29455 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29456 29457 # Input might be given as Windows format, start by converting to 29458 # unix format. 29459 path="$BOOT_JDK" 29460 new_path=`$CYGPATH -u "$path"` 29461 29462 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29463 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29464 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29465 # "foo.exe" is OK but "foo" is an error. 29466 # 29467 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29468 # It is also a way to make sure we got the proper file name for the real test later on. 29469 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29470 if test "x$test_shortpath" = x; then 29471 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29472 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29473 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29474 fi 29475 29476 # Call helper function which possibly converts this using DOS-style short mode. 29477 # If so, the updated path is stored in $new_path. 29478 29479 input_path="$new_path" 29480 # Check if we need to convert this using DOS-style short mode. If the path 29481 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29482 # take no chances and rewrite it. 29483 # Note: m4 eats our [], so we need to use [ and ] instead. 29484 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29485 if test "x$has_forbidden_chars" != x; then 29486 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29487 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29488 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29489 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29490 # Going to short mode and back again did indeed matter. Since short mode is 29491 # case insensitive, let's make it lowercase to improve readability. 29492 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29493 # Now convert it back to Unix-style (cygpath) 29494 input_path=`$CYGPATH -u "$shortmode_path"` 29495 new_path="$input_path" 29496 fi 29497 fi 29498 29499 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29500 if test "x$test_cygdrive_prefix" = x; then 29501 # As a simple fix, exclude /usr/bin since it's not a real path. 29502 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29503 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29504 # a path prefixed by /cygdrive for fixpath to work. 29505 new_path="$CYGWIN_ROOT_PATH$input_path" 29506 fi 29507 fi 29508 29509 29510 if test "x$path" != "x$new_path"; then 29511 BOOT_JDK="$new_path" 29512 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29513 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29514 fi 29515 29516 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29517 29518 path="$BOOT_JDK" 29519 has_colon=`$ECHO $path | $GREP ^.:` 29520 new_path="$path" 29521 if test "x$has_colon" = x; then 29522 # Not in mixed or Windows style, start by that. 29523 new_path=`cmd //c echo $path` 29524 fi 29525 29526 29527 input_path="$new_path" 29528 # Check if we need to convert this using DOS-style short mode. If the path 29529 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29530 # take no chances and rewrite it. 29531 # Note: m4 eats our [], so we need to use [ and ] instead. 29532 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29533 if test "x$has_forbidden_chars" != x; then 29534 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29535 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29536 fi 29537 29538 29539 windows_path="$new_path" 29540 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29541 unix_path=`$CYGPATH -u "$windows_path"` 29542 new_path="$unix_path" 29543 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29544 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29545 new_path="$unix_path" 29546 fi 29547 29548 if test "x$path" != "x$new_path"; then 29549 BOOT_JDK="$new_path" 29550 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29551 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29552 fi 29553 29554 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29555 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29556 29557 else 29558 # We're on a unix platform. Hooray! :) 29559 path="$BOOT_JDK" 29560 has_space=`$ECHO "$path" | $GREP " "` 29561 if test "x$has_space" != x; then 29562 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29563 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29564 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29565 fi 29566 29567 # Use eval to expand a potential ~ 29568 eval path="$path" 29569 if test ! -f "$path" && test ! -d "$path"; then 29570 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29571 fi 29572 29573 if test -d "$path"; then 29574 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29575 else 29576 dir="`$DIRNAME "$path"`" 29577 base="`$BASENAME "$path"`" 29578 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29579 fi 29580 fi 29581 fi 29582 29583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29584 $as_echo_n "checking for Boot JDK... " >&6; } 29585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29586 $as_echo "$BOOT_JDK" >&6; } 29587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29588 $as_echo_n "checking Boot JDK version... " >&6; } 29589 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29591 $as_echo "$BOOT_JDK_VERSION" >&6; } 29592 fi # end check jdk version 29593 fi # end check javac 29594 fi # end check java 29595 fi # end check boot jdk found 29596 fi 29597 29598 done 29599 fi 29600 29601 29602 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29603 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29604 # Do we have a bin/java? 29605 if test ! -x "$BOOT_JDK/bin/java"; then 29606 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29607 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29608 BOOT_JDK_FOUND=no 29609 else 29610 # Do we have a bin/javac? 29611 if test ! -x "$BOOT_JDK/bin/javac"; then 29612 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29613 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29614 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29615 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29616 BOOT_JDK_FOUND=no 29617 else 29618 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29619 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29620 29621 # Extra M4 quote needed to protect [] in grep expression. 29622 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 29623 if test "x$FOUND_CORRECT_VERSION" = x; then 29624 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29625 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29626 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 29627 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 29628 BOOT_JDK_FOUND=no 29629 else 29630 # We're done! :-) 29631 BOOT_JDK_FOUND=yes 29632 29633 # Only process if variable expands to non-empty 29634 29635 if test "x$BOOT_JDK" != x; then 29636 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29637 29638 # Input might be given as Windows format, start by converting to 29639 # unix format. 29640 path="$BOOT_JDK" 29641 new_path=`$CYGPATH -u "$path"` 29642 29643 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29644 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29645 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29646 # "foo.exe" is OK but "foo" is an error. 29647 # 29648 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29649 # It is also a way to make sure we got the proper file name for the real test later on. 29650 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29651 if test "x$test_shortpath" = x; then 29652 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29653 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29654 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29655 fi 29656 29657 # Call helper function which possibly converts this using DOS-style short mode. 29658 # If so, the updated path is stored in $new_path. 29659 29660 input_path="$new_path" 29661 # Check if we need to convert this using DOS-style short mode. If the path 29662 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29663 # take no chances and rewrite it. 29664 # Note: m4 eats our [], so we need to use [ and ] instead. 29665 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29666 if test "x$has_forbidden_chars" != x; then 29667 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29668 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29669 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29670 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29671 # Going to short mode and back again did indeed matter. Since short mode is 29672 # case insensitive, let's make it lowercase to improve readability. 29673 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29674 # Now convert it back to Unix-style (cygpath) 29675 input_path=`$CYGPATH -u "$shortmode_path"` 29676 new_path="$input_path" 29677 fi 29678 fi 29679 29680 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29681 if test "x$test_cygdrive_prefix" = x; then 29682 # As a simple fix, exclude /usr/bin since it's not a real path. 29683 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29684 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29685 # a path prefixed by /cygdrive for fixpath to work. 29686 new_path="$CYGWIN_ROOT_PATH$input_path" 29687 fi 29688 fi 29689 29690 29691 if test "x$path" != "x$new_path"; then 29692 BOOT_JDK="$new_path" 29693 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29694 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29695 fi 29696 29697 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29698 29699 path="$BOOT_JDK" 29700 has_colon=`$ECHO $path | $GREP ^.:` 29701 new_path="$path" 29702 if test "x$has_colon" = x; then 29703 # Not in mixed or Windows style, start by that. 29704 new_path=`cmd //c echo $path` 29705 fi 29706 29707 29708 input_path="$new_path" 29709 # Check if we need to convert this using DOS-style short mode. If the path 29710 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29711 # take no chances and rewrite it. 29712 # Note: m4 eats our [], so we need to use [ and ] instead. 29713 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29714 if test "x$has_forbidden_chars" != x; then 29715 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29716 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29717 fi 29718 29719 29720 windows_path="$new_path" 29721 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29722 unix_path=`$CYGPATH -u "$windows_path"` 29723 new_path="$unix_path" 29724 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29725 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29726 new_path="$unix_path" 29727 fi 29728 29729 if test "x$path" != "x$new_path"; then 29730 BOOT_JDK="$new_path" 29731 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29732 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29733 fi 29734 29735 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29736 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29737 29738 else 29739 # We're on a unix platform. Hooray! :) 29740 path="$BOOT_JDK" 29741 has_space=`$ECHO "$path" | $GREP " "` 29742 if test "x$has_space" != x; then 29743 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29744 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29745 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29746 fi 29747 29748 # Use eval to expand a potential ~ 29749 eval path="$path" 29750 if test ! -f "$path" && test ! -d "$path"; then 29751 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29752 fi 29753 29754 if test -d "$path"; then 29755 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29756 else 29757 dir="`$DIRNAME "$path"`" 29758 base="`$BASENAME "$path"`" 29759 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29760 fi 29761 fi 29762 fi 29763 29764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29765 $as_echo_n "checking for Boot JDK... " >&6; } 29766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29767 $as_echo "$BOOT_JDK" >&6; } 29768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29769 $as_echo_n "checking Boot JDK version... " >&6; } 29770 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29772 $as_echo "$BOOT_JDK_VERSION" >&6; } 29773 fi # end check jdk version 29774 fi # end check javac 29775 fi # end check java 29776 fi # end check boot jdk found 29777 fi 29778 29779 29780 if test "x$BOOT_JDK_FOUND" = xno; then 29781 # Now execute the test 29782 29783 BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines" 29784 BOOT_JDK_SUFFIX="/Contents/Home" 29785 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29786 if test "x$ALL_JDKS_FOUND" != x; then 29787 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29788 29789 if test "x$BOOT_JDK_FOUND" = xno; then 29790 # Now execute the test 29791 29792 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29793 if test -d "$BOOT_JDK"; then 29794 BOOT_JDK_FOUND=maybe 29795 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29796 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29797 fi 29798 29799 29800 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29801 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29802 # Do we have a bin/java? 29803 if test ! -x "$BOOT_JDK/bin/java"; then 29804 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29805 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29806 BOOT_JDK_FOUND=no 29807 else 29808 # Do we have a bin/javac? 29809 if test ! -x "$BOOT_JDK/bin/javac"; then 29810 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29811 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29812 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29813 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29814 BOOT_JDK_FOUND=no 29815 else 29816 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29817 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29818 29819 # Extra M4 quote needed to protect [] in grep expression. 29820 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 29821 if test "x$FOUND_CORRECT_VERSION" = x; then 29822 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29823 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29824 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 29825 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 29826 BOOT_JDK_FOUND=no 29827 else 29828 # We're done! :-) 29829 BOOT_JDK_FOUND=yes 29830 29831 # Only process if variable expands to non-empty 29832 29833 if test "x$BOOT_JDK" != x; then 29834 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29835 29836 # Input might be given as Windows format, start by converting to 29837 # unix format. 29838 path="$BOOT_JDK" 29839 new_path=`$CYGPATH -u "$path"` 29840 29841 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29842 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29843 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29844 # "foo.exe" is OK but "foo" is an error. 29845 # 29846 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29847 # It is also a way to make sure we got the proper file name for the real test later on. 29848 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29849 if test "x$test_shortpath" = x; then 29850 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29851 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29852 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29853 fi 29854 29855 # Call helper function which possibly converts this using DOS-style short mode. 29856 # If so, the updated path is stored in $new_path. 29857 29858 input_path="$new_path" 29859 # Check if we need to convert this using DOS-style short mode. If the path 29860 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29861 # take no chances and rewrite it. 29862 # Note: m4 eats our [], so we need to use [ and ] instead. 29863 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29864 if test "x$has_forbidden_chars" != x; then 29865 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29866 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29867 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29868 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29869 # Going to short mode and back again did indeed matter. Since short mode is 29870 # case insensitive, let's make it lowercase to improve readability. 29871 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29872 # Now convert it back to Unix-style (cygpath) 29873 input_path=`$CYGPATH -u "$shortmode_path"` 29874 new_path="$input_path" 29875 fi 29876 fi 29877 29878 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29879 if test "x$test_cygdrive_prefix" = x; then 29880 # As a simple fix, exclude /usr/bin since it's not a real path. 29881 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29882 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29883 # a path prefixed by /cygdrive for fixpath to work. 29884 new_path="$CYGWIN_ROOT_PATH$input_path" 29885 fi 29886 fi 29887 29888 29889 if test "x$path" != "x$new_path"; then 29890 BOOT_JDK="$new_path" 29891 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29892 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29893 fi 29894 29895 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29896 29897 path="$BOOT_JDK" 29898 has_colon=`$ECHO $path | $GREP ^.:` 29899 new_path="$path" 29900 if test "x$has_colon" = x; then 29901 # Not in mixed or Windows style, start by that. 29902 new_path=`cmd //c echo $path` 29903 fi 29904 29905 29906 input_path="$new_path" 29907 # Check if we need to convert this using DOS-style short mode. If the path 29908 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29909 # take no chances and rewrite it. 29910 # Note: m4 eats our [], so we need to use [ and ] instead. 29911 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29912 if test "x$has_forbidden_chars" != x; then 29913 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29914 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29915 fi 29916 29917 29918 windows_path="$new_path" 29919 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29920 unix_path=`$CYGPATH -u "$windows_path"` 29921 new_path="$unix_path" 29922 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29923 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29924 new_path="$unix_path" 29925 fi 29926 29927 if test "x$path" != "x$new_path"; then 29928 BOOT_JDK="$new_path" 29929 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29930 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29931 fi 29932 29933 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29934 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29935 29936 else 29937 # We're on a unix platform. Hooray! :) 29938 path="$BOOT_JDK" 29939 has_space=`$ECHO "$path" | $GREP " "` 29940 if test "x$has_space" != x; then 29941 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29942 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29943 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29944 fi 29945 29946 # Use eval to expand a potential ~ 29947 eval path="$path" 29948 if test ! -f "$path" && test ! -d "$path"; then 29949 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29950 fi 29951 29952 if test -d "$path"; then 29953 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29954 else 29955 dir="`$DIRNAME "$path"`" 29956 base="`$BASENAME "$path"`" 29957 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29958 fi 29959 fi 29960 fi 29961 29962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29963 $as_echo_n "checking for Boot JDK... " >&6; } 29964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29965 $as_echo "$BOOT_JDK" >&6; } 29966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29967 $as_echo_n "checking Boot JDK version... " >&6; } 29968 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29970 $as_echo "$BOOT_JDK_VERSION" >&6; } 29971 fi # end check jdk version 29972 fi # end check javac 29973 fi # end check java 29974 fi # end check boot jdk found 29975 fi 29976 29977 done 29978 fi 29979 29980 29981 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29982 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29983 # Do we have a bin/java? 29984 if test ! -x "$BOOT_JDK/bin/java"; then 29985 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29986 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29987 BOOT_JDK_FOUND=no 29988 else 29989 # Do we have a bin/javac? 29990 if test ! -x "$BOOT_JDK/bin/javac"; then 29991 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29992 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29993 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29994 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29995 BOOT_JDK_FOUND=no 29996 else 29997 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29998 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29999 30000 # Extra M4 quote needed to protect [] in grep expression. 30001 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 30002 if test "x$FOUND_CORRECT_VERSION" = x; then 30003 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 30004 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 30005 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 30006 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 30007 BOOT_JDK_FOUND=no 30008 else 30009 # We're done! :-) 30010 BOOT_JDK_FOUND=yes 30011 30012 # Only process if variable expands to non-empty 30013 30014 if test "x$BOOT_JDK" != x; then 30015 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30016 30017 # Input might be given as Windows format, start by converting to 30018 # unix format. 30019 path="$BOOT_JDK" 30020 new_path=`$CYGPATH -u "$path"` 30021 30022 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30023 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30024 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30025 # "foo.exe" is OK but "foo" is an error. 30026 # 30027 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30028 # It is also a way to make sure we got the proper file name for the real test later on. 30029 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30030 if test "x$test_shortpath" = x; then 30031 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30032 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30033 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30034 fi 30035 30036 # Call helper function which possibly converts this using DOS-style short mode. 30037 # If so, the updated path is stored in $new_path. 30038 30039 input_path="$new_path" 30040 # Check if we need to convert this using DOS-style short mode. If the path 30041 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30042 # take no chances and rewrite it. 30043 # Note: m4 eats our [], so we need to use [ and ] instead. 30044 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30045 if test "x$has_forbidden_chars" != x; then 30046 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30047 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30048 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30049 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30050 # Going to short mode and back again did indeed matter. Since short mode is 30051 # case insensitive, let's make it lowercase to improve readability. 30052 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30053 # Now convert it back to Unix-style (cygpath) 30054 input_path=`$CYGPATH -u "$shortmode_path"` 30055 new_path="$input_path" 30056 fi 30057 fi 30058 30059 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30060 if test "x$test_cygdrive_prefix" = x; then 30061 # As a simple fix, exclude /usr/bin since it's not a real path. 30062 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30063 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30064 # a path prefixed by /cygdrive for fixpath to work. 30065 new_path="$CYGWIN_ROOT_PATH$input_path" 30066 fi 30067 fi 30068 30069 30070 if test "x$path" != "x$new_path"; then 30071 BOOT_JDK="$new_path" 30072 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30073 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30074 fi 30075 30076 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30077 30078 path="$BOOT_JDK" 30079 has_colon=`$ECHO $path | $GREP ^.:` 30080 new_path="$path" 30081 if test "x$has_colon" = x; then 30082 # Not in mixed or Windows style, start by that. 30083 new_path=`cmd //c echo $path` 30084 fi 30085 30086 30087 input_path="$new_path" 30088 # Check if we need to convert this using DOS-style short mode. If the path 30089 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30090 # take no chances and rewrite it. 30091 # Note: m4 eats our [], so we need to use [ and ] instead. 30092 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30093 if test "x$has_forbidden_chars" != x; then 30094 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30095 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30096 fi 30097 30098 30099 windows_path="$new_path" 30100 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30101 unix_path=`$CYGPATH -u "$windows_path"` 30102 new_path="$unix_path" 30103 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30104 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30105 new_path="$unix_path" 30106 fi 30107 30108 if test "x$path" != "x$new_path"; then 30109 BOOT_JDK="$new_path" 30110 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30111 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30112 fi 30113 30114 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30115 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30116 30117 else 30118 # We're on a unix platform. Hooray! :) 30119 path="$BOOT_JDK" 30120 has_space=`$ECHO "$path" | $GREP " "` 30121 if test "x$has_space" != x; then 30122 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30123 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30124 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30125 fi 30126 30127 # Use eval to expand a potential ~ 30128 eval path="$path" 30129 if test ! -f "$path" && test ! -d "$path"; then 30130 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30131 fi 30132 30133 if test -d "$path"; then 30134 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30135 else 30136 dir="`$DIRNAME "$path"`" 30137 base="`$BASENAME "$path"`" 30138 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30139 fi 30140 fi 30141 fi 30142 30143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30144 $as_echo_n "checking for Boot JDK... " >&6; } 30145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30146 $as_echo "$BOOT_JDK" >&6; } 30147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30148 $as_echo_n "checking Boot JDK version... " >&6; } 30149 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30151 $as_echo "$BOOT_JDK_VERSION" >&6; } 30152 fi # end check jdk version 30153 fi # end check javac 30154 fi # end check java 30155 fi # end check boot jdk found 30156 fi 30157 30158 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 30159 30160 if test "x$BOOT_JDK_FOUND" = xno; then 30161 # Now execute the test 30162 30163 BOOT_JDK_PREFIX="/usr/lib/jvm" 30164 BOOT_JDK_SUFFIX="" 30165 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 30166 if test "x$ALL_JDKS_FOUND" != x; then 30167 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 30168 30169 if test "x$BOOT_JDK_FOUND" = xno; then 30170 # Now execute the test 30171 30172 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 30173 if test -d "$BOOT_JDK"; then 30174 BOOT_JDK_FOUND=maybe 30175 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 30176 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 30177 fi 30178 30179 30180 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30181 if test "x$BOOT_JDK_FOUND" = xmaybe; then 30182 # Do we have a bin/java? 30183 if test ! -x "$BOOT_JDK/bin/java"; then 30184 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 30185 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 30186 BOOT_JDK_FOUND=no 30187 else 30188 # Do we have a bin/javac? 30189 if test ! -x "$BOOT_JDK/bin/javac"; then 30190 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 30191 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 30192 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 30193 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 30194 BOOT_JDK_FOUND=no 30195 else 30196 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30197 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30198 30199 # Extra M4 quote needed to protect [] in grep expression. 30200 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 30201 if test "x$FOUND_CORRECT_VERSION" = x; then 30202 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 30203 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 30204 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 30205 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 30206 BOOT_JDK_FOUND=no 30207 else 30208 # We're done! :-) 30209 BOOT_JDK_FOUND=yes 30210 30211 # Only process if variable expands to non-empty 30212 30213 if test "x$BOOT_JDK" != x; then 30214 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30215 30216 # Input might be given as Windows format, start by converting to 30217 # unix format. 30218 path="$BOOT_JDK" 30219 new_path=`$CYGPATH -u "$path"` 30220 30221 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30222 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30223 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30224 # "foo.exe" is OK but "foo" is an error. 30225 # 30226 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30227 # It is also a way to make sure we got the proper file name for the real test later on. 30228 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30229 if test "x$test_shortpath" = x; then 30230 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30231 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30232 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30233 fi 30234 30235 # Call helper function which possibly converts this using DOS-style short mode. 30236 # If so, the updated path is stored in $new_path. 30237 30238 input_path="$new_path" 30239 # Check if we need to convert this using DOS-style short mode. If the path 30240 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30241 # take no chances and rewrite it. 30242 # Note: m4 eats our [], so we need to use [ and ] instead. 30243 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30244 if test "x$has_forbidden_chars" != x; then 30245 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30246 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30247 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30248 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30249 # Going to short mode and back again did indeed matter. Since short mode is 30250 # case insensitive, let's make it lowercase to improve readability. 30251 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30252 # Now convert it back to Unix-style (cygpath) 30253 input_path=`$CYGPATH -u "$shortmode_path"` 30254 new_path="$input_path" 30255 fi 30256 fi 30257 30258 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30259 if test "x$test_cygdrive_prefix" = x; then 30260 # As a simple fix, exclude /usr/bin since it's not a real path. 30261 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30262 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30263 # a path prefixed by /cygdrive for fixpath to work. 30264 new_path="$CYGWIN_ROOT_PATH$input_path" 30265 fi 30266 fi 30267 30268 30269 if test "x$path" != "x$new_path"; then 30270 BOOT_JDK="$new_path" 30271 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30272 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30273 fi 30274 30275 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30276 30277 path="$BOOT_JDK" 30278 has_colon=`$ECHO $path | $GREP ^.:` 30279 new_path="$path" 30280 if test "x$has_colon" = x; then 30281 # Not in mixed or Windows style, start by that. 30282 new_path=`cmd //c echo $path` 30283 fi 30284 30285 30286 input_path="$new_path" 30287 # Check if we need to convert this using DOS-style short mode. If the path 30288 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30289 # take no chances and rewrite it. 30290 # Note: m4 eats our [], so we need to use [ and ] instead. 30291 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30292 if test "x$has_forbidden_chars" != x; then 30293 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30294 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30295 fi 30296 30297 30298 windows_path="$new_path" 30299 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30300 unix_path=`$CYGPATH -u "$windows_path"` 30301 new_path="$unix_path" 30302 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30303 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30304 new_path="$unix_path" 30305 fi 30306 30307 if test "x$path" != "x$new_path"; then 30308 BOOT_JDK="$new_path" 30309 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30310 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30311 fi 30312 30313 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30314 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30315 30316 else 30317 # We're on a unix platform. Hooray! :) 30318 path="$BOOT_JDK" 30319 has_space=`$ECHO "$path" | $GREP " "` 30320 if test "x$has_space" != x; then 30321 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30322 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30323 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30324 fi 30325 30326 # Use eval to expand a potential ~ 30327 eval path="$path" 30328 if test ! -f "$path" && test ! -d "$path"; then 30329 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30330 fi 30331 30332 if test -d "$path"; then 30333 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30334 else 30335 dir="`$DIRNAME "$path"`" 30336 base="`$BASENAME "$path"`" 30337 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30338 fi 30339 fi 30340 fi 30341 30342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30343 $as_echo_n "checking for Boot JDK... " >&6; } 30344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30345 $as_echo "$BOOT_JDK" >&6; } 30346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30347 $as_echo_n "checking Boot JDK version... " >&6; } 30348 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30350 $as_echo "$BOOT_JDK_VERSION" >&6; } 30351 fi # end check jdk version 30352 fi # end check javac 30353 fi # end check java 30354 fi # end check boot jdk found 30355 fi 30356 30357 done 30358 fi 30359 30360 30361 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30362 if test "x$BOOT_JDK_FOUND" = xmaybe; then 30363 # Do we have a bin/java? 30364 if test ! -x "$BOOT_JDK/bin/java"; then 30365 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 30366 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 30367 BOOT_JDK_FOUND=no 30368 else 30369 # Do we have a bin/javac? 30370 if test ! -x "$BOOT_JDK/bin/javac"; then 30371 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 30372 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 30373 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 30374 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 30375 BOOT_JDK_FOUND=no 30376 else 30377 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30378 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30379 30380 # Extra M4 quote needed to protect [] in grep expression. 30381 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 30382 if test "x$FOUND_CORRECT_VERSION" = x; then 30383 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 30384 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 30385 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 30386 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 30387 BOOT_JDK_FOUND=no 30388 else 30389 # We're done! :-) 30390 BOOT_JDK_FOUND=yes 30391 30392 # Only process if variable expands to non-empty 30393 30394 if test "x$BOOT_JDK" != x; then 30395 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30396 30397 # Input might be given as Windows format, start by converting to 30398 # unix format. 30399 path="$BOOT_JDK" 30400 new_path=`$CYGPATH -u "$path"` 30401 30402 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30403 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30404 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30405 # "foo.exe" is OK but "foo" is an error. 30406 # 30407 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30408 # It is also a way to make sure we got the proper file name for the real test later on. 30409 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30410 if test "x$test_shortpath" = x; then 30411 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30412 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30413 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30414 fi 30415 30416 # Call helper function which possibly converts this using DOS-style short mode. 30417 # If so, the updated path is stored in $new_path. 30418 30419 input_path="$new_path" 30420 # Check if we need to convert this using DOS-style short mode. If the path 30421 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30422 # take no chances and rewrite it. 30423 # Note: m4 eats our [], so we need to use [ and ] instead. 30424 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30425 if test "x$has_forbidden_chars" != x; then 30426 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30427 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30428 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30429 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30430 # Going to short mode and back again did indeed matter. Since short mode is 30431 # case insensitive, let's make it lowercase to improve readability. 30432 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30433 # Now convert it back to Unix-style (cygpath) 30434 input_path=`$CYGPATH -u "$shortmode_path"` 30435 new_path="$input_path" 30436 fi 30437 fi 30438 30439 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30440 if test "x$test_cygdrive_prefix" = x; then 30441 # As a simple fix, exclude /usr/bin since it's not a real path. 30442 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30443 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30444 # a path prefixed by /cygdrive for fixpath to work. 30445 new_path="$CYGWIN_ROOT_PATH$input_path" 30446 fi 30447 fi 30448 30449 30450 if test "x$path" != "x$new_path"; then 30451 BOOT_JDK="$new_path" 30452 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30453 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30454 fi 30455 30456 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30457 30458 path="$BOOT_JDK" 30459 has_colon=`$ECHO $path | $GREP ^.:` 30460 new_path="$path" 30461 if test "x$has_colon" = x; then 30462 # Not in mixed or Windows style, start by that. 30463 new_path=`cmd //c echo $path` 30464 fi 30465 30466 30467 input_path="$new_path" 30468 # Check if we need to convert this using DOS-style short mode. If the path 30469 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30470 # take no chances and rewrite it. 30471 # Note: m4 eats our [], so we need to use [ and ] instead. 30472 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30473 if test "x$has_forbidden_chars" != x; then 30474 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30475 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30476 fi 30477 30478 30479 windows_path="$new_path" 30480 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30481 unix_path=`$CYGPATH -u "$windows_path"` 30482 new_path="$unix_path" 30483 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30484 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30485 new_path="$unix_path" 30486 fi 30487 30488 if test "x$path" != "x$new_path"; then 30489 BOOT_JDK="$new_path" 30490 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30491 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30492 fi 30493 30494 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30495 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30496 30497 else 30498 # We're on a unix platform. Hooray! :) 30499 path="$BOOT_JDK" 30500 has_space=`$ECHO "$path" | $GREP " "` 30501 if test "x$has_space" != x; then 30502 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30503 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30504 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30505 fi 30506 30507 # Use eval to expand a potential ~ 30508 eval path="$path" 30509 if test ! -f "$path" && test ! -d "$path"; then 30510 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30511 fi 30512 30513 if test -d "$path"; then 30514 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30515 else 30516 dir="`$DIRNAME "$path"`" 30517 base="`$BASENAME "$path"`" 30518 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30519 fi 30520 fi 30521 fi 30522 30523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30524 $as_echo_n "checking for Boot JDK... " >&6; } 30525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30526 $as_echo "$BOOT_JDK" >&6; } 30527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30528 $as_echo_n "checking Boot JDK version... " >&6; } 30529 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30531 $as_echo "$BOOT_JDK_VERSION" >&6; } 30532 fi # end check jdk version 30533 fi # end check javac 30534 fi # end check java 30535 fi # end check boot jdk found 30536 fi 30537 30538 fi 30539 30540 30541 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30542 if test "x$BOOT_JDK_FOUND" = xmaybe; then 30543 # Do we have a bin/java? 30544 if test ! -x "$BOOT_JDK/bin/java"; then 30545 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 30546 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 30547 BOOT_JDK_FOUND=no 30548 else 30549 # Do we have a bin/javac? 30550 if test ! -x "$BOOT_JDK/bin/javac"; then 30551 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 30552 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 30553 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 30554 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 30555 BOOT_JDK_FOUND=no 30556 else 30557 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30558 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30559 30560 # Extra M4 quote needed to protect [] in grep expression. 30561 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"|(1\.[89]\.)'` 30562 if test "x$FOUND_CORRECT_VERSION" = x; then 30563 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 30564 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 30565 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8, 9 or 10)" >&5 30566 $as_echo "$as_me: (Your Boot JDK must be version 8, 9 or 10)" >&6;} 30567 BOOT_JDK_FOUND=no 30568 else 30569 # We're done! :-) 30570 BOOT_JDK_FOUND=yes 30571 30572 # Only process if variable expands to non-empty 30573 30574 if test "x$BOOT_JDK" != x; then 30575 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30576 30577 # Input might be given as Windows format, start by converting to 30578 # unix format. 30579 path="$BOOT_JDK" 30580 new_path=`$CYGPATH -u "$path"` 30581 30582 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30583 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30584 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30585 # "foo.exe" is OK but "foo" is an error. 30586 # 30587 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30588 # It is also a way to make sure we got the proper file name for the real test later on. 30589 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30590 if test "x$test_shortpath" = x; then 30591 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30592 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30593 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30594 fi 30595 30596 # Call helper function which possibly converts this using DOS-style short mode. 30597 # If so, the updated path is stored in $new_path. 30598 30599 input_path="$new_path" 30600 # Check if we need to convert this using DOS-style short mode. If the path 30601 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30602 # take no chances and rewrite it. 30603 # Note: m4 eats our [], so we need to use [ and ] instead. 30604 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30605 if test "x$has_forbidden_chars" != x; then 30606 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30607 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30608 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30609 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30610 # Going to short mode and back again did indeed matter. Since short mode is 30611 # case insensitive, let's make it lowercase to improve readability. 30612 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30613 # Now convert it back to Unix-style (cygpath) 30614 input_path=`$CYGPATH -u "$shortmode_path"` 30615 new_path="$input_path" 30616 fi 30617 fi 30618 30619 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30620 if test "x$test_cygdrive_prefix" = x; then 30621 # As a simple fix, exclude /usr/bin since it's not a real path. 30622 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30623 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30624 # a path prefixed by /cygdrive for fixpath to work. 30625 new_path="$CYGWIN_ROOT_PATH$input_path" 30626 fi 30627 fi 30628 30629 30630 if test "x$path" != "x$new_path"; then 30631 BOOT_JDK="$new_path" 30632 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30633 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30634 fi 30635 30636 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30637 30638 path="$BOOT_JDK" 30639 has_colon=`$ECHO $path | $GREP ^.:` 30640 new_path="$path" 30641 if test "x$has_colon" = x; then 30642 # Not in mixed or Windows style, start by that. 30643 new_path=`cmd //c echo $path` 30644 fi 30645 30646 30647 input_path="$new_path" 30648 # Check if we need to convert this using DOS-style short mode. If the path 30649 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30650 # take no chances and rewrite it. 30651 # Note: m4 eats our [], so we need to use [ and ] instead. 30652 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30653 if test "x$has_forbidden_chars" != x; then 30654 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30655 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30656 fi 30657 30658 30659 windows_path="$new_path" 30660 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30661 unix_path=`$CYGPATH -u "$windows_path"` 30662 new_path="$unix_path" 30663 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30664 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30665 new_path="$unix_path" 30666 fi 30667 30668 if test "x$path" != "x$new_path"; then 30669 BOOT_JDK="$new_path" 30670 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30671 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30672 fi 30673 30674 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30675 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30676 30677 else 30678 # We're on a unix platform. Hooray! :) 30679 path="$BOOT_JDK" 30680 has_space=`$ECHO "$path" | $GREP " "` 30681 if test "x$has_space" != x; then 30682 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30683 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30684 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30685 fi 30686 30687 # Use eval to expand a potential ~ 30688 eval path="$path" 30689 if test ! -f "$path" && test ! -d "$path"; then 30690 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30691 fi 30692 30693 if test -d "$path"; then 30694 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30695 else 30696 dir="`$DIRNAME "$path"`" 30697 base="`$BASENAME "$path"`" 30698 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30699 fi 30700 fi 30701 fi 30702 30703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30704 $as_echo_n "checking for Boot JDK... " >&6; } 30705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30706 $as_echo "$BOOT_JDK" >&6; } 30707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30708 $as_echo_n "checking Boot JDK version... " >&6; } 30709 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30711 $as_echo "$BOOT_JDK_VERSION" >&6; } 30712 fi # end check jdk version 30713 fi # end check javac 30714 fi # end check java 30715 fi # end check boot jdk found 30716 fi 30717 30718 30719 # If we haven't found anything yet, we've truly lost. Give up. 30720 if test "x$BOOT_JDK_FOUND" = xno; then 30721 30722 # Print a helpful message on how to acquire the necessary build dependency. 30723 # openjdk is the help tag: freetype, cups, alsa etc 30724 MISSING_DEPENDENCY=openjdk 30725 30726 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30727 cygwin_help $MISSING_DEPENDENCY 30728 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30729 msys_help $MISSING_DEPENDENCY 30730 else 30731 PKGHANDLER_COMMAND= 30732 30733 case $PKGHANDLER in 30734 apt-get) 30735 apt_help $MISSING_DEPENDENCY ;; 30736 yum) 30737 yum_help $MISSING_DEPENDENCY ;; 30738 brew) 30739 brew_help $MISSING_DEPENDENCY ;; 30740 port) 30741 port_help $MISSING_DEPENDENCY ;; 30742 pkgutil) 30743 pkgutil_help $MISSING_DEPENDENCY ;; 30744 pkgadd) 30745 pkgadd_help $MISSING_DEPENDENCY ;; 30746 esac 30747 30748 if test "x$PKGHANDLER_COMMAND" != x; then 30749 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 30750 fi 30751 fi 30752 30753 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5 30754 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;} 30755 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitly setting --with-boot-jdk" >&5 30756 $as_echo "$as_me: This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30757 as_fn_error $? "Cannot continue" "$LINENO" 5 30758 fi 30759 30760 30761 30762 # Setup tools from the Boot JDK. 30763 30764 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30765 30766 # Publish this variable in the help. 30767 30768 30769 if [ -z "${JAVA+x}" ]; then 30770 # The variable is not set by user, try to locate tool using the code snippet 30771 30772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 30773 $as_echo_n "checking for java in Boot JDK... " >&6; } 30774 JAVA=$BOOT_JDK/bin/java 30775 if test ! -x $JAVA; then 30776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30777 $as_echo "not found" >&6; } 30778 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30779 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30780 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 30781 fi 30782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30783 $as_echo "ok" >&6; } 30784 30785 30786 else 30787 # The variable is set, but is it from the command line or the environment? 30788 30789 # Try to remove the string !JAVA! from our list. 30790 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/} 30791 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30792 # If it failed, the variable was not from the command line. Ignore it, 30793 # but warn the user (except for BASH, which is always set by the calling BASH). 30794 if test "xJAVA" != xBASH; then 30795 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5 30796 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;} 30797 fi 30798 # Try to locate tool using the code snippet 30799 30800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 30801 $as_echo_n "checking for java in Boot JDK... " >&6; } 30802 JAVA=$BOOT_JDK/bin/java 30803 if test ! -x $JAVA; then 30804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30805 $as_echo "not found" >&6; } 30806 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30807 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30808 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 30809 fi 30810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30811 $as_echo "ok" >&6; } 30812 30813 30814 else 30815 # If it succeeded, then it was overridden by the user. We will use it 30816 # for the tool. 30817 30818 # First remove it from the list of overridden variables, so we can test 30819 # for unknown variables in the end. 30820 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30821 30822 # Check if we try to supply an empty value 30823 if test "x$JAVA" = x; then 30824 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVA= (no value)" >&5 30825 $as_echo "$as_me: Setting user supplied tool JAVA= (no value)" >&6;} 30826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30827 $as_echo_n "checking for JAVA... " >&6; } 30828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30829 $as_echo "disabled" >&6; } 30830 else 30831 # Check if the provided tool contains a complete path. 30832 tool_specified="$JAVA" 30833 tool_basename="${tool_specified##*/}" 30834 if test "x$tool_basename" = "x$tool_specified"; then 30835 # A command without a complete path is provided, search $PATH. 30836 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5 30837 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;} 30838 # Extract the first word of "$tool_basename", so it can be a program name with args. 30839 set dummy $tool_basename; ac_word=$2 30840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30841 $as_echo_n "checking for $ac_word... " >&6; } 30842 if ${ac_cv_path_JAVA+:} false; then : 30843 $as_echo_n "(cached) " >&6 30844 else 30845 case $JAVA in 30846 [\\/]* | ?:[\\/]*) 30847 ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path. 30848 ;; 30849 *) 30850 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30851 for as_dir in $PATH 30852 do 30853 IFS=$as_save_IFS 30854 test -z "$as_dir" && as_dir=. 30855 for ac_exec_ext in '' $ac_executable_extensions; do 30856 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30857 ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext" 30858 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30859 break 2 30860 fi 30861 done 30862 done 30863 IFS=$as_save_IFS 30864 30865 ;; 30866 esac 30867 fi 30868 JAVA=$ac_cv_path_JAVA 30869 if test -n "$JAVA"; then 30870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5 30871 $as_echo "$JAVA" >&6; } 30872 else 30873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30874 $as_echo "no" >&6; } 30875 fi 30876 30877 30878 if test "x$JAVA" = x; then 30879 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30880 fi 30881 else 30882 # Otherwise we believe it is a complete path. Use it as it is. 30883 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5 30884 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;} 30885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30886 $as_echo_n "checking for JAVA... " >&6; } 30887 if test ! -x "$tool_specified"; then 30888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30889 $as_echo "not found" >&6; } 30890 as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5 30891 fi 30892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30893 $as_echo "$tool_specified" >&6; } 30894 fi 30895 fi 30896 fi 30897 30898 fi 30899 30900 30901 30902 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30903 30904 # Publish this variable in the help. 30905 30906 30907 if [ -z "${JAVAC+x}" ]; then 30908 # The variable is not set by user, try to locate tool using the code snippet 30909 30910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30911 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30912 JAVAC=$BOOT_JDK/bin/javac 30913 if test ! -x $JAVAC; then 30914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30915 $as_echo "not found" >&6; } 30916 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30917 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30918 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30919 fi 30920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30921 $as_echo "ok" >&6; } 30922 30923 30924 else 30925 # The variable is set, but is it from the command line or the environment? 30926 30927 # Try to remove the string !JAVAC! from our list. 30928 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/} 30929 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30930 # If it failed, the variable was not from the command line. Ignore it, 30931 # but warn the user (except for BASH, which is always set by the calling BASH). 30932 if test "xJAVAC" != xBASH; then 30933 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5 30934 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;} 30935 fi 30936 # Try to locate tool using the code snippet 30937 30938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30939 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30940 JAVAC=$BOOT_JDK/bin/javac 30941 if test ! -x $JAVAC; then 30942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30943 $as_echo "not found" >&6; } 30944 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30945 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30946 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30947 fi 30948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30949 $as_echo "ok" >&6; } 30950 30951 30952 else 30953 # If it succeeded, then it was overridden by the user. We will use it 30954 # for the tool. 30955 30956 # First remove it from the list of overridden variables, so we can test 30957 # for unknown variables in the end. 30958 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30959 30960 # Check if we try to supply an empty value 30961 if test "x$JAVAC" = x; then 30962 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAC= (no value)" >&5 30963 $as_echo "$as_me: Setting user supplied tool JAVAC= (no value)" >&6;} 30964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30965 $as_echo_n "checking for JAVAC... " >&6; } 30966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30967 $as_echo "disabled" >&6; } 30968 else 30969 # Check if the provided tool contains a complete path. 30970 tool_specified="$JAVAC" 30971 tool_basename="${tool_specified##*/}" 30972 if test "x$tool_basename" = "x$tool_specified"; then 30973 # A command without a complete path is provided, search $PATH. 30974 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5 30975 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;} 30976 # Extract the first word of "$tool_basename", so it can be a program name with args. 30977 set dummy $tool_basename; ac_word=$2 30978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30979 $as_echo_n "checking for $ac_word... " >&6; } 30980 if ${ac_cv_path_JAVAC+:} false; then : 30981 $as_echo_n "(cached) " >&6 30982 else 30983 case $JAVAC in 30984 [\\/]* | ?:[\\/]*) 30985 ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path. 30986 ;; 30987 *) 30988 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30989 for as_dir in $PATH 30990 do 30991 IFS=$as_save_IFS 30992 test -z "$as_dir" && as_dir=. 30993 for ac_exec_ext in '' $ac_executable_extensions; do 30994 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30995 ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext" 30996 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30997 break 2 30998 fi 30999 done 31000 done 31001 IFS=$as_save_IFS 31002 31003 ;; 31004 esac 31005 fi 31006 JAVAC=$ac_cv_path_JAVAC 31007 if test -n "$JAVAC"; then 31008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5 31009 $as_echo "$JAVAC" >&6; } 31010 else 31011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31012 $as_echo "no" >&6; } 31013 fi 31014 31015 31016 if test "x$JAVAC" = x; then 31017 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31018 fi 31019 else 31020 # Otherwise we believe it is a complete path. Use it as it is. 31021 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5 31022 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;} 31023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 31024 $as_echo_n "checking for JAVAC... " >&6; } 31025 if test ! -x "$tool_specified"; then 31026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31027 $as_echo "not found" >&6; } 31028 as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5 31029 fi 31030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31031 $as_echo "$tool_specified" >&6; } 31032 fi 31033 fi 31034 fi 31035 31036 fi 31037 31038 31039 31040 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 31041 31042 # Publish this variable in the help. 31043 31044 31045 if [ -z "${JAVAH+x}" ]; then 31046 # The variable is not set by user, try to locate tool using the code snippet 31047 31048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 31049 $as_echo_n "checking for javah in Boot JDK... " >&6; } 31050 JAVAH=$BOOT_JDK/bin/javah 31051 if test ! -x $JAVAH; then 31052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31053 $as_echo "not found" >&6; } 31054 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31055 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31056 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 31057 fi 31058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31059 $as_echo "ok" >&6; } 31060 31061 31062 else 31063 # The variable is set, but is it from the command line or the environment? 31064 31065 # Try to remove the string !JAVAH! from our list. 31066 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/} 31067 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 31068 # If it failed, the variable was not from the command line. Ignore it, 31069 # but warn the user (except for BASH, which is always set by the calling BASH). 31070 if test "xJAVAH" != xBASH; then 31071 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5 31072 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;} 31073 fi 31074 # Try to locate tool using the code snippet 31075 31076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 31077 $as_echo_n "checking for javah in Boot JDK... " >&6; } 31078 JAVAH=$BOOT_JDK/bin/javah 31079 if test ! -x $JAVAH; then 31080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31081 $as_echo "not found" >&6; } 31082 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31083 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31084 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 31085 fi 31086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31087 $as_echo "ok" >&6; } 31088 31089 31090 else 31091 # If it succeeded, then it was overridden by the user. We will use it 31092 # for the tool. 31093 31094 # First remove it from the list of overridden variables, so we can test 31095 # for unknown variables in the end. 31096 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 31097 31098 # Check if we try to supply an empty value 31099 if test "x$JAVAH" = x; then 31100 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAH= (no value)" >&5 31101 $as_echo "$as_me: Setting user supplied tool JAVAH= (no value)" >&6;} 31102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 31103 $as_echo_n "checking for JAVAH... " >&6; } 31104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 31105 $as_echo "disabled" >&6; } 31106 else 31107 # Check if the provided tool contains a complete path. 31108 tool_specified="$JAVAH" 31109 tool_basename="${tool_specified##*/}" 31110 if test "x$tool_basename" = "x$tool_specified"; then 31111 # A command without a complete path is provided, search $PATH. 31112 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5 31113 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;} 31114 # Extract the first word of "$tool_basename", so it can be a program name with args. 31115 set dummy $tool_basename; ac_word=$2 31116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31117 $as_echo_n "checking for $ac_word... " >&6; } 31118 if ${ac_cv_path_JAVAH+:} false; then : 31119 $as_echo_n "(cached) " >&6 31120 else 31121 case $JAVAH in 31122 [\\/]* | ?:[\\/]*) 31123 ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path. 31124 ;; 31125 *) 31126 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31127 for as_dir in $PATH 31128 do 31129 IFS=$as_save_IFS 31130 test -z "$as_dir" && as_dir=. 31131 for ac_exec_ext in '' $ac_executable_extensions; do 31132 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31133 ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext" 31134 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31135 break 2 31136 fi 31137 done 31138 done 31139 IFS=$as_save_IFS 31140 31141 ;; 31142 esac 31143 fi 31144 JAVAH=$ac_cv_path_JAVAH 31145 if test -n "$JAVAH"; then 31146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5 31147 $as_echo "$JAVAH" >&6; } 31148 else 31149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31150 $as_echo "no" >&6; } 31151 fi 31152 31153 31154 if test "x$JAVAH" = x; then 31155 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31156 fi 31157 else 31158 # Otherwise we believe it is a complete path. Use it as it is. 31159 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5 31160 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;} 31161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 31162 $as_echo_n "checking for JAVAH... " >&6; } 31163 if test ! -x "$tool_specified"; then 31164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31165 $as_echo "not found" >&6; } 31166 as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5 31167 fi 31168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31169 $as_echo "$tool_specified" >&6; } 31170 fi 31171 fi 31172 fi 31173 31174 fi 31175 31176 31177 31178 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 31179 31180 # Publish this variable in the help. 31181 31182 31183 if [ -z "${JAR+x}" ]; then 31184 # The variable is not set by user, try to locate tool using the code snippet 31185 31186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 31187 $as_echo_n "checking for jar in Boot JDK... " >&6; } 31188 JAR=$BOOT_JDK/bin/jar 31189 if test ! -x $JAR; then 31190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31191 $as_echo "not found" >&6; } 31192 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31193 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31194 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 31195 fi 31196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31197 $as_echo "ok" >&6; } 31198 31199 31200 else 31201 # The variable is set, but is it from the command line or the environment? 31202 31203 # Try to remove the string !JAR! from our list. 31204 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/} 31205 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 31206 # If it failed, the variable was not from the command line. Ignore it, 31207 # but warn the user (except for BASH, which is always set by the calling BASH). 31208 if test "xJAR" != xBASH; then 31209 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5 31210 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;} 31211 fi 31212 # Try to locate tool using the code snippet 31213 31214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 31215 $as_echo_n "checking for jar in Boot JDK... " >&6; } 31216 JAR=$BOOT_JDK/bin/jar 31217 if test ! -x $JAR; then 31218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31219 $as_echo "not found" >&6; } 31220 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31221 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31222 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 31223 fi 31224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31225 $as_echo "ok" >&6; } 31226 31227 31228 else 31229 # If it succeeded, then it was overridden by the user. We will use it 31230 # for the tool. 31231 31232 # First remove it from the list of overridden variables, so we can test 31233 # for unknown variables in the end. 31234 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 31235 31236 # Check if we try to supply an empty value 31237 if test "x$JAR" = x; then 31238 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAR= (no value)" >&5 31239 $as_echo "$as_me: Setting user supplied tool JAR= (no value)" >&6;} 31240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 31241 $as_echo_n "checking for JAR... " >&6; } 31242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 31243 $as_echo "disabled" >&6; } 31244 else 31245 # Check if the provided tool contains a complete path. 31246 tool_specified="$JAR" 31247 tool_basename="${tool_specified##*/}" 31248 if test "x$tool_basename" = "x$tool_specified"; then 31249 # A command without a complete path is provided, search $PATH. 31250 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5 31251 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;} 31252 # Extract the first word of "$tool_basename", so it can be a program name with args. 31253 set dummy $tool_basename; ac_word=$2 31254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31255 $as_echo_n "checking for $ac_word... " >&6; } 31256 if ${ac_cv_path_JAR+:} false; then : 31257 $as_echo_n "(cached) " >&6 31258 else 31259 case $JAR in 31260 [\\/]* | ?:[\\/]*) 31261 ac_cv_path_JAR="$JAR" # Let the user override the test with a path. 31262 ;; 31263 *) 31264 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31265 for as_dir in $PATH 31266 do 31267 IFS=$as_save_IFS 31268 test -z "$as_dir" && as_dir=. 31269 for ac_exec_ext in '' $ac_executable_extensions; do 31270 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31271 ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext" 31272 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31273 break 2 31274 fi 31275 done 31276 done 31277 IFS=$as_save_IFS 31278 31279 ;; 31280 esac 31281 fi 31282 JAR=$ac_cv_path_JAR 31283 if test -n "$JAR"; then 31284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5 31285 $as_echo "$JAR" >&6; } 31286 else 31287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31288 $as_echo "no" >&6; } 31289 fi 31290 31291 31292 if test "x$JAR" = x; then 31293 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31294 fi 31295 else 31296 # Otherwise we believe it is a complete path. Use it as it is. 31297 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5 31298 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;} 31299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 31300 $as_echo_n "checking for JAR... " >&6; } 31301 if test ! -x "$tool_specified"; then 31302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31303 $as_echo "not found" >&6; } 31304 as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5 31305 fi 31306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31307 $as_echo "$tool_specified" >&6; } 31308 fi 31309 fi 31310 fi 31311 31312 fi 31313 31314 31315 31316 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 31317 31318 # Publish this variable in the help. 31319 31320 31321 if [ -z "${JARSIGNER+x}" ]; then 31322 # The variable is not set by user, try to locate tool using the code snippet 31323 31324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 31325 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 31326 JARSIGNER=$BOOT_JDK/bin/jarsigner 31327 if test ! -x $JARSIGNER; then 31328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31329 $as_echo "not found" >&6; } 31330 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31331 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31332 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 31333 fi 31334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31335 $as_echo "ok" >&6; } 31336 31337 31338 else 31339 # The variable is set, but is it from the command line or the environment? 31340 31341 # Try to remove the string !JARSIGNER! from our list. 31342 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/} 31343 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 31344 # If it failed, the variable was not from the command line. Ignore it, 31345 # but warn the user (except for BASH, which is always set by the calling BASH). 31346 if test "xJARSIGNER" != xBASH; then 31347 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5 31348 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;} 31349 fi 31350 # Try to locate tool using the code snippet 31351 31352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 31353 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 31354 JARSIGNER=$BOOT_JDK/bin/jarsigner 31355 if test ! -x $JARSIGNER; then 31356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31357 $as_echo "not found" >&6; } 31358 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31359 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31360 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 31361 fi 31362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31363 $as_echo "ok" >&6; } 31364 31365 31366 else 31367 # If it succeeded, then it was overridden by the user. We will use it 31368 # for the tool. 31369 31370 # First remove it from the list of overridden variables, so we can test 31371 # for unknown variables in the end. 31372 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 31373 31374 # Check if we try to supply an empty value 31375 if test "x$JARSIGNER" = x; then 31376 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JARSIGNER= (no value)" >&5 31377 $as_echo "$as_me: Setting user supplied tool JARSIGNER= (no value)" >&6;} 31378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 31379 $as_echo_n "checking for JARSIGNER... " >&6; } 31380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 31381 $as_echo "disabled" >&6; } 31382 else 31383 # Check if the provided tool contains a complete path. 31384 tool_specified="$JARSIGNER" 31385 tool_basename="${tool_specified##*/}" 31386 if test "x$tool_basename" = "x$tool_specified"; then 31387 # A command without a complete path is provided, search $PATH. 31388 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5 31389 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;} 31390 # Extract the first word of "$tool_basename", so it can be a program name with args. 31391 set dummy $tool_basename; ac_word=$2 31392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31393 $as_echo_n "checking for $ac_word... " >&6; } 31394 if ${ac_cv_path_JARSIGNER+:} false; then : 31395 $as_echo_n "(cached) " >&6 31396 else 31397 case $JARSIGNER in 31398 [\\/]* | ?:[\\/]*) 31399 ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path. 31400 ;; 31401 *) 31402 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31403 for as_dir in $PATH 31404 do 31405 IFS=$as_save_IFS 31406 test -z "$as_dir" && as_dir=. 31407 for ac_exec_ext in '' $ac_executable_extensions; do 31408 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31409 ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext" 31410 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31411 break 2 31412 fi 31413 done 31414 done 31415 IFS=$as_save_IFS 31416 31417 ;; 31418 esac 31419 fi 31420 JARSIGNER=$ac_cv_path_JARSIGNER 31421 if test -n "$JARSIGNER"; then 31422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5 31423 $as_echo "$JARSIGNER" >&6; } 31424 else 31425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31426 $as_echo "no" >&6; } 31427 fi 31428 31429 31430 if test "x$JARSIGNER" = x; then 31431 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31432 fi 31433 else 31434 # Otherwise we believe it is a complete path. Use it as it is. 31435 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5 31436 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;} 31437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 31438 $as_echo_n "checking for JARSIGNER... " >&6; } 31439 if test ! -x "$tool_specified"; then 31440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31441 $as_echo "not found" >&6; } 31442 as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5 31443 fi 31444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31445 $as_echo "$tool_specified" >&6; } 31446 fi 31447 fi 31448 fi 31449 31450 fi 31451 31452 31453 31454 # Finally, set some other options... 31455 31456 # When compiling code to be executed by the Boot JDK, force jdk8 compatibility. 31457 BOOT_JDK_SOURCETARGET="-source 8 -target 8" 31458 31459 31460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK supports modules" >&5 31461 $as_echo_n "checking if Boot JDK supports modules... " >&6; } 31462 if "$JAVA" --list-modules > /dev/null 2>&1; then 31463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31464 $as_echo "yes" >&6; } 31465 BOOT_JDK_MODULAR="true" 31466 else 31467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31468 $as_echo "no" >&6; } 31469 BOOT_JDK_MODULAR="false" 31470 fi 31471 31472 31473 31474 31475 # Check if the boot jdk is 32 or 64 bit 31476 if "$JAVA" -version 2>&1 | $GREP -q "64-Bit"; then 31477 BOOT_JDK_BITS="64" 31478 else 31479 BOOT_JDK_BITS="32" 31480 fi 31481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK is 32 or 64 bits" >&5 31482 $as_echo_n "checking if Boot JDK is 32 or 64 bits... " >&6; } 31483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_BITS" >&5 31484 $as_echo "$BOOT_JDK_BITS" >&6; } 31485 31486 # Try to enable CDS 31487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for local Boot JDK Class Data Sharing (CDS)" >&5 31488 $as_echo_n "checking for local Boot JDK Class Data Sharing (CDS)... " >&6; } 31489 BOOT_JDK_CDS_ARCHIVE=$CONFIGURESUPPORT_OUTPUTDIR/classes.jsa 31490 31491 $ECHO "Check if jvm arg is ok: -XX:+UnlockDiagnosticVMOptions -XX:-VerifySharedSpaces -XX:SharedArchiveFile=$BOOT_JDK_CDS_ARCHIVE" >&5 31492 $ECHO "Command: $JAVA -XX:+UnlockDiagnosticVMOptions -XX:-VerifySharedSpaces -XX:SharedArchiveFile=$BOOT_JDK_CDS_ARCHIVE -version" >&5 31493 OUTPUT=`$JAVA -XX:+UnlockDiagnosticVMOptions -XX:-VerifySharedSpaces -XX:SharedArchiveFile=$BOOT_JDK_CDS_ARCHIVE -version 2>&1` 31494 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 31495 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 31496 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 31497 boot_jdk_cds_args="$boot_jdk_cds_args -XX:+UnlockDiagnosticVMOptions -XX:-VerifySharedSpaces -XX:SharedArchiveFile=$BOOT_JDK_CDS_ARCHIVE" 31498 JVM_ARG_OK=true 31499 else 31500 $ECHO "Arg failed:" >&5 31501 $ECHO "$OUTPUT" >&5 31502 JVM_ARG_OK=false 31503 fi 31504 31505 31506 if test "x$boot_jdk_cds_args" != x; then 31507 # Try creating a CDS archive 31508 "$JAVA" $boot_jdk_cds_args -Xshare:dump > /dev/null 2>&1 31509 if test $? -eq 0; then 31510 BOOTJDK_USE_LOCAL_CDS=true 31511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, created" >&5 31512 $as_echo "yes, created" >&6; } 31513 else 31514 # Generation failed, don't use CDS. 31515 BOOTJDK_USE_LOCAL_CDS=false 31516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, creation failed" >&5 31517 $as_echo "no, creation failed" >&6; } 31518 fi 31519 else 31520 BOOTJDK_USE_LOCAL_CDS=false 31521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, -XX:SharedArchiveFile not supported" >&5 31522 $as_echo "no, -XX:SharedArchiveFile not supported" >&6; } 31523 fi 31524 31525 31526 31527 # Check whether --with-build-jdk was given. 31528 if test "${with_build_jdk+set}" = set; then : 31529 withval=$with_build_jdk; 31530 fi 31531 31532 31533 CREATE_BUILDJDK=false 31534 EXTERNAL_BUILDJDK=false 31535 BUILD_JDK_FOUND="no" 31536 if test "x$with_build_jdk" != "x"; then 31537 31538 if test "x$BUILD_JDK_FOUND" = xno; then 31539 # Execute the test 31540 31541 if test "x$with_build_jdk" != x; then 31542 BUILD_JDK=$with_build_jdk 31543 BUILD_JDK_FOUND=maybe 31544 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Build JDK using configure arguments" >&5 31545 $as_echo "$as_me: Found potential Build JDK using configure arguments" >&6;} 31546 fi 31547 31548 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 31549 if test "x$BUILD_JDK_FOUND" = xmaybe; then 31550 # Do we have a bin/java? 31551 if test ! -x "$BUILD_JDK/bin/java"; then 31552 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&5 31553 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&6;} 31554 BUILD_JDK_FOUND=no 31555 elif test ! -x "$BUILD_JDK/bin/jlink"; then 31556 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&5 31557 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&6;} 31558 BUILD_JDK_FOUND=no 31559 elif test ! -x "$BUILD_JDK/bin/jmod"; then 31560 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&5 31561 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&6;} 31562 BUILD_JDK_FOUND=no 31563 elif test ! -x "$BUILD_JDK/bin/javac"; then 31564 # Do we have a bin/javac? 31565 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&5 31566 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&6;} 31567 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be a JRE instead of an JDK)" >&5 31568 $as_echo "$as_me: (This might be a JRE instead of an JDK)" >&6;} 31569 BUILD_JDK_FOUND=no 31570 else 31571 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 31572 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 31573 31574 # Extra M4 quote needed to protect [] in grep expression. 31575 FOUND_CORRECT_VERSION=`echo $BUILD_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"'` 31576 if test "x$FOUND_CORRECT_VERSION" = x; then 31577 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&5 31578 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&6;} 31579 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Build JDK must be version 10)" >&5 31580 $as_echo "$as_me: (Your Build JDK must be version 10)" >&6;} 31581 BUILD_JDK_FOUND=no 31582 else 31583 # We're done! 31584 BUILD_JDK_FOUND=yes 31585 31586 # Only process if variable expands to non-empty 31587 31588 if test "x$BUILD_JDK" != x; then 31589 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31590 31591 # Input might be given as Windows format, start by converting to 31592 # unix format. 31593 path="$BUILD_JDK" 31594 new_path=`$CYGPATH -u "$path"` 31595 31596 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31597 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31598 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31599 # "foo.exe" is OK but "foo" is an error. 31600 # 31601 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31602 # It is also a way to make sure we got the proper file name for the real test later on. 31603 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31604 if test "x$test_shortpath" = x; then 31605 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 31606 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 31607 as_fn_error $? "Cannot locate the the path of BUILD_JDK" "$LINENO" 5 31608 fi 31609 31610 # Call helper function which possibly converts this using DOS-style short mode. 31611 # If so, the updated path is stored in $new_path. 31612 31613 input_path="$new_path" 31614 # Check if we need to convert this using DOS-style short mode. If the path 31615 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31616 # take no chances and rewrite it. 31617 # Note: m4 eats our [], so we need to use [ and ] instead. 31618 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31619 if test "x$has_forbidden_chars" != x; then 31620 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31621 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31622 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31623 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31624 # Going to short mode and back again did indeed matter. Since short mode is 31625 # case insensitive, let's make it lowercase to improve readability. 31626 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31627 # Now convert it back to Unix-style (cygpath) 31628 input_path=`$CYGPATH -u "$shortmode_path"` 31629 new_path="$input_path" 31630 fi 31631 fi 31632 31633 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31634 if test "x$test_cygdrive_prefix" = x; then 31635 # As a simple fix, exclude /usr/bin since it's not a real path. 31636 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31637 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31638 # a path prefixed by /cygdrive for fixpath to work. 31639 new_path="$CYGWIN_ROOT_PATH$input_path" 31640 fi 31641 fi 31642 31643 31644 if test "x$path" != "x$new_path"; then 31645 BUILD_JDK="$new_path" 31646 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 31647 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 31648 fi 31649 31650 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31651 31652 path="$BUILD_JDK" 31653 has_colon=`$ECHO $path | $GREP ^.:` 31654 new_path="$path" 31655 if test "x$has_colon" = x; then 31656 # Not in mixed or Windows style, start by that. 31657 new_path=`cmd //c echo $path` 31658 fi 31659 31660 31661 input_path="$new_path" 31662 # Check if we need to convert this using DOS-style short mode. If the path 31663 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31664 # take no chances and rewrite it. 31665 # Note: m4 eats our [], so we need to use [ and ] instead. 31666 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31667 if test "x$has_forbidden_chars" != x; then 31668 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31669 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31670 fi 31671 31672 31673 windows_path="$new_path" 31674 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31675 unix_path=`$CYGPATH -u "$windows_path"` 31676 new_path="$unix_path" 31677 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31678 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31679 new_path="$unix_path" 31680 fi 31681 31682 if test "x$path" != "x$new_path"; then 31683 BUILD_JDK="$new_path" 31684 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 31685 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 31686 fi 31687 31688 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31689 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31690 31691 else 31692 # We're on a unix platform. Hooray! :) 31693 path="$BUILD_JDK" 31694 has_space=`$ECHO "$path" | $GREP " "` 31695 if test "x$has_space" != x; then 31696 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 31697 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 31698 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31699 fi 31700 31701 # Use eval to expand a potential ~ 31702 eval path="$path" 31703 if test ! -f "$path" && test ! -d "$path"; then 31704 as_fn_error $? "The path of BUILD_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 31705 fi 31706 31707 if test -d "$path"; then 31708 BUILD_JDK="`cd "$path"; $THEPWDCMD -L`" 31709 else 31710 dir="`$DIRNAME "$path"`" 31711 base="`$BASENAME "$path"`" 31712 BUILD_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 31713 fi 31714 fi 31715 fi 31716 31717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31718 $as_echo_n "checking for Build JDK... " >&6; } 31719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK" >&5 31720 $as_echo "$BUILD_JDK" >&6; } 31721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Build JDK version" >&5 31722 $as_echo_n "checking Build JDK version... " >&6; } 31723 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 31724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK_VERSION" >&5 31725 $as_echo "$BUILD_JDK_VERSION" >&6; } 31726 fi # end check jdk version 31727 fi # end check java 31728 fi # end check build jdk found 31729 fi 31730 31731 EXTERNAL_BUILDJDK=true 31732 else 31733 if test "x$COMPILE_TYPE" = "xcross"; then 31734 BUILD_JDK="\$(BUILDJDK_OUTPUTDIR)/jdk" 31735 BUILD_JDK_FOUND=yes 31736 CREATE_BUILDJDK=true 31737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31738 $as_echo_n "checking for Build JDK... " >&6; } 31739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will build it for the host platform" >&5 31740 $as_echo "yes, will build it for the host platform" >&6; } 31741 else 31742 BUILD_JDK="\$(JDK_OUTPUTDIR)" 31743 BUILD_JDK_FOUND=yes 31744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31745 $as_echo_n "checking for Build JDK... " >&6; } 31746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will use output dir" >&5 31747 $as_echo "yes, will use output dir" >&6; } 31748 fi 31749 fi 31750 31751 JMOD="$BUILD_JDK/bin/jmod" 31752 JLINK="$BUILD_JDK/bin/jlink" 31753 31754 31755 31756 if test "x$BUILD_JDK_FOUND" != "xyes"; then 31757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31758 $as_echo_n "checking for Build JDK... " >&6; } 31759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31760 $as_echo "no" >&6; } 31761 as_fn_error $? "Could not find a suitable Build JDK" "$LINENO" 5 31762 fi 31763 31764 31765 31766 31767 31768 31769 ############################################################################### 31770 # 31771 # Configure the sources to use. We can add or override individual directories. 31772 # 31773 ############################################################################### 31774 31775 31776 OUTPUTDIR="$OUTPUTDIR" 31777 31778 JDK_OUTPUTDIR="$OUTPUTDIR/jdk" 31779 31780 # Where are the sources. 31781 31782 31783 31784 31785 # Check whether --with-import-modules was given. 31786 if test "${with_import_modules+set}" = set; then : 31787 withval=$with_import_modules; 31788 fi 31789 31790 31791 if test "x$with_import_modules" != x \ 31792 && test "x$with_import_modules" != "xno"; then 31793 if test -d "$with_import_modules"; then 31794 IMPORT_MODULES_TOPDIR="$with_import_modules" 31795 31796 # Only process if variable expands to non-empty 31797 31798 if test "x$IMPORT_MODULES_TOPDIR" != x; then 31799 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31800 31801 # Input might be given as Windows format, start by converting to 31802 # unix format. 31803 path="$IMPORT_MODULES_TOPDIR" 31804 new_path=`$CYGPATH -u "$path"` 31805 31806 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31807 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31808 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31809 # "foo.exe" is OK but "foo" is an error. 31810 # 31811 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31812 # It is also a way to make sure we got the proper file name for the real test later on. 31813 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31814 if test "x$test_shortpath" = x; then 31815 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31816 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31817 as_fn_error $? "Cannot locate the the path of IMPORT_MODULES_TOPDIR" "$LINENO" 5 31818 fi 31819 31820 # Call helper function which possibly converts this using DOS-style short mode. 31821 # If so, the updated path is stored in $new_path. 31822 31823 input_path="$new_path" 31824 # Check if we need to convert this using DOS-style short mode. If the path 31825 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31826 # take no chances and rewrite it. 31827 # Note: m4 eats our [], so we need to use [ and ] instead. 31828 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31829 if test "x$has_forbidden_chars" != x; then 31830 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31831 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31832 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31833 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31834 # Going to short mode and back again did indeed matter. Since short mode is 31835 # case insensitive, let's make it lowercase to improve readability. 31836 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31837 # Now convert it back to Unix-style (cygpath) 31838 input_path=`$CYGPATH -u "$shortmode_path"` 31839 new_path="$input_path" 31840 fi 31841 fi 31842 31843 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31844 if test "x$test_cygdrive_prefix" = x; then 31845 # As a simple fix, exclude /usr/bin since it's not a real path. 31846 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31847 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31848 # a path prefixed by /cygdrive for fixpath to work. 31849 new_path="$CYGWIN_ROOT_PATH$input_path" 31850 fi 31851 fi 31852 31853 31854 if test "x$path" != "x$new_path"; then 31855 IMPORT_MODULES_TOPDIR="$new_path" 31856 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31857 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31858 fi 31859 31860 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31861 31862 path="$IMPORT_MODULES_TOPDIR" 31863 has_colon=`$ECHO $path | $GREP ^.:` 31864 new_path="$path" 31865 if test "x$has_colon" = x; then 31866 # Not in mixed or Windows style, start by that. 31867 new_path=`cmd //c echo $path` 31868 fi 31869 31870 31871 input_path="$new_path" 31872 # Check if we need to convert this using DOS-style short mode. If the path 31873 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31874 # take no chances and rewrite it. 31875 # Note: m4 eats our [], so we need to use [ and ] instead. 31876 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31877 if test "x$has_forbidden_chars" != x; then 31878 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31879 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31880 fi 31881 31882 31883 windows_path="$new_path" 31884 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31885 unix_path=`$CYGPATH -u "$windows_path"` 31886 new_path="$unix_path" 31887 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31888 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31889 new_path="$unix_path" 31890 fi 31891 31892 if test "x$path" != "x$new_path"; then 31893 IMPORT_MODULES_TOPDIR="$new_path" 31894 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31895 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31896 fi 31897 31898 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31899 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31900 31901 else 31902 # We're on a unix platform. Hooray! :) 31903 path="$IMPORT_MODULES_TOPDIR" 31904 has_space=`$ECHO "$path" | $GREP " "` 31905 if test "x$has_space" != x; then 31906 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31907 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31908 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31909 fi 31910 31911 # Use eval to expand a potential ~ 31912 eval path="$path" 31913 if test ! -f "$path" && test ! -d "$path"; then 31914 as_fn_error $? "The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 31915 fi 31916 31917 if test -d "$path"; then 31918 IMPORT_MODULES_TOPDIR="`cd "$path"; $THEPWDCMD -L`" 31919 else 31920 dir="`$DIRNAME "$path"`" 31921 base="`$BASENAME "$path"`" 31922 IMPORT_MODULES_TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 31923 fi 31924 fi 31925 fi 31926 31927 elif test -e "$with_import_modules"; then 31928 IMPORT_MODULES_TOPDIR="$CONFIGURESUPPORT_OUTPUTDIR/import-modules" 31929 $RM -rf "$IMPORT_MODULES_TOPDIR" 31930 $MKDIR -p "$IMPORT_MODULES_TOPDIR" 31931 if ! $UNZIP -q "$with_import_modules" -d "$IMPORT_MODULES_TOPDIR"; then 31932 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31933 fi 31934 else 31935 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31936 fi 31937 fi 31938 31939 if test -d "$IMPORT_MODULES_TOPDIR/modules"; then 31940 IMPORT_MODULES_CLASSES="$IMPORT_MODULES_TOPDIR/modules" 31941 fi 31942 if test -d "$IMPORT_MODULES_TOPDIR/modules_cmds"; then 31943 IMPORT_MODULES_CMDS="$IMPORT_MODULES_TOPDIR/modules_cmds" 31944 fi 31945 if test -d "$IMPORT_MODULES_TOPDIR/modules_libs"; then 31946 IMPORT_MODULES_LIBS="$IMPORT_MODULES_TOPDIR/modules_libs" 31947 fi 31948 if test -d "$IMPORT_MODULES_TOPDIR/modules_conf"; then 31949 IMPORT_MODULES_CONF="$IMPORT_MODULES_TOPDIR/modules_conf" 31950 fi 31951 if test -d "$IMPORT_MODULES_TOPDIR/modules_legal"; then 31952 IMPORT_MODULES_LEGAL="$IMPORT_MODULES_TOPDIR/modules_legal" 31953 fi 31954 if test -d "$IMPORT_MODULES_TOPDIR/modules_man"; then 31955 IMPORT_MODULES_MAN="$IMPORT_MODULES_TOPDIR/modules_man" 31956 fi 31957 if test -d "$IMPORT_MODULES_TOPDIR/modules_src"; then 31958 IMPORT_MODULES_SRC="$IMPORT_MODULES_TOPDIR/modules_src" 31959 fi 31960 if test -d "$IMPORT_MODULES_TOPDIR/make"; then 31961 IMPORT_MODULES_MAKE="$IMPORT_MODULES_TOPDIR/make" 31962 fi 31963 31964 31965 31966 31967 31968 31969 31970 31971 31972 31973 31974 ############################################################################### 31975 # 31976 # Setup the toolchain (compilers etc), i.e. tools used to compile and process 31977 # native code. 31978 # 31979 ############################################################################### 31980 31981 # See if we are doing a complete static build or not 31982 31983 # Check whether --enable-static-build was given. 31984 if test "${enable_static_build+set}" = set; then : 31985 enableval=$enable_static_build; 31986 fi 31987 31988 STATIC_BUILD=false 31989 if test "x$enable_static_build" = "xyes"; then 31990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31991 $as_echo_n "checking if static build is enabled... " >&6; } 31992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31993 $as_echo "yes" >&6; } 31994 if test "x$OPENJDK_TARGET_OS" != "xmacosx"; then 31995 as_fn_error $? "--enable-static-build is only supported for macosx builds" "$LINENO" 5 31996 fi 31997 STATIC_BUILD_CFLAGS="-DSTATIC_BUILD=1" 31998 CFLAGS_JDKLIB_EXTRA="$CFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31999 CXXFLAGS_JDKLIB_EXTRA="$CXXFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 32000 STATIC_BUILD=true 32001 elif test "x$enable_static_build" = "xno"; then 32002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 32003 $as_echo_n "checking if static build is enabled... " >&6; } 32004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32005 $as_echo "no" >&6; } 32006 elif test "x$enable_static_build" != "x"; then 32007 as_fn_error $? "--enable-static-build can only be assigned \"yes\" or \"no\"" "$LINENO" 5 32008 fi 32009 32010 32011 32012 32013 # First determine the toolchain type (compiler family) 32014 32015 32016 # Check whether --with-toolchain-type was given. 32017 if test "${with_toolchain_type+set}" = set; then : 32018 withval=$with_toolchain_type; 32019 fi 32020 32021 32022 # Use indirect variable referencing 32023 toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS 32024 VALID_TOOLCHAINS=${!toolchain_var_name} 32025 32026 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 32027 if test -n "$XCODEBUILD"; then 32028 # On Mac OS X, default toolchain to clang after Xcode 5 32029 XCODE_VERSION_OUTPUT=`"$XCODEBUILD" -version 2>&1 | $HEAD -n 1` 32030 $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null 32031 if test $? -ne 0; then 32032 as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5 32033 fi 32034 XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \ 32035 $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \ 32036 $CUT -f 1 -d .` 32037 { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5 32038 $as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;} 32039 if test $XCODE_MAJOR_VERSION -ge 5; then 32040 DEFAULT_TOOLCHAIN="clang" 32041 else 32042 DEFAULT_TOOLCHAIN="gcc" 32043 fi 32044 else 32045 # If Xcode is not installed, but the command line tools are 32046 # then we can't run xcodebuild. On these systems we should 32047 # default to clang 32048 DEFAULT_TOOLCHAIN="clang" 32049 fi 32050 else 32051 # First toolchain type in the list is the default 32052 DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *} 32053 fi 32054 32055 if test "x$with_toolchain_type" = xlist; then 32056 # List all toolchains 32057 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5 32058 $as_echo "$as_me: The following toolchains are valid on this platform:" >&6;} 32059 for toolchain in $VALID_TOOLCHAINS; do 32060 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 32061 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 32062 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 32063 done 32064 32065 exit 0 32066 elif test "x$with_toolchain_type" != x; then 32067 # User override; check that it is valid 32068 if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then 32069 { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5 32070 $as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;} 32071 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5 32072 $as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;} 32073 as_fn_error $? "Cannot continue." "$LINENO" 5 32074 fi 32075 TOOLCHAIN_TYPE=$with_toolchain_type 32076 else 32077 # No flag given, use default 32078 TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN 32079 fi 32080 32081 32082 TOOLCHAIN_CC_BINARY_clang="clang" 32083 TOOLCHAIN_CC_BINARY_gcc="gcc" 32084 TOOLCHAIN_CC_BINARY_microsoft="cl" 32085 TOOLCHAIN_CC_BINARY_solstudio="cc" 32086 TOOLCHAIN_CC_BINARY_xlc="xlc_r" 32087 32088 TOOLCHAIN_CXX_BINARY_clang="clang++" 32089 TOOLCHAIN_CXX_BINARY_gcc="g++" 32090 TOOLCHAIN_CXX_BINARY_microsoft="cl" 32091 TOOLCHAIN_CXX_BINARY_solstudio="CC" 32092 TOOLCHAIN_CXX_BINARY_xlc="xlC_r" 32093 32094 # Use indirect variable referencing 32095 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE 32096 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 32097 toolchain_var_name=TOOLCHAIN_MINIMUM_VERSION_$TOOLCHAIN_TYPE 32098 TOOLCHAIN_MINIMUM_VERSION=${!toolchain_var_name} 32099 toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE 32100 TOOLCHAIN_CC_BINARY=${!toolchain_var_name} 32101 toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE 32102 TOOLCHAIN_CXX_BINARY=${!toolchain_var_name} 32103 32104 32105 # Define filename patterns 32106 if test "x$OPENJDK_TARGET_OS" = xwindows; then 32107 LIBRARY_PREFIX= 32108 SHARED_LIBRARY_SUFFIX='.dll' 32109 STATIC_LIBRARY_SUFFIX='.lib' 32110 SHARED_LIBRARY='$1.dll' 32111 STATIC_LIBRARY='$1.lib' 32112 OBJ_SUFFIX='.obj' 32113 EXE_SUFFIX='.exe' 32114 else 32115 LIBRARY_PREFIX=lib 32116 SHARED_LIBRARY_SUFFIX='.so' 32117 STATIC_LIBRARY_SUFFIX='.a' 32118 SHARED_LIBRARY='lib$1.so' 32119 STATIC_LIBRARY='lib$1.a' 32120 OBJ_SUFFIX='.o' 32121 EXE_SUFFIX='' 32122 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 32123 # For full static builds, we're overloading the SHARED_LIBRARY 32124 # variables in order to limit the amount of changes required. 32125 # It would be better to remove SHARED and just use LIBRARY and 32126 # LIBRARY_SUFFIX for libraries that can be built either 32127 # shared or static and use STATIC_* for libraries that are 32128 # always built statically. 32129 if test "x$STATIC_BUILD" = xtrue; then 32130 SHARED_LIBRARY='lib$1.a' 32131 SHARED_LIBRARY_SUFFIX='.a' 32132 else 32133 SHARED_LIBRARY='lib$1.dylib' 32134 SHARED_LIBRARY_SUFFIX='.dylib' 32135 fi 32136 fi 32137 fi 32138 32139 32140 32141 32142 32143 32144 32145 32146 32147 32148 if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then 32149 { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5 32150 $as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;} 32151 else 32152 { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5 32153 $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;} 32154 fi 32155 32156 32157 # User supplied flags should be used when configure detects compilers 32158 32159 if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then 32160 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5 32161 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;} 32162 fi 32163 32164 if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then 32165 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5 32166 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;} 32167 fi 32168 32169 if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then 32170 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5 32171 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;} 32172 fi 32173 32174 32175 # Check whether --with-extra-cflags was given. 32176 if test "${with_extra_cflags+set}" = set; then : 32177 withval=$with_extra_cflags; 32178 fi 32179 32180 32181 32182 # Check whether --with-extra-cxxflags was given. 32183 if test "${with_extra_cxxflags+set}" = set; then : 32184 withval=$with_extra_cxxflags; 32185 fi 32186 32187 32188 32189 # Check whether --with-extra-ldflags was given. 32190 if test "${with_extra_ldflags+set}" = set; then : 32191 withval=$with_extra_ldflags; 32192 fi 32193 32194 32195 EXTRA_CFLAGS="$with_extra_cflags" 32196 EXTRA_CXXFLAGS="$with_extra_cxxflags" 32197 EXTRA_LDFLAGS="$with_extra_ldflags" 32198 32199 32200 32201 32202 32203 # The global CFLAGS and LDLAGS variables are used by configure tests and 32204 # should include the extra parameters 32205 CFLAGS="$EXTRA_CFLAGS" 32206 CXXFLAGS="$EXTRA_CXXFLAGS" 32207 LDFLAGS="$EXTRA_LDFLAGS" 32208 CPPFLAGS="" 32209 32210 # The sysroot cflags are needed for configure to be able to run the compilers 32211 32212 if test "x$SYSROOT" != "x"; then 32213 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 32214 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 32215 # Solaris Studio does not have a concept of sysroot. Instead we must 32216 # make sure the default include and lib dirs are appended to each 32217 # compile and link command line. Must also add -I-xbuiltin to enable 32218 # inlining of system functions and intrinsics. 32219 SYSROOT_CFLAGS="-I-xbuiltin -I$SYSROOT/usr/include" 32220 SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 32221 -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 32222 fi 32223 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 32224 SYSROOT_CFLAGS="--sysroot=$SYSROOT" 32225 SYSROOT_LDFLAGS="--sysroot=$SYSROOT" 32226 elif test "x$TOOLCHAIN_TYPE" = xclang; then 32227 SYSROOT_CFLAGS="-isysroot $SYSROOT" 32228 SYSROOT_LDFLAGS="-isysroot $SYSROOT" 32229 fi 32230 # The global CFLAGS and LDFLAGS variables need these for configure to function 32231 CFLAGS="$CFLAGS $SYSROOT_CFLAGS" 32232 CPPFLAGS="$CPPFLAGS $SYSROOT_CFLAGS" 32233 CXXFLAGS="$CXXFLAGS $SYSROOT_CFLAGS" 32234 LDFLAGS="$LDFLAGS $SYSROOT_LDFLAGS" 32235 fi 32236 32237 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 32238 # We also need -iframework<path>/System/Library/Frameworks 32239 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -iframework $SYSROOT/System/Library/Frameworks" 32240 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -iframework $SYSROOT/System/Library/Frameworks" 32241 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 32242 # set this here so it doesn't have to be peppered throughout the forest 32243 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 32244 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 32245 fi 32246 32247 32248 32249 32250 32251 # Then detect the actual binaries needed 32252 32253 # FIXME: Is this needed? 32254 ac_ext=cpp 32255 ac_cpp='$CXXCPP $CPPFLAGS' 32256 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32257 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32258 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32259 32260 32261 # Store the CFLAGS etc passed to the configure script. 32262 ORG_CFLAGS="$CFLAGS" 32263 ORG_CXXFLAGS="$CXXFLAGS" 32264 32265 # autoconf magic only relies on PATH, so update it if tools dir is specified 32266 OLD_PATH="$PATH" 32267 32268 # On Windows, we need to detect the visual studio installation first. 32269 # This will change the PATH, but we need to keep that new PATH even 32270 # after toolchain detection is done, since the compiler (on x86) uses 32271 # it for DLL resolution in runtime. 32272 if test "x$OPENJDK_BUILD_OS" = "xwindows" \ 32273 && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then 32274 32275 # Store path to cygwin link.exe to help excluding it when searching for 32276 # VS linker. This must be done before changing the PATH when looking for VS. 32277 # Extract the first word of "link", so it can be a program name with args. 32278 set dummy link; ac_word=$2 32279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 32280 $as_echo_n "checking for $ac_word... " >&6; } 32281 if ${ac_cv_path_CYGWIN_LINK+:} false; then : 32282 $as_echo_n "(cached) " >&6 32283 else 32284 case $CYGWIN_LINK in 32285 [\\/]* | ?:[\\/]*) 32286 ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path. 32287 ;; 32288 *) 32289 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 32290 for as_dir in $PATH 32291 do 32292 IFS=$as_save_IFS 32293 test -z "$as_dir" && as_dir=. 32294 for ac_exec_ext in '' $ac_executable_extensions; do 32295 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 32296 ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext" 32297 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 32298 break 2 32299 fi 32300 done 32301 done 32302 IFS=$as_save_IFS 32303 32304 ;; 32305 esac 32306 fi 32307 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK 32308 if test -n "$CYGWIN_LINK"; then 32309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5 32310 $as_echo "$CYGWIN_LINK" >&6; } 32311 else 32312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32313 $as_echo "no" >&6; } 32314 fi 32315 32316 32317 if test "x$CYGWIN_LINK" != x; then 32318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5 32319 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; } 32320 "$CYGWIN_LINK" --version > /dev/null 32321 if test $? -eq 0 ; then 32322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32323 $as_echo "yes" >&6; } 32324 else 32325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32326 $as_echo "no" >&6; } 32327 # This might be the VS linker. Don't exclude it later on. 32328 CYGWIN_LINK="" 32329 fi 32330 fi 32331 32332 # First-hand choice is to locate and run the vsvars bat file. 32333 32334 32335 # Check whether --with-toolchain-version was given. 32336 if test "${with_toolchain_version+set}" = set; then : 32337 withval=$with_toolchain_version; 32338 fi 32339 32340 32341 if test "x$with_toolchain_version" = xlist; then 32342 # List all toolchains 32343 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchain versions are valid on this platform:" >&5 32344 $as_echo "$as_me: The following toolchain versions are valid on this platform:" >&6;} 32345 for version in $VALID_VS_VERSIONS; do 32346 eval VS_DESCRIPTION=\${VS_DESCRIPTION_$version} 32347 $PRINTF " %-10s %s\n" $version "$VS_DESCRIPTION" 32348 done 32349 32350 exit 0 32351 elif test "x$DEVKIT_VS_VERSION" != x; then 32352 VS_VERSION=$DEVKIT_VS_VERSION 32353 TOOLCHAIN_VERSION=$VS_VERSION 32354 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 32355 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 32356 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 32357 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 32358 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32359 VS_PATH="$TOOLCHAIN_PATH:$PATH" 32360 32361 # Convert DEVKIT_VS_INCLUDE into windows style VS_INCLUDE so that it 32362 # can still be exported as INCLUDE for compiler invocations without 32363 # SYSROOT_CFLAGS 32364 OLDIFS="$IFS" 32365 IFS=";" 32366 for i in $DEVKIT_VS_INCLUDE; do 32367 ipath=$i 32368 32369 unix_path="$ipath" 32370 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32371 windows_path=`$CYGPATH -m "$unix_path"` 32372 ipath="$windows_path" 32373 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32374 windows_path=`cmd //c echo $unix_path` 32375 ipath="$windows_path" 32376 fi 32377 32378 VS_INCLUDE="$VS_INCLUDE;$ipath" 32379 done 32380 # Convert DEVKIT_VS_LIB into VS_LIB so that it can still be exported 32381 # as LIB for compiler invocations without SYSROOT_LDFLAGS 32382 for i in $DEVKIT_VS_LIB; do 32383 libpath=$i 32384 32385 unix_path="$libpath" 32386 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32387 windows_path=`$CYGPATH -m "$unix_path"` 32388 libpath="$windows_path" 32389 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32390 windows_path=`cmd //c echo $unix_path` 32391 libpath="$windows_path" 32392 fi 32393 32394 VS_LIB="$VS_LIB;$libpath" 32395 done 32396 IFS="$OLDIFS" 32397 32398 { $as_echo "$as_me:${as_lineno-$LINENO}: Found devkit $VS_DESCRIPTION" >&5 32399 $as_echo "$as_me: Found devkit $VS_DESCRIPTION" >&6;} 32400 32401 elif test "x$with_toolchain_version" != x; then 32402 # User override; check that it is valid 32403 if test "x${VALID_VS_VERSIONS/$with_toolchain_version/}" = "x${VALID_VS_VERSIONS}"; then 32404 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio version $with_toolchain_version is not valid." >&5 32405 $as_echo "$as_me: Visual Studio version $with_toolchain_version is not valid." >&6;} 32406 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&5 32407 $as_echo "$as_me: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&6;} 32408 as_fn_error $? "Cannot continue." "$LINENO" 5 32409 fi 32410 VS_VERSIONS_PROBE_LIST="$with_toolchain_version" 32411 else 32412 # No flag given, use default 32413 VS_VERSIONS_PROBE_LIST="$VALID_VS_VERSIONS" 32414 fi 32415 32416 for VS_VERSION in $VS_VERSIONS_PROBE_LIST; do 32417 32418 VS_VERSION="$VS_VERSION" 32419 eval VS_COMNTOOLS_VAR="\${VS_ENVVAR_${VS_VERSION}}" 32420 eval VS_COMNTOOLS="\$${VS_COMNTOOLS_VAR}" 32421 eval VS_INSTALL_DIR="\${VS_VS_INSTALLDIR_${VS_VERSION}}" 32422 eval SDK_INSTALL_DIR="\${VS_SDK_INSTALLDIR_${VS_VERSION}}" 32423 32424 # When using --with-tools-dir, assume it points to the correct and default 32425 # version of Visual Studio or that --with-toolchain-version was also set. 32426 if test "x$with_tools_dir" != x; then 32427 32428 if test "x$VS_ENV_CMD" = x; then 32429 VS_VERSION="${VS_VERSION}" 32430 VS_BASE="$with_tools_dir/../.." 32431 METHOD="--with-tools-dir" 32432 32433 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32434 VCVARSFILE="vc/bin/vcvars32.bat" 32435 else 32436 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32437 fi 32438 32439 32440 windows_path="$VS_BASE" 32441 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32442 unix_path=`$CYGPATH -u "$windows_path"` 32443 VS_BASE="$unix_path" 32444 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32445 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32446 VS_BASE="$unix_path" 32447 fi 32448 32449 if test -d "$VS_BASE"; then 32450 if test -f "$VS_BASE/$VCVARSFILE"; then 32451 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32452 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32453 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32454 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32455 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32456 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32457 else 32458 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32459 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32460 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32461 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32462 fi 32463 fi 32464 fi 32465 32466 32467 if test "x$VS_ENV_CMD" = x; then 32468 VS_VERSION="${VS_VERSION}" 32469 VS_BASE="$with_tools_dir/../../.." 32470 METHOD="--with-tools-dir" 32471 32472 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32473 VCVARSFILE="vc/bin/vcvars32.bat" 32474 else 32475 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32476 fi 32477 32478 32479 windows_path="$VS_BASE" 32480 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32481 unix_path=`$CYGPATH -u "$windows_path"` 32482 VS_BASE="$unix_path" 32483 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32484 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32485 VS_BASE="$unix_path" 32486 fi 32487 32488 if test -d "$VS_BASE"; then 32489 if test -f "$VS_BASE/$VCVARSFILE"; then 32490 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32491 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32492 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32493 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32494 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32495 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32496 else 32497 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32498 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32499 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32500 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32501 fi 32502 fi 32503 fi 32504 32505 if test "x$VS_ENV_CMD" = x; then 32506 # Having specified an argument which is incorrect will produce an instant failure; 32507 # we should not go on looking 32508 { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid" >&5 32509 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid" >&6;} 32510 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&5 32511 $as_echo "$as_me: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&6;} 32512 { $as_echo "$as_me:${as_lineno-$LINENO}: directory within the Visual Studio installation" >&5 32513 $as_echo "$as_me: directory within the Visual Studio installation" >&6;} 32514 as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5 32515 fi 32516 fi 32517 32518 VS_ENV_CMD="" 32519 VS_ENV_ARGS="" 32520 32521 if test "x$VS_COMNTOOLS" != x; then 32522 32523 if test "x$VS_ENV_CMD" = x; then 32524 VS_VERSION="${VS_VERSION}" 32525 VS_BASE="$VS_COMNTOOLS/../.." 32526 METHOD="$VS_COMNTOOLS_VAR variable" 32527 32528 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32529 VCVARSFILE="vc/bin/vcvars32.bat" 32530 else 32531 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32532 fi 32533 32534 32535 windows_path="$VS_BASE" 32536 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32537 unix_path=`$CYGPATH -u "$windows_path"` 32538 VS_BASE="$unix_path" 32539 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32540 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32541 VS_BASE="$unix_path" 32542 fi 32543 32544 if test -d "$VS_BASE"; then 32545 if test -f "$VS_BASE/$VCVARSFILE"; then 32546 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32547 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32548 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32549 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32550 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32551 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32552 else 32553 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32554 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32555 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32556 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32557 fi 32558 fi 32559 fi 32560 32561 fi 32562 if test "x$PROGRAMFILES" != x; then 32563 32564 if test "x$VS_ENV_CMD" = x; then 32565 VS_VERSION="${VS_VERSION}" 32566 VS_BASE="$PROGRAMFILES/$VS_INSTALL_DIR" 32567 METHOD="well-known name" 32568 32569 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32570 VCVARSFILE="vc/bin/vcvars32.bat" 32571 else 32572 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32573 fi 32574 32575 32576 windows_path="$VS_BASE" 32577 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32578 unix_path=`$CYGPATH -u "$windows_path"` 32579 VS_BASE="$unix_path" 32580 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32581 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32582 VS_BASE="$unix_path" 32583 fi 32584 32585 if test -d "$VS_BASE"; then 32586 if test -f "$VS_BASE/$VCVARSFILE"; then 32587 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32588 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32589 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32590 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32591 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32592 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32593 else 32594 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32595 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32596 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32597 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32598 fi 32599 fi 32600 fi 32601 32602 fi 32603 # Work around the insanely named ProgramFiles(x86) env variable 32604 PROGRAMFILES_X86="`env | $SED -n 's/^ProgramFiles(x86)=//p'`" 32605 if test "x$PROGRAMFILES_X86" != x; then 32606 32607 if test "x$VS_ENV_CMD" = x; then 32608 VS_VERSION="${VS_VERSION}" 32609 VS_BASE="$PROGRAMFILES_X86/$VS_INSTALL_DIR" 32610 METHOD="well-known name" 32611 32612 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32613 VCVARSFILE="vc/bin/vcvars32.bat" 32614 else 32615 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32616 fi 32617 32618 32619 windows_path="$VS_BASE" 32620 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32621 unix_path=`$CYGPATH -u "$windows_path"` 32622 VS_BASE="$unix_path" 32623 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32624 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32625 VS_BASE="$unix_path" 32626 fi 32627 32628 if test -d "$VS_BASE"; then 32629 if test -f "$VS_BASE/$VCVARSFILE"; then 32630 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32631 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32632 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32633 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32634 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32635 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32636 else 32637 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32638 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32639 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32640 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32641 fi 32642 fi 32643 fi 32644 32645 fi 32646 32647 if test "x$VS_ENV_CMD" = x; then 32648 VS_VERSION="${VS_VERSION}" 32649 VS_BASE="C:/Program Files/$VS_INSTALL_DIR" 32650 METHOD="well-known name" 32651 32652 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32653 VCVARSFILE="vc/bin/vcvars32.bat" 32654 else 32655 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32656 fi 32657 32658 32659 windows_path="$VS_BASE" 32660 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32661 unix_path=`$CYGPATH -u "$windows_path"` 32662 VS_BASE="$unix_path" 32663 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32664 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32665 VS_BASE="$unix_path" 32666 fi 32667 32668 if test -d "$VS_BASE"; then 32669 if test -f "$VS_BASE/$VCVARSFILE"; then 32670 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32671 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32672 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32673 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32674 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32675 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32676 else 32677 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32678 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32679 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32680 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32681 fi 32682 fi 32683 fi 32684 32685 32686 if test "x$VS_ENV_CMD" = x; then 32687 VS_VERSION="${VS_VERSION}" 32688 VS_BASE="C:/Program Files (x86)/$VS_INSTALL_DIR" 32689 METHOD="well-known name" 32690 32691 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32692 VCVARSFILE="vc/bin/vcvars32.bat" 32693 else 32694 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32695 fi 32696 32697 32698 windows_path="$VS_BASE" 32699 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32700 unix_path=`$CYGPATH -u "$windows_path"` 32701 VS_BASE="$unix_path" 32702 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32703 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32704 VS_BASE="$unix_path" 32705 fi 32706 32707 if test -d "$VS_BASE"; then 32708 if test -f "$VS_BASE/$VCVARSFILE"; then 32709 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32710 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32711 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32712 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32713 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32714 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32715 else 32716 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32717 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32718 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32719 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32720 fi 32721 fi 32722 fi 32723 32724 32725 if test "x$SDK_INSTALL_DIR" != x; then 32726 if test "x$ProgramW6432" != x; then 32727 32728 if test "x$VS_ENV_CMD" = x; then 32729 VS_VERSION="${VS_VERSION}" 32730 WIN_SDK_BASE="$ProgramW6432/$SDK_INSTALL_DIR" 32731 METHOD="well-known name" 32732 32733 windows_path="$WIN_SDK_BASE" 32734 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32735 unix_path=`$CYGPATH -u "$windows_path"` 32736 WIN_SDK_BASE="$unix_path" 32737 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32738 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32739 WIN_SDK_BASE="$unix_path" 32740 fi 32741 32742 if test -d "$WIN_SDK_BASE"; then 32743 # There have been cases of partial or broken SDK installations. A missing 32744 # lib dir is not going to work. 32745 if test ! -d "$WIN_SDK_BASE/lib"; then 32746 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32747 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32748 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32749 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32750 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32751 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32752 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32753 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32754 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32755 VS_ENV_ARGS="/x86" 32756 else 32757 VS_ENV_ARGS="/x64" 32758 fi 32759 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32760 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32761 # TODO: improve detection for other versions of SDK 32762 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32763 else 32764 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32765 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32766 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32767 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32768 fi 32769 fi 32770 fi 32771 32772 fi 32773 if test "x$PROGRAMW6432" != x; then 32774 32775 if test "x$VS_ENV_CMD" = x; then 32776 VS_VERSION="${VS_VERSION}" 32777 WIN_SDK_BASE="$PROGRAMW6432/$SDK_INSTALL_DIR" 32778 METHOD="well-known name" 32779 32780 windows_path="$WIN_SDK_BASE" 32781 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32782 unix_path=`$CYGPATH -u "$windows_path"` 32783 WIN_SDK_BASE="$unix_path" 32784 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32785 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32786 WIN_SDK_BASE="$unix_path" 32787 fi 32788 32789 if test -d "$WIN_SDK_BASE"; then 32790 # There have been cases of partial or broken SDK installations. A missing 32791 # lib dir is not going to work. 32792 if test ! -d "$WIN_SDK_BASE/lib"; then 32793 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32794 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32795 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32796 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32797 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32798 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32799 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32800 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32801 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32802 VS_ENV_ARGS="/x86" 32803 else 32804 VS_ENV_ARGS="/x64" 32805 fi 32806 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32807 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32808 # TODO: improve detection for other versions of SDK 32809 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32810 else 32811 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32812 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32813 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32814 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32815 fi 32816 fi 32817 fi 32818 32819 fi 32820 if test "x$PROGRAMFILES" != x; then 32821 32822 if test "x$VS_ENV_CMD" = x; then 32823 VS_VERSION="${VS_VERSION}" 32824 WIN_SDK_BASE="$PROGRAMFILES/$SDK_INSTALL_DIR" 32825 METHOD="well-known name" 32826 32827 windows_path="$WIN_SDK_BASE" 32828 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32829 unix_path=`$CYGPATH -u "$windows_path"` 32830 WIN_SDK_BASE="$unix_path" 32831 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32832 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32833 WIN_SDK_BASE="$unix_path" 32834 fi 32835 32836 if test -d "$WIN_SDK_BASE"; then 32837 # There have been cases of partial or broken SDK installations. A missing 32838 # lib dir is not going to work. 32839 if test ! -d "$WIN_SDK_BASE/lib"; then 32840 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32841 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32842 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32843 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32844 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32845 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32846 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32847 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32848 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32849 VS_ENV_ARGS="/x86" 32850 else 32851 VS_ENV_ARGS="/x64" 32852 fi 32853 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32854 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32855 # TODO: improve detection for other versions of SDK 32856 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32857 else 32858 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32859 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32860 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32861 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32862 fi 32863 fi 32864 fi 32865 32866 fi 32867 32868 if test "x$VS_ENV_CMD" = x; then 32869 VS_VERSION="${VS_VERSION}" 32870 WIN_SDK_BASE="C:/Program Files/$SDK_INSTALL_DIR" 32871 METHOD="well-known name" 32872 32873 windows_path="$WIN_SDK_BASE" 32874 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32875 unix_path=`$CYGPATH -u "$windows_path"` 32876 WIN_SDK_BASE="$unix_path" 32877 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32878 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32879 WIN_SDK_BASE="$unix_path" 32880 fi 32881 32882 if test -d "$WIN_SDK_BASE"; then 32883 # There have been cases of partial or broken SDK installations. A missing 32884 # lib dir is not going to work. 32885 if test ! -d "$WIN_SDK_BASE/lib"; then 32886 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32887 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32888 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32889 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32890 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32891 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32892 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32893 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32894 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32895 VS_ENV_ARGS="/x86" 32896 else 32897 VS_ENV_ARGS="/x64" 32898 fi 32899 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32900 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32901 # TODO: improve detection for other versions of SDK 32902 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32903 else 32904 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32905 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32906 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32907 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32908 fi 32909 fi 32910 fi 32911 32912 32913 if test "x$VS_ENV_CMD" = x; then 32914 VS_VERSION="${VS_VERSION}" 32915 WIN_SDK_BASE="C:/Program Files (x86)/$SDK_INSTALL_DIR" 32916 METHOD="well-known name" 32917 32918 windows_path="$WIN_SDK_BASE" 32919 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32920 unix_path=`$CYGPATH -u "$windows_path"` 32921 WIN_SDK_BASE="$unix_path" 32922 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32923 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32924 WIN_SDK_BASE="$unix_path" 32925 fi 32926 32927 if test -d "$WIN_SDK_BASE"; then 32928 # There have been cases of partial or broken SDK installations. A missing 32929 # lib dir is not going to work. 32930 if test ! -d "$WIN_SDK_BASE/lib"; then 32931 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32932 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32933 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32934 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32935 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32936 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32937 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32938 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32939 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32940 VS_ENV_ARGS="/x86" 32941 else 32942 VS_ENV_ARGS="/x64" 32943 fi 32944 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32945 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32946 # TODO: improve detection for other versions of SDK 32947 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32948 else 32949 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32950 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32951 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32952 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32953 fi 32954 fi 32955 fi 32956 32957 fi 32958 32959 if test "x$VS_ENV_CMD" != x; then 32960 TOOLCHAIN_VERSION=$VS_VERSION 32961 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 32962 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 32963 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 32964 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 32965 # The rest of the variables are already evaled while probing 32966 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $VS_DESCRIPTION" >&5 32967 $as_echo "$as_me: Found $VS_DESCRIPTION" >&6;} 32968 break 32969 fi 32970 done 32971 32972 32973 # If we have a devkit, skip all of the below. 32974 if test "x$DEVKIT_VS_VERSION" = x; then 32975 if test "x$VS_ENV_CMD" != x; then 32976 # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file. 32977 32978 # Only process if variable expands to non-empty 32979 32980 if test "x$VS_ENV_CMD" != x; then 32981 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32982 32983 # First separate the path from the arguments. This will split at the first 32984 # space. 32985 complete="$VS_ENV_CMD" 32986 path="${complete%% *}" 32987 tmp="$complete EOL" 32988 arguments="${tmp#* }" 32989 32990 # Input might be given as Windows format, start by converting to 32991 # unix format. 32992 new_path=`$CYGPATH -u "$path"` 32993 32994 # Now try to locate executable using which 32995 new_path=`$WHICH "$new_path" 2> /dev/null` 32996 # bat and cmd files are not always considered executable in cygwin causing which 32997 # to not find them 32998 if test "x$new_path" = x \ 32999 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33000 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33001 new_path=`$CYGPATH -u "$path"` 33002 fi 33003 if test "x$new_path" = x; then 33004 # Oops. Which didn't find the executable. 33005 # The splitting of arguments from the executable at a space might have been incorrect, 33006 # since paths with space are more likely in Windows. Give it another try with the whole 33007 # argument. 33008 path="$complete" 33009 arguments="EOL" 33010 new_path=`$CYGPATH -u "$path"` 33011 new_path=`$WHICH "$new_path" 2> /dev/null` 33012 # bat and cmd files are not always considered executable in cygwin causing which 33013 # to not find them 33014 if test "x$new_path" = x \ 33015 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33016 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33017 new_path=`$CYGPATH -u "$path"` 33018 fi 33019 if test "x$new_path" = x; then 33020 # It's still not found. Now this is an unrecoverable error. 33021 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 33022 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 33023 has_space=`$ECHO "$complete" | $GREP " "` 33024 if test "x$has_space" != x; then 33025 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33026 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33027 fi 33028 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33029 fi 33030 fi 33031 33032 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33033 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33034 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33035 # "foo.exe" is OK but "foo" is an error. 33036 # 33037 # This test is therefore slightly more accurate than "test -f" to check for file presence. 33038 # It is also a way to make sure we got the proper file name for the real test later on. 33039 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33040 if test "x$test_shortpath" = x; then 33041 # Short path failed, file does not exist as specified. 33042 # Try adding .exe or .cmd 33043 if test -f "${new_path}.exe"; then 33044 input_to_shortpath="${new_path}.exe" 33045 elif test -f "${new_path}.cmd"; then 33046 input_to_shortpath="${new_path}.cmd" 33047 else 33048 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5 33049 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;} 33050 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 33051 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 33052 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33053 fi 33054 else 33055 input_to_shortpath="$new_path" 33056 fi 33057 33058 # Call helper function which possibly converts this using DOS-style short mode. 33059 # If so, the updated path is stored in $new_path. 33060 new_path="$input_to_shortpath" 33061 33062 input_path="$input_to_shortpath" 33063 # Check if we need to convert this using DOS-style short mode. If the path 33064 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33065 # take no chances and rewrite it. 33066 # Note: m4 eats our [], so we need to use [ and ] instead. 33067 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33068 if test "x$has_forbidden_chars" != x; then 33069 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33070 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33071 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33072 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33073 # Going to short mode and back again did indeed matter. Since short mode is 33074 # case insensitive, let's make it lowercase to improve readability. 33075 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33076 # Now convert it back to Unix-style (cygpath) 33077 input_path=`$CYGPATH -u "$shortmode_path"` 33078 new_path="$input_path" 33079 fi 33080 fi 33081 33082 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33083 if test "x$test_cygdrive_prefix" = x; then 33084 # As a simple fix, exclude /usr/bin since it's not a real path. 33085 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 33086 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33087 # a path prefixed by /cygdrive for fixpath to work. 33088 new_path="$CYGWIN_ROOT_PATH$input_path" 33089 fi 33090 fi 33091 33092 # remove trailing .exe if any 33093 new_path="${new_path/%.exe/}" 33094 33095 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33096 33097 # First separate the path from the arguments. This will split at the first 33098 # space. 33099 complete="$VS_ENV_CMD" 33100 path="${complete%% *}" 33101 tmp="$complete EOL" 33102 arguments="${tmp#* }" 33103 33104 # Input might be given as Windows format, start by converting to 33105 # unix format. 33106 new_path="$path" 33107 33108 windows_path="$new_path" 33109 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33110 unix_path=`$CYGPATH -u "$windows_path"` 33111 new_path="$unix_path" 33112 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33113 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33114 new_path="$unix_path" 33115 fi 33116 33117 33118 # Now try to locate executable using which 33119 new_path=`$WHICH "$new_path" 2> /dev/null` 33120 33121 if test "x$new_path" = x; then 33122 # Oops. Which didn't find the executable. 33123 # The splitting of arguments from the executable at a space might have been incorrect, 33124 # since paths with space are more likely in Windows. Give it another try with the whole 33125 # argument. 33126 path="$complete" 33127 arguments="EOL" 33128 new_path="$path" 33129 33130 windows_path="$new_path" 33131 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33132 unix_path=`$CYGPATH -u "$windows_path"` 33133 new_path="$unix_path" 33134 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33135 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33136 new_path="$unix_path" 33137 fi 33138 33139 33140 new_path=`$WHICH "$new_path" 2> /dev/null` 33141 # bat and cmd files are not always considered executable in MSYS causing which 33142 # to not find them 33143 if test "x$new_path" = x \ 33144 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33145 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33146 new_path="$path" 33147 33148 windows_path="$new_path" 33149 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33150 unix_path=`$CYGPATH -u "$windows_path"` 33151 new_path="$unix_path" 33152 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33153 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33154 new_path="$unix_path" 33155 fi 33156 33157 fi 33158 33159 if test "x$new_path" = x; then 33160 # It's still not found. Now this is an unrecoverable error. 33161 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 33162 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 33163 has_space=`$ECHO "$complete" | $GREP " "` 33164 if test "x$has_space" != x; then 33165 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33166 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33167 fi 33168 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33169 fi 33170 fi 33171 33172 # Now new_path has a complete unix path to the binary 33173 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 33174 # Keep paths in /bin as-is, but remove trailing .exe if any 33175 new_path="${new_path/%.exe/}" 33176 # Do not save /bin paths to all_fixpath_prefixes! 33177 else 33178 # Not in mixed or Windows style, start by that. 33179 new_path=`cmd //c echo $new_path` 33180 33181 input_path="$new_path" 33182 # Check if we need to convert this using DOS-style short mode. If the path 33183 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33184 # take no chances and rewrite it. 33185 # Note: m4 eats our [], so we need to use [ and ] instead. 33186 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33187 if test "x$has_forbidden_chars" != x; then 33188 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33189 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33190 fi 33191 33192 # Output is in $new_path 33193 33194 windows_path="$new_path" 33195 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33196 unix_path=`$CYGPATH -u "$windows_path"` 33197 new_path="$unix_path" 33198 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33199 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33200 new_path="$unix_path" 33201 fi 33202 33203 # remove trailing .exe if any 33204 new_path="${new_path/%.exe/}" 33205 33206 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33207 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33208 fi 33209 33210 else 33211 # We're on a unix platform. Hooray! :) 33212 # First separate the path from the arguments. This will split at the first 33213 # space. 33214 complete="$VS_ENV_CMD" 33215 path="${complete%% *}" 33216 tmp="$complete EOL" 33217 arguments="${tmp#* }" 33218 33219 # Cannot rely on the command "which" here since it doesn't always work. 33220 is_absolute_path=`$ECHO "$path" | $GREP ^/` 33221 if test -z "$is_absolute_path"; then 33222 # Path to executable is not absolute. Find it. 33223 IFS_save="$IFS" 33224 IFS=: 33225 for p in $PATH; do 33226 if test -f "$p/$path" && test -x "$p/$path"; then 33227 new_path="$p/$path" 33228 break 33229 fi 33230 done 33231 IFS="$IFS_save" 33232 else 33233 # This is an absolute path, we can use it without further modifications. 33234 new_path="$path" 33235 fi 33236 33237 if test "x$new_path" = x; then 33238 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 33239 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 33240 has_space=`$ECHO "$complete" | $GREP " "` 33241 if test "x$has_space" != x; then 33242 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 33243 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 33244 fi 33245 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33246 fi 33247 fi 33248 33249 # Now join together the path and the arguments once again 33250 if test "x$arguments" != xEOL; then 33251 new_complete="$new_path ${arguments% *}" 33252 else 33253 new_complete="$new_path" 33254 fi 33255 33256 if test "x$complete" != "x$new_complete"; then 33257 VS_ENV_CMD="$new_complete" 33258 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5 33259 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;} 33260 fi 33261 fi 33262 33263 33264 # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat 33265 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5 33266 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;} 33267 33268 # We need to create a couple of temporary files. 33269 VS_ENV_TMP_DIR="$CONFIGURESUPPORT_OUTPUTDIR/vs-env" 33270 $MKDIR -p $VS_ENV_TMP_DIR 33271 33272 # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment). 33273 # Instead create a shell script which will set the relevant variables when run. 33274 WINPATH_VS_ENV_CMD="$VS_ENV_CMD" 33275 33276 unix_path="$WINPATH_VS_ENV_CMD" 33277 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33278 windows_path=`$CYGPATH -m "$unix_path"` 33279 WINPATH_VS_ENV_CMD="$windows_path" 33280 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33281 windows_path=`cmd //c echo $unix_path` 33282 WINPATH_VS_ENV_CMD="$windows_path" 33283 fi 33284 33285 WINPATH_BASH="$BASH" 33286 33287 unix_path="$WINPATH_BASH" 33288 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33289 windows_path=`$CYGPATH -m "$unix_path"` 33290 WINPATH_BASH="$windows_path" 33291 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33292 windows_path=`cmd //c echo $unix_path` 33293 WINPATH_BASH="$windows_path" 33294 fi 33295 33296 33297 # Generate a DOS batch file which runs $VS_ENV_CMD, and then creates a shell 33298 # script (executable by bash) that will setup the important variables. 33299 EXTRACT_VC_ENV_BAT_FILE="$VS_ENV_TMP_DIR/extract-vs-env.bat" 33300 $ECHO "@echo off" > $EXTRACT_VC_ENV_BAT_FILE 33301 # This will end up something like: 33302 # call C:/progra~2/micros~2.0/vc/bin/amd64/vcvars64.bat 33303 $ECHO "call $WINPATH_VS_ENV_CMD $VS_ENV_ARGS" >> $EXTRACT_VC_ENV_BAT_FILE 33304 # These will end up something like: 33305 # C:/CygWin/bin/bash -c 'echo VS_PATH=\"$PATH\" > localdevenv.sh 33306 # The trailing space for everyone except PATH is no typo, but is needed due 33307 # to trailing \ in the Windows paths. These will be stripped later. 33308 $ECHO "$WINPATH_BASH -c 'echo VS_PATH="'\"$PATH\" > set-vs-env.sh' \ 33309 >> $EXTRACT_VC_ENV_BAT_FILE 33310 $ECHO "$WINPATH_BASH -c 'echo VS_INCLUDE="'\"$INCLUDE\;$include \" >> set-vs-env.sh' \ 33311 >> $EXTRACT_VC_ENV_BAT_FILE 33312 $ECHO "$WINPATH_BASH -c 'echo VS_LIB="'\"$LIB\;$lib \" >> set-vs-env.sh' \ 33313 >> $EXTRACT_VC_ENV_BAT_FILE 33314 $ECHO "$WINPATH_BASH -c 'echo VCINSTALLDIR="'\"$VCINSTALLDIR \" >> set-vs-env.sh' \ 33315 >> $EXTRACT_VC_ENV_BAT_FILE 33316 $ECHO "$WINPATH_BASH -c 'echo WindowsSdkDir="'\"$WindowsSdkDir \" >> set-vs-env.sh' \ 33317 >> $EXTRACT_VC_ENV_BAT_FILE 33318 $ECHO "$WINPATH_BASH -c 'echo WINDOWSSDKDIR="'\"$WINDOWSSDKDIR \" >> set-vs-env.sh' \ 33319 >> $EXTRACT_VC_ENV_BAT_FILE 33320 33321 # Now execute the newly created bat file. 33322 # The | cat is to stop SetEnv.Cmd to mess with system colors on msys. 33323 # Change directory so we don't need to mess with Windows paths in redirects. 33324 cd $VS_ENV_TMP_DIR 33325 cmd /c extract-vs-env.bat | $CAT 33326 cd $CURDIR 33327 33328 if test ! -s $VS_ENV_TMP_DIR/set-vs-env.sh; then 33329 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5 33330 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;} 33331 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 33332 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 33333 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 33334 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 33335 as_fn_error $? "Cannot continue" "$LINENO" 5 33336 fi 33337 33338 # Now set all paths and other env variables. This will allow the rest of 33339 # the configure script to find and run the compiler in the proper way. 33340 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5 33341 $as_echo "$as_me: Setting extracted environment variables" >&6;} 33342 . $VS_ENV_TMP_DIR/set-vs-env.sh 33343 # Now we have VS_PATH, VS_INCLUDE, VS_LIB. For further checking, we 33344 # also define VCINSTALLDIR, WindowsSdkDir and WINDOWSSDKDIR. 33345 else 33346 # We did not find a vsvars bat file, let's hope we are run from a VS command prompt. 33347 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5 33348 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;} 33349 fi 33350 fi 33351 33352 # At this point, we should have correct variables in the environment, or we can't continue. 33353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5 33354 $as_echo_n "checking for Visual Studio variables... " >&6; } 33355 33356 if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x \ 33357 || test "x$WINDOWSSDKDIR" != x || test "x$DEVKIT_NAME" != x; then 33358 if test "x$VS_INCLUDE" = x || test "x$VS_LIB" = x; then 33359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5 33360 $as_echo "present but broken" >&6; } 33361 as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5 33362 else 33363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 33364 $as_echo "ok" >&6; } 33365 # Remove any trailing "\" ";" and " " from the variables. 33366 VS_INCLUDE=`$ECHO "$VS_INCLUDE" | $SED -e 's/\\\\*;* *$//'` 33367 VS_LIB=`$ECHO "$VS_LIB" | $SED 's/\\\\*;* *$//'` 33368 VCINSTALLDIR=`$ECHO "$VCINSTALLDIR" | $SED 's/\\\\* *$//'` 33369 WindowsSDKDir=`$ECHO "$WindowsSDKDir" | $SED 's/\\\\* *$//'` 33370 WINDOWSSDKDIR=`$ECHO "$WINDOWSSDKDIR" | $SED 's/\\\\* *$//'` 33371 # Remove any paths containing # (typically F#) as that messes up make. This 33372 # is needed if visual studio was installed with F# support. 33373 VS_PATH=`$ECHO "$VS_PATH" | $SED 's/[^:#]*#[^:]*://g'` 33374 33375 33376 33377 33378 33379 # Convert VS_INCLUDE into SYSROOT_CFLAGS 33380 OLDIFS="$IFS" 33381 IFS=";" 33382 for i in $VS_INCLUDE; do 33383 ipath=$i 33384 # Only process non-empty elements 33385 if test "x$ipath" != x; then 33386 IFS="$OLDIFS" 33387 # Check that directory exists before calling fixup_path 33388 testpath=$ipath 33389 33390 windows_path="$testpath" 33391 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33392 unix_path=`$CYGPATH -u "$windows_path"` 33393 testpath="$unix_path" 33394 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33395 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33396 testpath="$unix_path" 33397 fi 33398 33399 if test -d "$testpath"; then 33400 33401 # Only process if variable expands to non-empty 33402 33403 if test "x$ipath" != x; then 33404 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33405 33406 # Input might be given as Windows format, start by converting to 33407 # unix format. 33408 path="$ipath" 33409 new_path=`$CYGPATH -u "$path"` 33410 33411 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33412 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33413 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33414 # "foo.exe" is OK but "foo" is an error. 33415 # 33416 # This test is therefore slightly more accurate than "test -f" to check for file precense. 33417 # It is also a way to make sure we got the proper file name for the real test later on. 33418 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33419 if test "x$test_shortpath" = x; then 33420 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 33421 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 33422 as_fn_error $? "Cannot locate the the path of ipath" "$LINENO" 5 33423 fi 33424 33425 # Call helper function which possibly converts this using DOS-style short mode. 33426 # If so, the updated path is stored in $new_path. 33427 33428 input_path="$new_path" 33429 # Check if we need to convert this using DOS-style short mode. If the path 33430 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33431 # take no chances and rewrite it. 33432 # Note: m4 eats our [], so we need to use [ and ] instead. 33433 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33434 if test "x$has_forbidden_chars" != x; then 33435 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33436 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33437 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33438 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33439 # Going to short mode and back again did indeed matter. Since short mode is 33440 # case insensitive, let's make it lowercase to improve readability. 33441 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33442 # Now convert it back to Unix-style (cygpath) 33443 input_path=`$CYGPATH -u "$shortmode_path"` 33444 new_path="$input_path" 33445 fi 33446 fi 33447 33448 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33449 if test "x$test_cygdrive_prefix" = x; then 33450 # As a simple fix, exclude /usr/bin since it's not a real path. 33451 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 33452 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33453 # a path prefixed by /cygdrive for fixpath to work. 33454 new_path="$CYGWIN_ROOT_PATH$input_path" 33455 fi 33456 fi 33457 33458 33459 if test "x$path" != "x$new_path"; then 33460 ipath="$new_path" 33461 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 33462 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 33463 fi 33464 33465 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33466 33467 path="$ipath" 33468 has_colon=`$ECHO $path | $GREP ^.:` 33469 new_path="$path" 33470 if test "x$has_colon" = x; then 33471 # Not in mixed or Windows style, start by that. 33472 new_path=`cmd //c echo $path` 33473 fi 33474 33475 33476 input_path="$new_path" 33477 # Check if we need to convert this using DOS-style short mode. If the path 33478 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33479 # take no chances and rewrite it. 33480 # Note: m4 eats our [], so we need to use [ and ] instead. 33481 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33482 if test "x$has_forbidden_chars" != x; then 33483 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33484 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33485 fi 33486 33487 33488 windows_path="$new_path" 33489 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33490 unix_path=`$CYGPATH -u "$windows_path"` 33491 new_path="$unix_path" 33492 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33493 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33494 new_path="$unix_path" 33495 fi 33496 33497 if test "x$path" != "x$new_path"; then 33498 ipath="$new_path" 33499 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 33500 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 33501 fi 33502 33503 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33504 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33505 33506 else 33507 # We're on a unix platform. Hooray! :) 33508 path="$ipath" 33509 has_space=`$ECHO "$path" | $GREP " "` 33510 if test "x$has_space" != x; then 33511 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 33512 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 33513 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 33514 fi 33515 33516 # Use eval to expand a potential ~ 33517 eval path="$path" 33518 if test ! -f "$path" && test ! -d "$path"; then 33519 as_fn_error $? "The path of ipath, which resolves as \"$path\", is not found." "$LINENO" 5 33520 fi 33521 33522 if test -d "$path"; then 33523 ipath="`cd "$path"; $THEPWDCMD -L`" 33524 else 33525 dir="`$DIRNAME "$path"`" 33526 base="`$BASENAME "$path"`" 33527 ipath="`cd "$dir"; $THEPWDCMD -L`/$base" 33528 fi 33529 fi 33530 fi 33531 33532 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -I$ipath" 33533 fi 33534 IFS=";" 33535 fi 33536 done 33537 # Convert VS_LIB into SYSROOT_LDFLAGS 33538 for i in $VS_LIB; do 33539 libpath=$i 33540 # Only process non-empty elements 33541 if test "x$libpath" != x; then 33542 IFS="$OLDIFS" 33543 # Check that directory exists before calling fixup_path 33544 testpath=$libpath 33545 33546 windows_path="$testpath" 33547 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33548 unix_path=`$CYGPATH -u "$windows_path"` 33549 testpath="$unix_path" 33550 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33551 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33552 testpath="$unix_path" 33553 fi 33554 33555 if test -d "$testpath"; then 33556 33557 # Only process if variable expands to non-empty 33558 33559 if test "x$libpath" != x; then 33560 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33561 33562 # Input might be given as Windows format, start by converting to 33563 # unix format. 33564 path="$libpath" 33565 new_path=`$CYGPATH -u "$path"` 33566 33567 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33568 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33569 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33570 # "foo.exe" is OK but "foo" is an error. 33571 # 33572 # This test is therefore slightly more accurate than "test -f" to check for file precense. 33573 # It is also a way to make sure we got the proper file name for the real test later on. 33574 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33575 if test "x$test_shortpath" = x; then 33576 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 33577 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 33578 as_fn_error $? "Cannot locate the the path of libpath" "$LINENO" 5 33579 fi 33580 33581 # Call helper function which possibly converts this using DOS-style short mode. 33582 # If so, the updated path is stored in $new_path. 33583 33584 input_path="$new_path" 33585 # Check if we need to convert this using DOS-style short mode. If the path 33586 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33587 # take no chances and rewrite it. 33588 # Note: m4 eats our [], so we need to use [ and ] instead. 33589 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33590 if test "x$has_forbidden_chars" != x; then 33591 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33592 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33593 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33594 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33595 # Going to short mode and back again did indeed matter. Since short mode is 33596 # case insensitive, let's make it lowercase to improve readability. 33597 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33598 # Now convert it back to Unix-style (cygpath) 33599 input_path=`$CYGPATH -u "$shortmode_path"` 33600 new_path="$input_path" 33601 fi 33602 fi 33603 33604 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33605 if test "x$test_cygdrive_prefix" = x; then 33606 # As a simple fix, exclude /usr/bin since it's not a real path. 33607 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 33608 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33609 # a path prefixed by /cygdrive for fixpath to work. 33610 new_path="$CYGWIN_ROOT_PATH$input_path" 33611 fi 33612 fi 33613 33614 33615 if test "x$path" != "x$new_path"; then 33616 libpath="$new_path" 33617 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 33618 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 33619 fi 33620 33621 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33622 33623 path="$libpath" 33624 has_colon=`$ECHO $path | $GREP ^.:` 33625 new_path="$path" 33626 if test "x$has_colon" = x; then 33627 # Not in mixed or Windows style, start by that. 33628 new_path=`cmd //c echo $path` 33629 fi 33630 33631 33632 input_path="$new_path" 33633 # Check if we need to convert this using DOS-style short mode. If the path 33634 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33635 # take no chances and rewrite it. 33636 # Note: m4 eats our [], so we need to use [ and ] instead. 33637 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33638 if test "x$has_forbidden_chars" != x; then 33639 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33640 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33641 fi 33642 33643 33644 windows_path="$new_path" 33645 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33646 unix_path=`$CYGPATH -u "$windows_path"` 33647 new_path="$unix_path" 33648 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33649 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33650 new_path="$unix_path" 33651 fi 33652 33653 if test "x$path" != "x$new_path"; then 33654 libpath="$new_path" 33655 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 33656 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 33657 fi 33658 33659 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33660 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33661 33662 else 33663 # We're on a unix platform. Hooray! :) 33664 path="$libpath" 33665 has_space=`$ECHO "$path" | $GREP " "` 33666 if test "x$has_space" != x; then 33667 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 33668 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 33669 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 33670 fi 33671 33672 # Use eval to expand a potential ~ 33673 eval path="$path" 33674 if test ! -f "$path" && test ! -d "$path"; then 33675 as_fn_error $? "The path of libpath, which resolves as \"$path\", is not found." "$LINENO" 5 33676 fi 33677 33678 if test -d "$path"; then 33679 libpath="`cd "$path"; $THEPWDCMD -L`" 33680 else 33681 dir="`$DIRNAME "$path"`" 33682 base="`$BASENAME "$path"`" 33683 libpath="`cd "$dir"; $THEPWDCMD -L`/$base" 33684 fi 33685 fi 33686 fi 33687 33688 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -libpath:$libpath" 33689 fi 33690 IFS=";" 33691 fi 33692 done 33693 IFS="$OLDIFS" 33694 fi 33695 else 33696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 33697 $as_echo "not found" >&6; } 33698 33699 if test "x$VS_ENV_CMD" = x; then 33700 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5 33701 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;} 33702 { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5 33703 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;} 33704 else 33705 { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5 33706 $as_echo "$as_me: Running the extraction script failed." >&6;} 33707 fi 33708 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 33709 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 33710 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 33711 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 33712 as_fn_error $? "Cannot continue" "$LINENO" 5 33713 fi 33714 33715 # Reset path to VS_PATH. It will include everything that was on PATH at the time we 33716 # ran TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV. 33717 PATH="$VS_PATH" 33718 # The microsoft toolchain also requires INCLUDE and LIB to be set. 33719 export INCLUDE="$VS_INCLUDE" 33720 export LIB="$VS_LIB" 33721 else 33722 if test "x$XCODE_VERSION_OUTPUT" != x; then 33723 # For Xcode, we set the Xcode version as TOOLCHAIN_VERSION 33724 TOOLCHAIN_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | $CUT -f 2 -d ' '` 33725 TOOLCHAIN_DESCRIPTION="$TOOLCHAIN_DESCRIPTION from Xcode" 33726 else 33727 # Currently we do not define this for other toolchains. This might change as the need arise. 33728 TOOLCHAIN_VERSION= 33729 fi 33730 fi 33731 33732 33733 # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to 33734 # override all other locations. 33735 if test "x$TOOLCHAIN_PATH" != x; then 33736 PATH=$TOOLCHAIN_PATH:$PATH 33737 fi 33738 33739 33740 # 33741 # Setup the compilers (CC and CXX) 33742 # 33743 33744 COMPILER_NAME=C 33745 SEARCH_LIST="$TOOLCHAIN_CC_BINARY" 33746 33747 if test "x$CC" != x; then 33748 # User has supplied compiler name already, always let that override. 33749 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5 33750 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;} 33751 if test "x`basename $CC`" = "x$CC"; then 33752 # A command without a complete path is provided, search $PATH. 33753 33754 for ac_prog in $CC 33755 do 33756 # Extract the first word of "$ac_prog", so it can be a program name with args. 33757 set dummy $ac_prog; ac_word=$2 33758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33759 $as_echo_n "checking for $ac_word... " >&6; } 33760 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33761 $as_echo_n "(cached) " >&6 33762 else 33763 case $POTENTIAL_CC in 33764 [\\/]* | ?:[\\/]*) 33765 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33766 ;; 33767 *) 33768 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33769 for as_dir in $PATH 33770 do 33771 IFS=$as_save_IFS 33772 test -z "$as_dir" && as_dir=. 33773 for ac_exec_ext in '' $ac_executable_extensions; do 33774 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33775 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33776 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33777 break 2 33778 fi 33779 done 33780 done 33781 IFS=$as_save_IFS 33782 33783 ;; 33784 esac 33785 fi 33786 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33787 if test -n "$POTENTIAL_CC"; then 33788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33789 $as_echo "$POTENTIAL_CC" >&6; } 33790 else 33791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33792 $as_echo "no" >&6; } 33793 fi 33794 33795 33796 test -n "$POTENTIAL_CC" && break 33797 done 33798 33799 if test "x$POTENTIAL_CC" != x; then 33800 CC=$POTENTIAL_CC 33801 else 33802 as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5 33803 fi 33804 else 33805 # Otherwise it might already be a complete path 33806 if test ! -x "$CC"; then 33807 as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5 33808 fi 33809 fi 33810 else 33811 # No user supplied value. Locate compiler ourselves. 33812 33813 # If we are cross compiling, assume cross compilation tools follows the 33814 # cross compilation standard where they are prefixed with the autoconf 33815 # standard name for the target. For example the binary 33816 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 33817 # If we are not cross compiling, then the default compiler name will be 33818 # used. 33819 33820 CC= 33821 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 33822 # before checking the rest of the PATH. 33823 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 33824 # step, this should not be necessary. 33825 if test -n "$TOOLCHAIN_PATH"; then 33826 PATH_save="$PATH" 33827 PATH="$TOOLCHAIN_PATH" 33828 if test -n "$ac_tool_prefix"; then 33829 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 33830 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 33831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33832 $as_echo_n "checking for $ac_word... " >&6; } 33833 if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then : 33834 $as_echo_n "(cached) " >&6 33835 else 33836 case $TOOLCHAIN_PATH_CC in 33837 [\\/]* | ?:[\\/]*) 33838 ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33839 ;; 33840 *) 33841 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33842 for as_dir in $PATH 33843 do 33844 IFS=$as_save_IFS 33845 test -z "$as_dir" && as_dir=. 33846 for ac_exec_ext in '' $ac_executable_extensions; do 33847 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33848 ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33849 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33850 break 2 33851 fi 33852 done 33853 done 33854 IFS=$as_save_IFS 33855 33856 ;; 33857 esac 33858 fi 33859 TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC 33860 if test -n "$TOOLCHAIN_PATH_CC"; then 33861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5 33862 $as_echo "$TOOLCHAIN_PATH_CC" >&6; } 33863 else 33864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33865 $as_echo "no" >&6; } 33866 fi 33867 33868 33869 fi 33870 if test -z "$ac_cv_path_TOOLCHAIN_PATH_CC"; then 33871 ac_pt_TOOLCHAIN_PATH_CC=$TOOLCHAIN_PATH_CC 33872 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 33873 set dummy $SEARCH_LIST; ac_word=$2 33874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33875 $as_echo_n "checking for $ac_word... " >&6; } 33876 if ${ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC+:} false; then : 33877 $as_echo_n "(cached) " >&6 33878 else 33879 case $ac_pt_TOOLCHAIN_PATH_CC in 33880 [\\/]* | ?:[\\/]*) 33881 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC="$ac_pt_TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33882 ;; 33883 *) 33884 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33885 for as_dir in $PATH 33886 do 33887 IFS=$as_save_IFS 33888 test -z "$as_dir" && as_dir=. 33889 for ac_exec_ext in '' $ac_executable_extensions; do 33890 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33891 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33892 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33893 break 2 33894 fi 33895 done 33896 done 33897 IFS=$as_save_IFS 33898 33899 ;; 33900 esac 33901 fi 33902 ac_pt_TOOLCHAIN_PATH_CC=$ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC 33903 if test -n "$ac_pt_TOOLCHAIN_PATH_CC"; then 33904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_TOOLCHAIN_PATH_CC" >&5 33905 $as_echo "$ac_pt_TOOLCHAIN_PATH_CC" >&6; } 33906 else 33907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33908 $as_echo "no" >&6; } 33909 fi 33910 33911 if test "x$ac_pt_TOOLCHAIN_PATH_CC" = x; then 33912 TOOLCHAIN_PATH_CC="" 33913 else 33914 case $cross_compiling:$ac_tool_warned in 33915 yes:) 33916 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 33917 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 33918 ac_tool_warned=yes ;; 33919 esac 33920 TOOLCHAIN_PATH_CC=$ac_pt_TOOLCHAIN_PATH_CC 33921 fi 33922 else 33923 TOOLCHAIN_PATH_CC="$ac_cv_path_TOOLCHAIN_PATH_CC" 33924 fi 33925 33926 CC=$TOOLCHAIN_PATH_CC 33927 PATH="$PATH_save" 33928 fi 33929 33930 # AC_PATH_TOOL can't be run multiple times with the same variable, 33931 # so create a new name for this run. 33932 if test "x$CC" = x; then 33933 if test -n "$ac_tool_prefix"; then 33934 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 33935 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 33936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33937 $as_echo_n "checking for $ac_word... " >&6; } 33938 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33939 $as_echo_n "(cached) " >&6 33940 else 33941 case $POTENTIAL_CC in 33942 [\\/]* | ?:[\\/]*) 33943 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33944 ;; 33945 *) 33946 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33947 for as_dir in $PATH 33948 do 33949 IFS=$as_save_IFS 33950 test -z "$as_dir" && as_dir=. 33951 for ac_exec_ext in '' $ac_executable_extensions; do 33952 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33953 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33954 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33955 break 2 33956 fi 33957 done 33958 done 33959 IFS=$as_save_IFS 33960 33961 ;; 33962 esac 33963 fi 33964 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33965 if test -n "$POTENTIAL_CC"; then 33966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33967 $as_echo "$POTENTIAL_CC" >&6; } 33968 else 33969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33970 $as_echo "no" >&6; } 33971 fi 33972 33973 33974 fi 33975 if test -z "$ac_cv_path_POTENTIAL_CC"; then 33976 ac_pt_POTENTIAL_CC=$POTENTIAL_CC 33977 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 33978 set dummy $SEARCH_LIST; ac_word=$2 33979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33980 $as_echo_n "checking for $ac_word... " >&6; } 33981 if ${ac_cv_path_ac_pt_POTENTIAL_CC+:} false; then : 33982 $as_echo_n "(cached) " >&6 33983 else 33984 case $ac_pt_POTENTIAL_CC in 33985 [\\/]* | ?:[\\/]*) 33986 ac_cv_path_ac_pt_POTENTIAL_CC="$ac_pt_POTENTIAL_CC" # Let the user override the test with a path. 33987 ;; 33988 *) 33989 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33990 for as_dir in $PATH 33991 do 33992 IFS=$as_save_IFS 33993 test -z "$as_dir" && as_dir=. 33994 for ac_exec_ext in '' $ac_executable_extensions; do 33995 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33996 ac_cv_path_ac_pt_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33997 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33998 break 2 33999 fi 34000 done 34001 done 34002 IFS=$as_save_IFS 34003 34004 ;; 34005 esac 34006 fi 34007 ac_pt_POTENTIAL_CC=$ac_cv_path_ac_pt_POTENTIAL_CC 34008 if test -n "$ac_pt_POTENTIAL_CC"; then 34009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_POTENTIAL_CC" >&5 34010 $as_echo "$ac_pt_POTENTIAL_CC" >&6; } 34011 else 34012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34013 $as_echo "no" >&6; } 34014 fi 34015 34016 if test "x$ac_pt_POTENTIAL_CC" = x; then 34017 POTENTIAL_CC="" 34018 else 34019 case $cross_compiling:$ac_tool_warned in 34020 yes:) 34021 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 34022 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 34023 ac_tool_warned=yes ;; 34024 esac 34025 POTENTIAL_CC=$ac_pt_POTENTIAL_CC 34026 fi 34027 else 34028 POTENTIAL_CC="$ac_cv_path_POTENTIAL_CC" 34029 fi 34030 34031 CC=$POTENTIAL_CC 34032 fi 34033 34034 if test "x$CC" = x; then 34035 34036 # Print a helpful message on how to acquire the necessary build dependency. 34037 # devkit is the help tag: freetype, cups, alsa etc 34038 MISSING_DEPENDENCY=devkit 34039 34040 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34041 cygwin_help $MISSING_DEPENDENCY 34042 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34043 msys_help $MISSING_DEPENDENCY 34044 else 34045 PKGHANDLER_COMMAND= 34046 34047 case $PKGHANDLER in 34048 apt-get) 34049 apt_help $MISSING_DEPENDENCY ;; 34050 yum) 34051 yum_help $MISSING_DEPENDENCY ;; 34052 brew) 34053 brew_help $MISSING_DEPENDENCY ;; 34054 port) 34055 port_help $MISSING_DEPENDENCY ;; 34056 pkgutil) 34057 pkgutil_help $MISSING_DEPENDENCY ;; 34058 pkgadd) 34059 pkgadd_help $MISSING_DEPENDENCY ;; 34060 esac 34061 34062 if test "x$PKGHANDLER_COMMAND" != x; then 34063 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 34064 fi 34065 fi 34066 34067 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 34068 fi 34069 fi 34070 34071 # Now we have a compiler binary in CC. Make sure it's okay. 34072 34073 # Only process if variable expands to non-empty 34074 34075 if test "x$CC" != x; then 34076 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34077 34078 # First separate the path from the arguments. This will split at the first 34079 # space. 34080 complete="$CC" 34081 path="${complete%% *}" 34082 tmp="$complete EOL" 34083 arguments="${tmp#* }" 34084 34085 # Input might be given as Windows format, start by converting to 34086 # unix format. 34087 new_path=`$CYGPATH -u "$path"` 34088 34089 # Now try to locate executable using which 34090 new_path=`$WHICH "$new_path" 2> /dev/null` 34091 # bat and cmd files are not always considered executable in cygwin causing which 34092 # to not find them 34093 if test "x$new_path" = x \ 34094 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34095 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34096 new_path=`$CYGPATH -u "$path"` 34097 fi 34098 if test "x$new_path" = x; then 34099 # Oops. Which didn't find the executable. 34100 # The splitting of arguments from the executable at a space might have been incorrect, 34101 # since paths with space are more likely in Windows. Give it another try with the whole 34102 # argument. 34103 path="$complete" 34104 arguments="EOL" 34105 new_path=`$CYGPATH -u "$path"` 34106 new_path=`$WHICH "$new_path" 2> /dev/null` 34107 # bat and cmd files are not always considered executable in cygwin causing which 34108 # to not find them 34109 if test "x$new_path" = x \ 34110 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34111 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34112 new_path=`$CYGPATH -u "$path"` 34113 fi 34114 if test "x$new_path" = x; then 34115 # It's still not found. Now this is an unrecoverable error. 34116 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 34117 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 34118 has_space=`$ECHO "$complete" | $GREP " "` 34119 if test "x$has_space" != x; then 34120 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34121 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34122 fi 34123 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34124 fi 34125 fi 34126 34127 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 34128 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 34129 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 34130 # "foo.exe" is OK but "foo" is an error. 34131 # 34132 # This test is therefore slightly more accurate than "test -f" to check for file presence. 34133 # It is also a way to make sure we got the proper file name for the real test later on. 34134 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 34135 if test "x$test_shortpath" = x; then 34136 # Short path failed, file does not exist as specified. 34137 # Try adding .exe or .cmd 34138 if test -f "${new_path}.exe"; then 34139 input_to_shortpath="${new_path}.exe" 34140 elif test -f "${new_path}.cmd"; then 34141 input_to_shortpath="${new_path}.cmd" 34142 else 34143 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5 34144 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;} 34145 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 34146 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 34147 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34148 fi 34149 else 34150 input_to_shortpath="$new_path" 34151 fi 34152 34153 # Call helper function which possibly converts this using DOS-style short mode. 34154 # If so, the updated path is stored in $new_path. 34155 new_path="$input_to_shortpath" 34156 34157 input_path="$input_to_shortpath" 34158 # Check if we need to convert this using DOS-style short mode. If the path 34159 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34160 # take no chances and rewrite it. 34161 # Note: m4 eats our [], so we need to use [ and ] instead. 34162 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 34163 if test "x$has_forbidden_chars" != x; then 34164 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34165 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 34166 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 34167 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 34168 # Going to short mode and back again did indeed matter. Since short mode is 34169 # case insensitive, let's make it lowercase to improve readability. 34170 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34171 # Now convert it back to Unix-style (cygpath) 34172 input_path=`$CYGPATH -u "$shortmode_path"` 34173 new_path="$input_path" 34174 fi 34175 fi 34176 34177 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 34178 if test "x$test_cygdrive_prefix" = x; then 34179 # As a simple fix, exclude /usr/bin since it's not a real path. 34180 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 34181 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 34182 # a path prefixed by /cygdrive for fixpath to work. 34183 new_path="$CYGWIN_ROOT_PATH$input_path" 34184 fi 34185 fi 34186 34187 # remove trailing .exe if any 34188 new_path="${new_path/%.exe/}" 34189 34190 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34191 34192 # First separate the path from the arguments. This will split at the first 34193 # space. 34194 complete="$CC" 34195 path="${complete%% *}" 34196 tmp="$complete EOL" 34197 arguments="${tmp#* }" 34198 34199 # Input might be given as Windows format, start by converting to 34200 # unix format. 34201 new_path="$path" 34202 34203 windows_path="$new_path" 34204 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34205 unix_path=`$CYGPATH -u "$windows_path"` 34206 new_path="$unix_path" 34207 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34208 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34209 new_path="$unix_path" 34210 fi 34211 34212 34213 # Now try to locate executable using which 34214 new_path=`$WHICH "$new_path" 2> /dev/null` 34215 34216 if test "x$new_path" = x; then 34217 # Oops. Which didn't find the executable. 34218 # The splitting of arguments from the executable at a space might have been incorrect, 34219 # since paths with space are more likely in Windows. Give it another try with the whole 34220 # argument. 34221 path="$complete" 34222 arguments="EOL" 34223 new_path="$path" 34224 34225 windows_path="$new_path" 34226 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34227 unix_path=`$CYGPATH -u "$windows_path"` 34228 new_path="$unix_path" 34229 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34230 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34231 new_path="$unix_path" 34232 fi 34233 34234 34235 new_path=`$WHICH "$new_path" 2> /dev/null` 34236 # bat and cmd files are not always considered executable in MSYS causing which 34237 # to not find them 34238 if test "x$new_path" = x \ 34239 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34240 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34241 new_path="$path" 34242 34243 windows_path="$new_path" 34244 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34245 unix_path=`$CYGPATH -u "$windows_path"` 34246 new_path="$unix_path" 34247 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34248 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34249 new_path="$unix_path" 34250 fi 34251 34252 fi 34253 34254 if test "x$new_path" = x; then 34255 # It's still not found. Now this is an unrecoverable error. 34256 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 34257 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 34258 has_space=`$ECHO "$complete" | $GREP " "` 34259 if test "x$has_space" != x; then 34260 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34261 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34262 fi 34263 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34264 fi 34265 fi 34266 34267 # Now new_path has a complete unix path to the binary 34268 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 34269 # Keep paths in /bin as-is, but remove trailing .exe if any 34270 new_path="${new_path/%.exe/}" 34271 # Do not save /bin paths to all_fixpath_prefixes! 34272 else 34273 # Not in mixed or Windows style, start by that. 34274 new_path=`cmd //c echo $new_path` 34275 34276 input_path="$new_path" 34277 # Check if we need to convert this using DOS-style short mode. If the path 34278 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34279 # take no chances and rewrite it. 34280 # Note: m4 eats our [], so we need to use [ and ] instead. 34281 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 34282 if test "x$has_forbidden_chars" != x; then 34283 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34284 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34285 fi 34286 34287 # Output is in $new_path 34288 34289 windows_path="$new_path" 34290 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34291 unix_path=`$CYGPATH -u "$windows_path"` 34292 new_path="$unix_path" 34293 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34294 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34295 new_path="$unix_path" 34296 fi 34297 34298 # remove trailing .exe if any 34299 new_path="${new_path/%.exe/}" 34300 34301 # Save the first 10 bytes of this path to the storage, so fixpath can work. 34302 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 34303 fi 34304 34305 else 34306 # We're on a unix platform. Hooray! :) 34307 # First separate the path from the arguments. This will split at the first 34308 # space. 34309 complete="$CC" 34310 path="${complete%% *}" 34311 tmp="$complete EOL" 34312 arguments="${tmp#* }" 34313 34314 # Cannot rely on the command "which" here since it doesn't always work. 34315 is_absolute_path=`$ECHO "$path" | $GREP ^/` 34316 if test -z "$is_absolute_path"; then 34317 # Path to executable is not absolute. Find it. 34318 IFS_save="$IFS" 34319 IFS=: 34320 for p in $PATH; do 34321 if test -f "$p/$path" && test -x "$p/$path"; then 34322 new_path="$p/$path" 34323 break 34324 fi 34325 done 34326 IFS="$IFS_save" 34327 else 34328 # This is an absolute path, we can use it without further modifications. 34329 new_path="$path" 34330 fi 34331 34332 if test "x$new_path" = x; then 34333 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 34334 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 34335 has_space=`$ECHO "$complete" | $GREP " "` 34336 if test "x$has_space" != x; then 34337 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 34338 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 34339 fi 34340 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34341 fi 34342 fi 34343 34344 # Now join together the path and the arguments once again 34345 if test "x$arguments" != xEOL; then 34346 new_complete="$new_path ${arguments% *}" 34347 else 34348 new_complete="$new_path" 34349 fi 34350 34351 if test "x$complete" != "x$new_complete"; then 34352 CC="$new_complete" 34353 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5 34354 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;} 34355 fi 34356 fi 34357 34358 TEST_COMPILER="$CC" 34359 34360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5 34361 $as_echo_n "checking resolved symbolic links for CC... " >&6; } 34362 SYMLINK_ORIGINAL="$TEST_COMPILER" 34363 34364 if test "x$OPENJDK_BUILD_OS" != xwindows; then 34365 # Follow a chain of symbolic links. Use readlink 34366 # where it exists, else fall back to horribly 34367 # complicated shell code. 34368 if test "x$READLINK_TESTED" != yes; then 34369 # On MacOSX there is a readlink tool with a different 34370 # purpose than the GNU readlink tool. Check the found readlink. 34371 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 34372 if test "x$ISGNU" = x; then 34373 # A readlink that we do not know how to use. 34374 # Are there other non-GNU readlinks out there? 34375 READLINK_TESTED=yes 34376 READLINK= 34377 fi 34378 fi 34379 34380 if test "x$READLINK" != x; then 34381 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 34382 else 34383 # Save the current directory for restoring afterwards 34384 STARTDIR=$PWD 34385 COUNTER=0 34386 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 34387 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 34388 cd $sym_link_dir 34389 # Use -P flag to resolve symlinks in directories. 34390 cd `$THEPWDCMD -P` 34391 sym_link_dir=`$THEPWDCMD -P` 34392 # Resolve file symlinks 34393 while test $COUNTER -lt 20; do 34394 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 34395 if test "x$ISLINK" == x; then 34396 # This is not a symbolic link! We are done! 34397 break 34398 fi 34399 # Again resolve directory symlinks since the target of the just found 34400 # link could be in a different directory 34401 cd `$DIRNAME $ISLINK` 34402 sym_link_dir=`$THEPWDCMD -P` 34403 sym_link_file=`$BASENAME $ISLINK` 34404 let COUNTER=COUNTER+1 34405 done 34406 cd $STARTDIR 34407 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 34408 fi 34409 fi 34410 34411 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 34412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 34413 $as_echo "no symlink" >&6; } 34414 else 34415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 34416 $as_echo "$SYMLINK_ORIGINAL" >&6; } 34417 34418 # We can't handle ccache by gcc wrappers, since we need to know if we're 34419 # using ccache. Instead ccache usage must be controlled by a configure option. 34420 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 34421 if test "x$COMPILER_BASENAME" = "xccache"; then 34422 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 34423 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 34424 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 34425 fi 34426 fi 34427 34428 34429 COMPILER=$CC 34430 COMPILER_NAME=$COMPILER_NAME 34431 34432 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 34433 # cc -V output typically looks like 34434 # cc: Sun C 5.12 Linux_i386 2011/11/16 34435 # or 34436 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 34437 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 34438 # Check that this is likely to be the Solaris Studio cc. 34439 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 34440 if test $? -ne 0; then 34441 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34442 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 34443 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34444 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34445 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34446 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34447 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34448 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34449 fi 34450 # Remove usage instructions (if present), and 34451 # collapse compiler output into a single line 34452 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34453 $SED -e 's/ *[Uu]sage:.*//'` 34454 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34455 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 34456 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 34457 # xlc -qversion output typically looks like 34458 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 34459 # Version: 11.01.0000.0015 34460 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 34461 # Check that this is likely to be the IBM XL C compiler. 34462 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 34463 if test $? -ne 0; then 34464 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34465 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 34466 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34467 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34468 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34469 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34470 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34471 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34472 fi 34473 # Collapse compiler output into a single line 34474 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34475 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34476 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 34477 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 34478 # There is no specific version flag, but all output starts with a version string. 34479 # First line typically looks something like: 34480 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 34481 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 34482 # Check that this is likely to be Microsoft CL.EXE. 34483 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 34484 if test $? -ne 0; then 34485 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 34486 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34487 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34488 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34489 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34490 fi 34491 # Collapse compiler output into a single line 34492 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34493 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34494 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 34495 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 34496 # gcc --version output typically looks like 34497 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 34498 # Copyright (C) 2013 Free Software Foundation, Inc. 34499 # This is free software; see the source for copying conditions. There is NO 34500 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 34501 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34502 # Check that this is likely to be GCC. 34503 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 34504 if test $? -ne 0; then 34505 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 34506 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34507 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 34508 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 34509 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34510 fi 34511 # Remove Copyright and legalese from version string, and 34512 # collapse into a single line 34513 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34514 $SED -e 's/ *Copyright .*//'` 34515 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34516 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 34517 elif test "x$TOOLCHAIN_TYPE" = xclang; then 34518 # clang --version output typically looks like 34519 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 34520 # clang version 3.3 (tags/RELEASE_33/final) 34521 # or 34522 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 34523 # Target: x86_64-pc-linux-gnu 34524 # Thread model: posix 34525 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34526 # Check that this is likely to be clang 34527 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 34528 if test $? -ne 0; then 34529 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 34530 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34531 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34532 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34533 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34534 fi 34535 # Collapse compiler output into a single line 34536 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34537 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34538 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 34539 else 34540 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 34541 fi 34542 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 34543 CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 34544 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 34545 CC_VERSION_STRING="$COMPILER_VERSION_STRING" 34546 34547 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 34548 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 34549 34550 34551 # Now that we have resolved CC ourself, let autoconf have its go at it 34552 ac_ext=c 34553 ac_cpp='$CPP $CPPFLAGS' 34554 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34555 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34556 ac_compiler_gnu=$ac_cv_c_compiler_gnu 34557 if test -n "$ac_tool_prefix"; then 34558 for ac_prog in $CC 34559 do 34560 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 34561 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 34562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34563 $as_echo_n "checking for $ac_word... " >&6; } 34564 if ${ac_cv_prog_CC+:} false; then : 34565 $as_echo_n "(cached) " >&6 34566 else 34567 if test -n "$CC"; then 34568 ac_cv_prog_CC="$CC" # Let the user override the test. 34569 else 34570 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34571 for as_dir in $PATH 34572 do 34573 IFS=$as_save_IFS 34574 test -z "$as_dir" && as_dir=. 34575 for ac_exec_ext in '' $ac_executable_extensions; do 34576 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34577 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 34578 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34579 break 2 34580 fi 34581 done 34582 done 34583 IFS=$as_save_IFS 34584 34585 fi 34586 fi 34587 CC=$ac_cv_prog_CC 34588 if test -n "$CC"; then 34589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 34590 $as_echo "$CC" >&6; } 34591 else 34592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34593 $as_echo "no" >&6; } 34594 fi 34595 34596 34597 test -n "$CC" && break 34598 done 34599 fi 34600 if test -z "$CC"; then 34601 ac_ct_CC=$CC 34602 for ac_prog in $CC 34603 do 34604 # Extract the first word of "$ac_prog", so it can be a program name with args. 34605 set dummy $ac_prog; ac_word=$2 34606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34607 $as_echo_n "checking for $ac_word... " >&6; } 34608 if ${ac_cv_prog_ac_ct_CC+:} false; then : 34609 $as_echo_n "(cached) " >&6 34610 else 34611 if test -n "$ac_ct_CC"; then 34612 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 34613 else 34614 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34615 for as_dir in $PATH 34616 do 34617 IFS=$as_save_IFS 34618 test -z "$as_dir" && as_dir=. 34619 for ac_exec_ext in '' $ac_executable_extensions; do 34620 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34621 ac_cv_prog_ac_ct_CC="$ac_prog" 34622 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34623 break 2 34624 fi 34625 done 34626 done 34627 IFS=$as_save_IFS 34628 34629 fi 34630 fi 34631 ac_ct_CC=$ac_cv_prog_ac_ct_CC 34632 if test -n "$ac_ct_CC"; then 34633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 34634 $as_echo "$ac_ct_CC" >&6; } 34635 else 34636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34637 $as_echo "no" >&6; } 34638 fi 34639 34640 34641 test -n "$ac_ct_CC" && break 34642 done 34643 34644 if test "x$ac_ct_CC" = x; then 34645 CC="" 34646 else 34647 case $cross_compiling:$ac_tool_warned in 34648 yes:) 34649 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 34650 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 34651 ac_tool_warned=yes ;; 34652 esac 34653 CC=$ac_ct_CC 34654 fi 34655 fi 34656 34657 34658 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34659 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34660 as_fn_error $? "no acceptable C compiler found in \$PATH 34661 See \`config.log' for more details" "$LINENO" 5; } 34662 34663 # Provide some information about the compiler. 34664 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 34665 set X $ac_compile 34666 ac_compiler=$2 34667 for ac_option in --version -v -V -qversion; do 34668 { { ac_try="$ac_compiler $ac_option >&5" 34669 case "(($ac_try" in 34670 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34671 *) ac_try_echo=$ac_try;; 34672 esac 34673 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34674 $as_echo "$ac_try_echo"; } >&5 34675 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 34676 ac_status=$? 34677 if test -s conftest.err; then 34678 sed '10a\ 34679 ... rest of stderr output deleted ... 34680 10q' conftest.err >conftest.er1 34681 cat conftest.er1 >&5 34682 fi 34683 rm -f conftest.er1 conftest.err 34684 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34685 test $ac_status = 0; } 34686 done 34687 34688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34689 /* end confdefs.h. */ 34690 34691 int 34692 main () 34693 { 34694 34695 ; 34696 return 0; 34697 } 34698 _ACEOF 34699 ac_clean_files_save=$ac_clean_files 34700 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 34701 # Try to create an executable without -o first, disregard a.out. 34702 # It will help us diagnose broken compilers, and finding out an intuition 34703 # of exeext. 34704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 34705 $as_echo_n "checking whether the C compiler works... " >&6; } 34706 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 34707 34708 # The possible output files: 34709 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 34710 34711 ac_rmfiles= 34712 for ac_file in $ac_files 34713 do 34714 case $ac_file in 34715 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 34716 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 34717 esac 34718 done 34719 rm -f $ac_rmfiles 34720 34721 if { { ac_try="$ac_link_default" 34722 case "(($ac_try" in 34723 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34724 *) ac_try_echo=$ac_try;; 34725 esac 34726 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34727 $as_echo "$ac_try_echo"; } >&5 34728 (eval "$ac_link_default") 2>&5 34729 ac_status=$? 34730 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34731 test $ac_status = 0; }; then : 34732 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 34733 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 34734 # in a Makefile. We should not override ac_cv_exeext if it was cached, 34735 # so that the user can short-circuit this test for compilers unknown to 34736 # Autoconf. 34737 for ac_file in $ac_files '' 34738 do 34739 test -f "$ac_file" || continue 34740 case $ac_file in 34741 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 34742 ;; 34743 [ab].out ) 34744 # We found the default executable, but exeext='' is most 34745 # certainly right. 34746 break;; 34747 *.* ) 34748 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 34749 then :; else 34750 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 34751 fi 34752 # We set ac_cv_exeext here because the later test for it is not 34753 # safe: cross compilers may not add the suffix if given an `-o' 34754 # argument, so we may need to know it at that point already. 34755 # Even if this section looks crufty: it has the advantage of 34756 # actually working. 34757 break;; 34758 * ) 34759 break;; 34760 esac 34761 done 34762 test "$ac_cv_exeext" = no && ac_cv_exeext= 34763 34764 else 34765 ac_file='' 34766 fi 34767 if test -z "$ac_file"; then : 34768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34769 $as_echo "no" >&6; } 34770 $as_echo "$as_me: failed program was:" >&5 34771 sed 's/^/| /' conftest.$ac_ext >&5 34772 34773 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34774 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34775 as_fn_error 77 "C compiler cannot create executables 34776 See \`config.log' for more details" "$LINENO" 5; } 34777 else 34778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 34779 $as_echo "yes" >&6; } 34780 fi 34781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 34782 $as_echo_n "checking for C compiler default output file name... " >&6; } 34783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 34784 $as_echo "$ac_file" >&6; } 34785 ac_exeext=$ac_cv_exeext 34786 34787 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 34788 ac_clean_files=$ac_clean_files_save 34789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 34790 $as_echo_n "checking for suffix of executables... " >&6; } 34791 if { { ac_try="$ac_link" 34792 case "(($ac_try" in 34793 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34794 *) ac_try_echo=$ac_try;; 34795 esac 34796 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34797 $as_echo "$ac_try_echo"; } >&5 34798 (eval "$ac_link") 2>&5 34799 ac_status=$? 34800 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34801 test $ac_status = 0; }; then : 34802 # If both `conftest.exe' and `conftest' are `present' (well, observable) 34803 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 34804 # work properly (i.e., refer to `conftest.exe'), while it won't with 34805 # `rm'. 34806 for ac_file in conftest.exe conftest conftest.*; do 34807 test -f "$ac_file" || continue 34808 case $ac_file in 34809 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 34810 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 34811 break;; 34812 * ) break;; 34813 esac 34814 done 34815 else 34816 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34817 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34818 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 34819 See \`config.log' for more details" "$LINENO" 5; } 34820 fi 34821 rm -f conftest conftest$ac_cv_exeext 34822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 34823 $as_echo "$ac_cv_exeext" >&6; } 34824 34825 rm -f conftest.$ac_ext 34826 EXEEXT=$ac_cv_exeext 34827 ac_exeext=$EXEEXT 34828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34829 /* end confdefs.h. */ 34830 #include <stdio.h> 34831 int 34832 main () 34833 { 34834 FILE *f = fopen ("conftest.out", "w"); 34835 return ferror (f) || fclose (f) != 0; 34836 34837 ; 34838 return 0; 34839 } 34840 _ACEOF 34841 ac_clean_files="$ac_clean_files conftest.out" 34842 # Check that the compiler produces executables we can run. If not, either 34843 # the compiler is broken, or we cross compile. 34844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 34845 $as_echo_n "checking whether we are cross compiling... " >&6; } 34846 if test "$cross_compiling" != yes; then 34847 { { ac_try="$ac_link" 34848 case "(($ac_try" in 34849 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34850 *) ac_try_echo=$ac_try;; 34851 esac 34852 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34853 $as_echo "$ac_try_echo"; } >&5 34854 (eval "$ac_link") 2>&5 34855 ac_status=$? 34856 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34857 test $ac_status = 0; } 34858 if { ac_try='./conftest$ac_cv_exeext' 34859 { { case "(($ac_try" in 34860 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34861 *) ac_try_echo=$ac_try;; 34862 esac 34863 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34864 $as_echo "$ac_try_echo"; } >&5 34865 (eval "$ac_try") 2>&5 34866 ac_status=$? 34867 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34868 test $ac_status = 0; }; }; then 34869 cross_compiling=no 34870 else 34871 if test "$cross_compiling" = maybe; then 34872 cross_compiling=yes 34873 else 34874 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34875 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34876 as_fn_error $? "cannot run C compiled programs. 34877 If you meant to cross compile, use \`--host'. 34878 See \`config.log' for more details" "$LINENO" 5; } 34879 fi 34880 fi 34881 fi 34882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 34883 $as_echo "$cross_compiling" >&6; } 34884 34885 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 34886 ac_clean_files=$ac_clean_files_save 34887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 34888 $as_echo_n "checking for suffix of object files... " >&6; } 34889 if ${ac_cv_objext+:} false; then : 34890 $as_echo_n "(cached) " >&6 34891 else 34892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34893 /* end confdefs.h. */ 34894 34895 int 34896 main () 34897 { 34898 34899 ; 34900 return 0; 34901 } 34902 _ACEOF 34903 rm -f conftest.o conftest.obj 34904 if { { ac_try="$ac_compile" 34905 case "(($ac_try" in 34906 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34907 *) ac_try_echo=$ac_try;; 34908 esac 34909 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34910 $as_echo "$ac_try_echo"; } >&5 34911 (eval "$ac_compile") 2>&5 34912 ac_status=$? 34913 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34914 test $ac_status = 0; }; then : 34915 for ac_file in conftest.o conftest.obj conftest.*; do 34916 test -f "$ac_file" || continue; 34917 case $ac_file in 34918 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 34919 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 34920 break;; 34921 esac 34922 done 34923 else 34924 $as_echo "$as_me: failed program was:" >&5 34925 sed 's/^/| /' conftest.$ac_ext >&5 34926 34927 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34928 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34929 as_fn_error $? "cannot compute suffix of object files: cannot compile 34930 See \`config.log' for more details" "$LINENO" 5; } 34931 fi 34932 rm -f conftest.$ac_cv_objext conftest.$ac_ext 34933 fi 34934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 34935 $as_echo "$ac_cv_objext" >&6; } 34936 OBJEXT=$ac_cv_objext 34937 ac_objext=$OBJEXT 34938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 34939 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 34940 if ${ac_cv_c_compiler_gnu+:} false; then : 34941 $as_echo_n "(cached) " >&6 34942 else 34943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34944 /* end confdefs.h. */ 34945 34946 int 34947 main () 34948 { 34949 #ifndef __GNUC__ 34950 choke me 34951 #endif 34952 34953 ; 34954 return 0; 34955 } 34956 _ACEOF 34957 if ac_fn_c_try_compile "$LINENO"; then : 34958 ac_compiler_gnu=yes 34959 else 34960 ac_compiler_gnu=no 34961 fi 34962 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34963 ac_cv_c_compiler_gnu=$ac_compiler_gnu 34964 34965 fi 34966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 34967 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 34968 if test $ac_compiler_gnu = yes; then 34969 GCC=yes 34970 else 34971 GCC= 34972 fi 34973 ac_test_CFLAGS=${CFLAGS+set} 34974 ac_save_CFLAGS=$CFLAGS 34975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 34976 $as_echo_n "checking whether $CC accepts -g... " >&6; } 34977 if ${ac_cv_prog_cc_g+:} false; then : 34978 $as_echo_n "(cached) " >&6 34979 else 34980 ac_save_c_werror_flag=$ac_c_werror_flag 34981 ac_c_werror_flag=yes 34982 ac_cv_prog_cc_g=no 34983 CFLAGS="-g" 34984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34985 /* end confdefs.h. */ 34986 34987 int 34988 main () 34989 { 34990 34991 ; 34992 return 0; 34993 } 34994 _ACEOF 34995 if ac_fn_c_try_compile "$LINENO"; then : 34996 ac_cv_prog_cc_g=yes 34997 else 34998 CFLAGS="" 34999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35000 /* end confdefs.h. */ 35001 35002 int 35003 main () 35004 { 35005 35006 ; 35007 return 0; 35008 } 35009 _ACEOF 35010 if ac_fn_c_try_compile "$LINENO"; then : 35011 35012 else 35013 ac_c_werror_flag=$ac_save_c_werror_flag 35014 CFLAGS="-g" 35015 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35016 /* end confdefs.h. */ 35017 35018 int 35019 main () 35020 { 35021 35022 ; 35023 return 0; 35024 } 35025 _ACEOF 35026 if ac_fn_c_try_compile "$LINENO"; then : 35027 ac_cv_prog_cc_g=yes 35028 fi 35029 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35030 fi 35031 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35032 fi 35033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35034 ac_c_werror_flag=$ac_save_c_werror_flag 35035 fi 35036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 35037 $as_echo "$ac_cv_prog_cc_g" >&6; } 35038 if test "$ac_test_CFLAGS" = set; then 35039 CFLAGS=$ac_save_CFLAGS 35040 elif test $ac_cv_prog_cc_g = yes; then 35041 if test "$GCC" = yes; then 35042 CFLAGS="-g -O2" 35043 else 35044 CFLAGS="-g" 35045 fi 35046 else 35047 if test "$GCC" = yes; then 35048 CFLAGS="-O2" 35049 else 35050 CFLAGS= 35051 fi 35052 fi 35053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 35054 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 35055 if ${ac_cv_prog_cc_c89+:} false; then : 35056 $as_echo_n "(cached) " >&6 35057 else 35058 ac_cv_prog_cc_c89=no 35059 ac_save_CC=$CC 35060 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35061 /* end confdefs.h. */ 35062 #include <stdarg.h> 35063 #include <stdio.h> 35064 struct stat; 35065 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 35066 struct buf { int x; }; 35067 FILE * (*rcsopen) (struct buf *, struct stat *, int); 35068 static char *e (p, i) 35069 char **p; 35070 int i; 35071 { 35072 return p[i]; 35073 } 35074 static char *f (char * (*g) (char **, int), char **p, ...) 35075 { 35076 char *s; 35077 va_list v; 35078 va_start (v,p); 35079 s = g (p, va_arg (v,int)); 35080 va_end (v); 35081 return s; 35082 } 35083 35084 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 35085 function prototypes and stuff, but not '\xHH' hex character constants. 35086 These don't provoke an error unfortunately, instead are silently treated 35087 as 'x'. The following induces an error, until -std is added to get 35088 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 35089 array size at least. It's necessary to write '\x00'==0 to get something 35090 that's true only with -std. */ 35091 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 35092 35093 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 35094 inside strings and character constants. */ 35095 #define FOO(x) 'x' 35096 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 35097 35098 int test (int i, double x); 35099 struct s1 {int (*f) (int a);}; 35100 struct s2 {int (*f) (double a);}; 35101 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 35102 int argc; 35103 char **argv; 35104 int 35105 main () 35106 { 35107 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 35108 ; 35109 return 0; 35110 } 35111 _ACEOF 35112 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 35113 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 35114 do 35115 CC="$ac_save_CC $ac_arg" 35116 if ac_fn_c_try_compile "$LINENO"; then : 35117 ac_cv_prog_cc_c89=$ac_arg 35118 fi 35119 rm -f core conftest.err conftest.$ac_objext 35120 test "x$ac_cv_prog_cc_c89" != "xno" && break 35121 done 35122 rm -f conftest.$ac_ext 35123 CC=$ac_save_CC 35124 35125 fi 35126 # AC_CACHE_VAL 35127 case "x$ac_cv_prog_cc_c89" in 35128 x) 35129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 35130 $as_echo "none needed" >&6; } ;; 35131 xno) 35132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 35133 $as_echo "unsupported" >&6; } ;; 35134 *) 35135 CC="$CC $ac_cv_prog_cc_c89" 35136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 35137 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 35138 esac 35139 if test "x$ac_cv_prog_cc_c89" != xno; then : 35140 35141 fi 35142 35143 ac_ext=cpp 35144 ac_cpp='$CXXCPP $CPPFLAGS' 35145 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35146 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35147 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35148 35149 35150 35151 COMPILER_NAME=C++ 35152 SEARCH_LIST="$TOOLCHAIN_CXX_BINARY" 35153 35154 if test "x$CXX" != x; then 35155 # User has supplied compiler name already, always let that override. 35156 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5 35157 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;} 35158 if test "x`basename $CXX`" = "x$CXX"; then 35159 # A command without a complete path is provided, search $PATH. 35160 35161 for ac_prog in $CXX 35162 do 35163 # Extract the first word of "$ac_prog", so it can be a program name with args. 35164 set dummy $ac_prog; ac_word=$2 35165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35166 $as_echo_n "checking for $ac_word... " >&6; } 35167 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 35168 $as_echo_n "(cached) " >&6 35169 else 35170 case $POTENTIAL_CXX in 35171 [\\/]* | ?:[\\/]*) 35172 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 35173 ;; 35174 *) 35175 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35176 for as_dir in $PATH 35177 do 35178 IFS=$as_save_IFS 35179 test -z "$as_dir" && as_dir=. 35180 for ac_exec_ext in '' $ac_executable_extensions; do 35181 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35182 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 35183 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35184 break 2 35185 fi 35186 done 35187 done 35188 IFS=$as_save_IFS 35189 35190 ;; 35191 esac 35192 fi 35193 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 35194 if test -n "$POTENTIAL_CXX"; then 35195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 35196 $as_echo "$POTENTIAL_CXX" >&6; } 35197 else 35198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35199 $as_echo "no" >&6; } 35200 fi 35201 35202 35203 test -n "$POTENTIAL_CXX" && break 35204 done 35205 35206 if test "x$POTENTIAL_CXX" != x; then 35207 CXX=$POTENTIAL_CXX 35208 else 35209 as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5 35210 fi 35211 else 35212 # Otherwise it might already be a complete path 35213 if test ! -x "$CXX"; then 35214 as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5 35215 fi 35216 fi 35217 else 35218 # No user supplied value. Locate compiler ourselves. 35219 35220 # If we are cross compiling, assume cross compilation tools follows the 35221 # cross compilation standard where they are prefixed with the autoconf 35222 # standard name for the target. For example the binary 35223 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 35224 # If we are not cross compiling, then the default compiler name will be 35225 # used. 35226 35227 CXX= 35228 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 35229 # before checking the rest of the PATH. 35230 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 35231 # step, this should not be necessary. 35232 if test -n "$TOOLCHAIN_PATH"; then 35233 PATH_save="$PATH" 35234 PATH="$TOOLCHAIN_PATH" 35235 if test -n "$ac_tool_prefix"; then 35236 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 35237 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 35238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35239 $as_echo_n "checking for $ac_word... " >&6; } 35240 if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then : 35241 $as_echo_n "(cached) " >&6 35242 else 35243 case $TOOLCHAIN_PATH_CXX in 35244 [\\/]* | ?:[\\/]*) 35245 ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 35246 ;; 35247 *) 35248 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35249 for as_dir in $PATH 35250 do 35251 IFS=$as_save_IFS 35252 test -z "$as_dir" && as_dir=. 35253 for ac_exec_ext in '' $ac_executable_extensions; do 35254 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35255 ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 35256 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35257 break 2 35258 fi 35259 done 35260 done 35261 IFS=$as_save_IFS 35262 35263 ;; 35264 esac 35265 fi 35266 TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX 35267 if test -n "$TOOLCHAIN_PATH_CXX"; then 35268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5 35269 $as_echo "$TOOLCHAIN_PATH_CXX" >&6; } 35270 else 35271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35272 $as_echo "no" >&6; } 35273 fi 35274 35275 35276 fi 35277 if test -z "$ac_cv_path_TOOLCHAIN_PATH_CXX"; then 35278 ac_pt_TOOLCHAIN_PATH_CXX=$TOOLCHAIN_PATH_CXX 35279 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 35280 set dummy $SEARCH_LIST; ac_word=$2 35281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35282 $as_echo_n "checking for $ac_word... " >&6; } 35283 if ${ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX+:} false; then : 35284 $as_echo_n "(cached) " >&6 35285 else 35286 case $ac_pt_TOOLCHAIN_PATH_CXX in 35287 [\\/]* | ?:[\\/]*) 35288 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX="$ac_pt_TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 35289 ;; 35290 *) 35291 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35292 for as_dir in $PATH 35293 do 35294 IFS=$as_save_IFS 35295 test -z "$as_dir" && as_dir=. 35296 for ac_exec_ext in '' $ac_executable_extensions; do 35297 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35298 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 35299 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35300 break 2 35301 fi 35302 done 35303 done 35304 IFS=$as_save_IFS 35305 35306 ;; 35307 esac 35308 fi 35309 ac_pt_TOOLCHAIN_PATH_CXX=$ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX 35310 if test -n "$ac_pt_TOOLCHAIN_PATH_CXX"; then 35311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_TOOLCHAIN_PATH_CXX" >&5 35312 $as_echo "$ac_pt_TOOLCHAIN_PATH_CXX" >&6; } 35313 else 35314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35315 $as_echo "no" >&6; } 35316 fi 35317 35318 if test "x$ac_pt_TOOLCHAIN_PATH_CXX" = x; then 35319 TOOLCHAIN_PATH_CXX="" 35320 else 35321 case $cross_compiling:$ac_tool_warned in 35322 yes:) 35323 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 35324 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 35325 ac_tool_warned=yes ;; 35326 esac 35327 TOOLCHAIN_PATH_CXX=$ac_pt_TOOLCHAIN_PATH_CXX 35328 fi 35329 else 35330 TOOLCHAIN_PATH_CXX="$ac_cv_path_TOOLCHAIN_PATH_CXX" 35331 fi 35332 35333 CXX=$TOOLCHAIN_PATH_CXX 35334 PATH="$PATH_save" 35335 fi 35336 35337 # AC_PATH_TOOL can't be run multiple times with the same variable, 35338 # so create a new name for this run. 35339 if test "x$CXX" = x; then 35340 if test -n "$ac_tool_prefix"; then 35341 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 35342 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 35343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35344 $as_echo_n "checking for $ac_word... " >&6; } 35345 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 35346 $as_echo_n "(cached) " >&6 35347 else 35348 case $POTENTIAL_CXX in 35349 [\\/]* | ?:[\\/]*) 35350 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 35351 ;; 35352 *) 35353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35354 for as_dir in $PATH 35355 do 35356 IFS=$as_save_IFS 35357 test -z "$as_dir" && as_dir=. 35358 for ac_exec_ext in '' $ac_executable_extensions; do 35359 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35360 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 35361 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35362 break 2 35363 fi 35364 done 35365 done 35366 IFS=$as_save_IFS 35367 35368 ;; 35369 esac 35370 fi 35371 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 35372 if test -n "$POTENTIAL_CXX"; then 35373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 35374 $as_echo "$POTENTIAL_CXX" >&6; } 35375 else 35376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35377 $as_echo "no" >&6; } 35378 fi 35379 35380 35381 fi 35382 if test -z "$ac_cv_path_POTENTIAL_CXX"; then 35383 ac_pt_POTENTIAL_CXX=$POTENTIAL_CXX 35384 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 35385 set dummy $SEARCH_LIST; ac_word=$2 35386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35387 $as_echo_n "checking for $ac_word... " >&6; } 35388 if ${ac_cv_path_ac_pt_POTENTIAL_CXX+:} false; then : 35389 $as_echo_n "(cached) " >&6 35390 else 35391 case $ac_pt_POTENTIAL_CXX in 35392 [\\/]* | ?:[\\/]*) 35393 ac_cv_path_ac_pt_POTENTIAL_CXX="$ac_pt_POTENTIAL_CXX" # Let the user override the test with a path. 35394 ;; 35395 *) 35396 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35397 for as_dir in $PATH 35398 do 35399 IFS=$as_save_IFS 35400 test -z "$as_dir" && as_dir=. 35401 for ac_exec_ext in '' $ac_executable_extensions; do 35402 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35403 ac_cv_path_ac_pt_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 35404 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35405 break 2 35406 fi 35407 done 35408 done 35409 IFS=$as_save_IFS 35410 35411 ;; 35412 esac 35413 fi 35414 ac_pt_POTENTIAL_CXX=$ac_cv_path_ac_pt_POTENTIAL_CXX 35415 if test -n "$ac_pt_POTENTIAL_CXX"; then 35416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_POTENTIAL_CXX" >&5 35417 $as_echo "$ac_pt_POTENTIAL_CXX" >&6; } 35418 else 35419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35420 $as_echo "no" >&6; } 35421 fi 35422 35423 if test "x$ac_pt_POTENTIAL_CXX" = x; then 35424 POTENTIAL_CXX="" 35425 else 35426 case $cross_compiling:$ac_tool_warned in 35427 yes:) 35428 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 35429 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 35430 ac_tool_warned=yes ;; 35431 esac 35432 POTENTIAL_CXX=$ac_pt_POTENTIAL_CXX 35433 fi 35434 else 35435 POTENTIAL_CXX="$ac_cv_path_POTENTIAL_CXX" 35436 fi 35437 35438 CXX=$POTENTIAL_CXX 35439 fi 35440 35441 if test "x$CXX" = x; then 35442 35443 # Print a helpful message on how to acquire the necessary build dependency. 35444 # devkit is the help tag: freetype, cups, alsa etc 35445 MISSING_DEPENDENCY=devkit 35446 35447 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35448 cygwin_help $MISSING_DEPENDENCY 35449 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35450 msys_help $MISSING_DEPENDENCY 35451 else 35452 PKGHANDLER_COMMAND= 35453 35454 case $PKGHANDLER in 35455 apt-get) 35456 apt_help $MISSING_DEPENDENCY ;; 35457 yum) 35458 yum_help $MISSING_DEPENDENCY ;; 35459 brew) 35460 brew_help $MISSING_DEPENDENCY ;; 35461 port) 35462 port_help $MISSING_DEPENDENCY ;; 35463 pkgutil) 35464 pkgutil_help $MISSING_DEPENDENCY ;; 35465 pkgadd) 35466 pkgadd_help $MISSING_DEPENDENCY ;; 35467 esac 35468 35469 if test "x$PKGHANDLER_COMMAND" != x; then 35470 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 35471 fi 35472 fi 35473 35474 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 35475 fi 35476 fi 35477 35478 # Now we have a compiler binary in CXX. Make sure it's okay. 35479 35480 # Only process if variable expands to non-empty 35481 35482 if test "x$CXX" != x; then 35483 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35484 35485 # First separate the path from the arguments. This will split at the first 35486 # space. 35487 complete="$CXX" 35488 path="${complete%% *}" 35489 tmp="$complete EOL" 35490 arguments="${tmp#* }" 35491 35492 # Input might be given as Windows format, start by converting to 35493 # unix format. 35494 new_path=`$CYGPATH -u "$path"` 35495 35496 # Now try to locate executable using which 35497 new_path=`$WHICH "$new_path" 2> /dev/null` 35498 # bat and cmd files are not always considered executable in cygwin causing which 35499 # to not find them 35500 if test "x$new_path" = x \ 35501 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35502 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35503 new_path=`$CYGPATH -u "$path"` 35504 fi 35505 if test "x$new_path" = x; then 35506 # Oops. Which didn't find the executable. 35507 # The splitting of arguments from the executable at a space might have been incorrect, 35508 # since paths with space are more likely in Windows. Give it another try with the whole 35509 # argument. 35510 path="$complete" 35511 arguments="EOL" 35512 new_path=`$CYGPATH -u "$path"` 35513 new_path=`$WHICH "$new_path" 2> /dev/null` 35514 # bat and cmd files are not always considered executable in cygwin causing which 35515 # to not find them 35516 if test "x$new_path" = x \ 35517 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35518 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35519 new_path=`$CYGPATH -u "$path"` 35520 fi 35521 if test "x$new_path" = x; then 35522 # It's still not found. Now this is an unrecoverable error. 35523 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35524 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35525 has_space=`$ECHO "$complete" | $GREP " "` 35526 if test "x$has_space" != x; then 35527 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35528 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35529 fi 35530 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35531 fi 35532 fi 35533 35534 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35535 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35536 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35537 # "foo.exe" is OK but "foo" is an error. 35538 # 35539 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35540 # It is also a way to make sure we got the proper file name for the real test later on. 35541 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35542 if test "x$test_shortpath" = x; then 35543 # Short path failed, file does not exist as specified. 35544 # Try adding .exe or .cmd 35545 if test -f "${new_path}.exe"; then 35546 input_to_shortpath="${new_path}.exe" 35547 elif test -f "${new_path}.cmd"; then 35548 input_to_shortpath="${new_path}.cmd" 35549 else 35550 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5 35551 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;} 35552 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35553 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35554 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35555 fi 35556 else 35557 input_to_shortpath="$new_path" 35558 fi 35559 35560 # Call helper function which possibly converts this using DOS-style short mode. 35561 # If so, the updated path is stored in $new_path. 35562 new_path="$input_to_shortpath" 35563 35564 input_path="$input_to_shortpath" 35565 # Check if we need to convert this using DOS-style short mode. If the path 35566 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35567 # take no chances and rewrite it. 35568 # Note: m4 eats our [], so we need to use [ and ] instead. 35569 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 35570 if test "x$has_forbidden_chars" != x; then 35571 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35572 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 35573 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 35574 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 35575 # Going to short mode and back again did indeed matter. Since short mode is 35576 # case insensitive, let's make it lowercase to improve readability. 35577 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35578 # Now convert it back to Unix-style (cygpath) 35579 input_path=`$CYGPATH -u "$shortmode_path"` 35580 new_path="$input_path" 35581 fi 35582 fi 35583 35584 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 35585 if test "x$test_cygdrive_prefix" = x; then 35586 # As a simple fix, exclude /usr/bin since it's not a real path. 35587 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 35588 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 35589 # a path prefixed by /cygdrive for fixpath to work. 35590 new_path="$CYGWIN_ROOT_PATH$input_path" 35591 fi 35592 fi 35593 35594 # remove trailing .exe if any 35595 new_path="${new_path/%.exe/}" 35596 35597 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35598 35599 # First separate the path from the arguments. This will split at the first 35600 # space. 35601 complete="$CXX" 35602 path="${complete%% *}" 35603 tmp="$complete EOL" 35604 arguments="${tmp#* }" 35605 35606 # Input might be given as Windows format, start by converting to 35607 # unix format. 35608 new_path="$path" 35609 35610 windows_path="$new_path" 35611 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35612 unix_path=`$CYGPATH -u "$windows_path"` 35613 new_path="$unix_path" 35614 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35615 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35616 new_path="$unix_path" 35617 fi 35618 35619 35620 # Now try to locate executable using which 35621 new_path=`$WHICH "$new_path" 2> /dev/null` 35622 35623 if test "x$new_path" = x; then 35624 # Oops. Which didn't find the executable. 35625 # The splitting of arguments from the executable at a space might have been incorrect, 35626 # since paths with space are more likely in Windows. Give it another try with the whole 35627 # argument. 35628 path="$complete" 35629 arguments="EOL" 35630 new_path="$path" 35631 35632 windows_path="$new_path" 35633 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35634 unix_path=`$CYGPATH -u "$windows_path"` 35635 new_path="$unix_path" 35636 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35637 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35638 new_path="$unix_path" 35639 fi 35640 35641 35642 new_path=`$WHICH "$new_path" 2> /dev/null` 35643 # bat and cmd files are not always considered executable in MSYS causing which 35644 # to not find them 35645 if test "x$new_path" = x \ 35646 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35647 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35648 new_path="$path" 35649 35650 windows_path="$new_path" 35651 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35652 unix_path=`$CYGPATH -u "$windows_path"` 35653 new_path="$unix_path" 35654 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35655 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35656 new_path="$unix_path" 35657 fi 35658 35659 fi 35660 35661 if test "x$new_path" = x; then 35662 # It's still not found. Now this is an unrecoverable error. 35663 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35664 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35665 has_space=`$ECHO "$complete" | $GREP " "` 35666 if test "x$has_space" != x; then 35667 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35668 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35669 fi 35670 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35671 fi 35672 fi 35673 35674 # Now new_path has a complete unix path to the binary 35675 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 35676 # Keep paths in /bin as-is, but remove trailing .exe if any 35677 new_path="${new_path/%.exe/}" 35678 # Do not save /bin paths to all_fixpath_prefixes! 35679 else 35680 # Not in mixed or Windows style, start by that. 35681 new_path=`cmd //c echo $new_path` 35682 35683 input_path="$new_path" 35684 # Check if we need to convert this using DOS-style short mode. If the path 35685 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35686 # take no chances and rewrite it. 35687 # Note: m4 eats our [], so we need to use [ and ] instead. 35688 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 35689 if test "x$has_forbidden_chars" != x; then 35690 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35691 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35692 fi 35693 35694 # Output is in $new_path 35695 35696 windows_path="$new_path" 35697 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35698 unix_path=`$CYGPATH -u "$windows_path"` 35699 new_path="$unix_path" 35700 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35701 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35702 new_path="$unix_path" 35703 fi 35704 35705 # remove trailing .exe if any 35706 new_path="${new_path/%.exe/}" 35707 35708 # Save the first 10 bytes of this path to the storage, so fixpath can work. 35709 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 35710 fi 35711 35712 else 35713 # We're on a unix platform. Hooray! :) 35714 # First separate the path from the arguments. This will split at the first 35715 # space. 35716 complete="$CXX" 35717 path="${complete%% *}" 35718 tmp="$complete EOL" 35719 arguments="${tmp#* }" 35720 35721 # Cannot rely on the command "which" here since it doesn't always work. 35722 is_absolute_path=`$ECHO "$path" | $GREP ^/` 35723 if test -z "$is_absolute_path"; then 35724 # Path to executable is not absolute. Find it. 35725 IFS_save="$IFS" 35726 IFS=: 35727 for p in $PATH; do 35728 if test -f "$p/$path" && test -x "$p/$path"; then 35729 new_path="$p/$path" 35730 break 35731 fi 35732 done 35733 IFS="$IFS_save" 35734 else 35735 # This is an absolute path, we can use it without further modifications. 35736 new_path="$path" 35737 fi 35738 35739 if test "x$new_path" = x; then 35740 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35741 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35742 has_space=`$ECHO "$complete" | $GREP " "` 35743 if test "x$has_space" != x; then 35744 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 35745 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 35746 fi 35747 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35748 fi 35749 fi 35750 35751 # Now join together the path and the arguments once again 35752 if test "x$arguments" != xEOL; then 35753 new_complete="$new_path ${arguments% *}" 35754 else 35755 new_complete="$new_path" 35756 fi 35757 35758 if test "x$complete" != "x$new_complete"; then 35759 CXX="$new_complete" 35760 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5 35761 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;} 35762 fi 35763 fi 35764 35765 TEST_COMPILER="$CXX" 35766 35767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5 35768 $as_echo_n "checking resolved symbolic links for CXX... " >&6; } 35769 SYMLINK_ORIGINAL="$TEST_COMPILER" 35770 35771 if test "x$OPENJDK_BUILD_OS" != xwindows; then 35772 # Follow a chain of symbolic links. Use readlink 35773 # where it exists, else fall back to horribly 35774 # complicated shell code. 35775 if test "x$READLINK_TESTED" != yes; then 35776 # On MacOSX there is a readlink tool with a different 35777 # purpose than the GNU readlink tool. Check the found readlink. 35778 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 35779 if test "x$ISGNU" = x; then 35780 # A readlink that we do not know how to use. 35781 # Are there other non-GNU readlinks out there? 35782 READLINK_TESTED=yes 35783 READLINK= 35784 fi 35785 fi 35786 35787 if test "x$READLINK" != x; then 35788 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 35789 else 35790 # Save the current directory for restoring afterwards 35791 STARTDIR=$PWD 35792 COUNTER=0 35793 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 35794 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 35795 cd $sym_link_dir 35796 # Use -P flag to resolve symlinks in directories. 35797 cd `$THEPWDCMD -P` 35798 sym_link_dir=`$THEPWDCMD -P` 35799 # Resolve file symlinks 35800 while test $COUNTER -lt 20; do 35801 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 35802 if test "x$ISLINK" == x; then 35803 # This is not a symbolic link! We are done! 35804 break 35805 fi 35806 # Again resolve directory symlinks since the target of the just found 35807 # link could be in a different directory 35808 cd `$DIRNAME $ISLINK` 35809 sym_link_dir=`$THEPWDCMD -P` 35810 sym_link_file=`$BASENAME $ISLINK` 35811 let COUNTER=COUNTER+1 35812 done 35813 cd $STARTDIR 35814 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 35815 fi 35816 fi 35817 35818 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 35819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 35820 $as_echo "no symlink" >&6; } 35821 else 35822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 35823 $as_echo "$SYMLINK_ORIGINAL" >&6; } 35824 35825 # We can't handle ccache by gcc wrappers, since we need to know if we're 35826 # using ccache. Instead ccache usage must be controlled by a configure option. 35827 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 35828 if test "x$COMPILER_BASENAME" = "xccache"; then 35829 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 35830 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 35831 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 35832 fi 35833 fi 35834 35835 35836 COMPILER=$CXX 35837 COMPILER_NAME=$COMPILER_NAME 35838 35839 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 35840 # cc -V output typically looks like 35841 # cc: Sun C 5.12 Linux_i386 2011/11/16 35842 # or 35843 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 35844 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 35845 # Check that this is likely to be the Solaris Studio cc. 35846 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 35847 if test $? -ne 0; then 35848 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35849 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 35850 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35851 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35852 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35853 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 35854 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 35855 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35856 fi 35857 # Remove usage instructions (if present), and 35858 # collapse compiler output into a single line 35859 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35860 $SED -e 's/ *[Uu]sage:.*//'` 35861 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35862 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 35863 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 35864 # xlc -qversion output typically looks like 35865 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 35866 # Version: 11.01.0000.0015 35867 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 35868 # Check that this is likely to be the IBM XL C compiler. 35869 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 35870 if test $? -ne 0; then 35871 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35872 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 35873 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35874 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35875 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35876 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 35877 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 35878 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35879 fi 35880 # Collapse compiler output into a single line 35881 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35882 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35883 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 35884 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 35885 # There is no specific version flag, but all output starts with a version string. 35886 # First line typically looks something like: 35887 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 35888 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 35889 # Check that this is likely to be Microsoft CL.EXE. 35890 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 35891 if test $? -ne 0; then 35892 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 35893 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35894 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35895 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35896 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35897 fi 35898 # Collapse compiler output into a single line 35899 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35900 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35901 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 35902 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 35903 # gcc --version output typically looks like 35904 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 35905 # Copyright (C) 2013 Free Software Foundation, Inc. 35906 # This is free software; see the source for copying conditions. There is NO 35907 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 35908 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35909 # Check that this is likely to be GCC. 35910 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 35911 if test $? -ne 0; then 35912 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 35913 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35914 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 35915 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 35916 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35917 fi 35918 # Remove Copyright and legalese from version string, and 35919 # collapse into a single line 35920 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35921 $SED -e 's/ *Copyright .*//'` 35922 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35923 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 35924 elif test "x$TOOLCHAIN_TYPE" = xclang; then 35925 # clang --version output typically looks like 35926 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 35927 # clang version 3.3 (tags/RELEASE_33/final) 35928 # or 35929 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 35930 # Target: x86_64-pc-linux-gnu 35931 # Thread model: posix 35932 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35933 # Check that this is likely to be clang 35934 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 35935 if test $? -ne 0; then 35936 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 35937 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35938 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35939 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35940 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35941 fi 35942 # Collapse compiler output into a single line 35943 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35944 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35945 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 35946 else 35947 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 35948 fi 35949 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 35950 CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 35951 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 35952 CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 35953 35954 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 35955 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 35956 35957 35958 # Now that we have resolved CXX ourself, let autoconf have its go at it 35959 ac_ext=cpp 35960 ac_cpp='$CXXCPP $CPPFLAGS' 35961 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35962 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35963 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35964 if test -z "$CXX"; then 35965 if test -n "$CCC"; then 35966 CXX=$CCC 35967 else 35968 if test -n "$ac_tool_prefix"; then 35969 for ac_prog in $CXX 35970 do 35971 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 35972 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 35973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35974 $as_echo_n "checking for $ac_word... " >&6; } 35975 if ${ac_cv_prog_CXX+:} false; then : 35976 $as_echo_n "(cached) " >&6 35977 else 35978 if test -n "$CXX"; then 35979 ac_cv_prog_CXX="$CXX" # Let the user override the test. 35980 else 35981 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35982 for as_dir in $PATH 35983 do 35984 IFS=$as_save_IFS 35985 test -z "$as_dir" && as_dir=. 35986 for ac_exec_ext in '' $ac_executable_extensions; do 35987 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35988 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" 35989 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35990 break 2 35991 fi 35992 done 35993 done 35994 IFS=$as_save_IFS 35995 35996 fi 35997 fi 35998 CXX=$ac_cv_prog_CXX 35999 if test -n "$CXX"; then 36000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 36001 $as_echo "$CXX" >&6; } 36002 else 36003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36004 $as_echo "no" >&6; } 36005 fi 36006 36007 36008 test -n "$CXX" && break 36009 done 36010 fi 36011 if test -z "$CXX"; then 36012 ac_ct_CXX=$CXX 36013 for ac_prog in $CXX 36014 do 36015 # Extract the first word of "$ac_prog", so it can be a program name with args. 36016 set dummy $ac_prog; ac_word=$2 36017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36018 $as_echo_n "checking for $ac_word... " >&6; } 36019 if ${ac_cv_prog_ac_ct_CXX+:} false; then : 36020 $as_echo_n "(cached) " >&6 36021 else 36022 if test -n "$ac_ct_CXX"; then 36023 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. 36024 else 36025 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36026 for as_dir in $PATH 36027 do 36028 IFS=$as_save_IFS 36029 test -z "$as_dir" && as_dir=. 36030 for ac_exec_ext in '' $ac_executable_extensions; do 36031 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36032 ac_cv_prog_ac_ct_CXX="$ac_prog" 36033 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36034 break 2 36035 fi 36036 done 36037 done 36038 IFS=$as_save_IFS 36039 36040 fi 36041 fi 36042 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX 36043 if test -n "$ac_ct_CXX"; then 36044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 36045 $as_echo "$ac_ct_CXX" >&6; } 36046 else 36047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36048 $as_echo "no" >&6; } 36049 fi 36050 36051 36052 test -n "$ac_ct_CXX" && break 36053 done 36054 36055 if test "x$ac_ct_CXX" = x; then 36056 CXX="g++" 36057 else 36058 case $cross_compiling:$ac_tool_warned in 36059 yes:) 36060 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 36061 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 36062 ac_tool_warned=yes ;; 36063 esac 36064 CXX=$ac_ct_CXX 36065 fi 36066 fi 36067 36068 fi 36069 fi 36070 # Provide some information about the compiler. 36071 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 36072 set X $ac_compile 36073 ac_compiler=$2 36074 for ac_option in --version -v -V -qversion; do 36075 { { ac_try="$ac_compiler $ac_option >&5" 36076 case "(($ac_try" in 36077 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 36078 *) ac_try_echo=$ac_try;; 36079 esac 36080 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 36081 $as_echo "$ac_try_echo"; } >&5 36082 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 36083 ac_status=$? 36084 if test -s conftest.err; then 36085 sed '10a\ 36086 ... rest of stderr output deleted ... 36087 10q' conftest.err >conftest.er1 36088 cat conftest.er1 >&5 36089 fi 36090 rm -f conftest.er1 conftest.err 36091 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 36092 test $ac_status = 0; } 36093 done 36094 36095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 36096 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } 36097 if ${ac_cv_cxx_compiler_gnu+:} false; then : 36098 $as_echo_n "(cached) " >&6 36099 else 36100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36101 /* end confdefs.h. */ 36102 36103 int 36104 main () 36105 { 36106 #ifndef __GNUC__ 36107 choke me 36108 #endif 36109 36110 ; 36111 return 0; 36112 } 36113 _ACEOF 36114 if ac_fn_cxx_try_compile "$LINENO"; then : 36115 ac_compiler_gnu=yes 36116 else 36117 ac_compiler_gnu=no 36118 fi 36119 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36120 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu 36121 36122 fi 36123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 36124 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } 36125 if test $ac_compiler_gnu = yes; then 36126 GXX=yes 36127 else 36128 GXX= 36129 fi 36130 ac_test_CXXFLAGS=${CXXFLAGS+set} 36131 ac_save_CXXFLAGS=$CXXFLAGS 36132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 36133 $as_echo_n "checking whether $CXX accepts -g... " >&6; } 36134 if ${ac_cv_prog_cxx_g+:} false; then : 36135 $as_echo_n "(cached) " >&6 36136 else 36137 ac_save_cxx_werror_flag=$ac_cxx_werror_flag 36138 ac_cxx_werror_flag=yes 36139 ac_cv_prog_cxx_g=no 36140 CXXFLAGS="-g" 36141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36142 /* end confdefs.h. */ 36143 36144 int 36145 main () 36146 { 36147 36148 ; 36149 return 0; 36150 } 36151 _ACEOF 36152 if ac_fn_cxx_try_compile "$LINENO"; then : 36153 ac_cv_prog_cxx_g=yes 36154 else 36155 CXXFLAGS="" 36156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36157 /* end confdefs.h. */ 36158 36159 int 36160 main () 36161 { 36162 36163 ; 36164 return 0; 36165 } 36166 _ACEOF 36167 if ac_fn_cxx_try_compile "$LINENO"; then : 36168 36169 else 36170 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 36171 CXXFLAGS="-g" 36172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36173 /* end confdefs.h. */ 36174 36175 int 36176 main () 36177 { 36178 36179 ; 36180 return 0; 36181 } 36182 _ACEOF 36183 if ac_fn_cxx_try_compile "$LINENO"; then : 36184 ac_cv_prog_cxx_g=yes 36185 fi 36186 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36187 fi 36188 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36189 fi 36190 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36191 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 36192 fi 36193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 36194 $as_echo "$ac_cv_prog_cxx_g" >&6; } 36195 if test "$ac_test_CXXFLAGS" = set; then 36196 CXXFLAGS=$ac_save_CXXFLAGS 36197 elif test $ac_cv_prog_cxx_g = yes; then 36198 if test "$GXX" = yes; then 36199 CXXFLAGS="-g -O2" 36200 else 36201 CXXFLAGS="-g" 36202 fi 36203 else 36204 if test "$GXX" = yes; then 36205 CXXFLAGS="-O2" 36206 else 36207 CXXFLAGS= 36208 fi 36209 fi 36210 ac_ext=cpp 36211 ac_cpp='$CXXCPP $CPPFLAGS' 36212 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36213 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36214 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36215 36216 36217 # This is the compiler version number on the form X.Y[.Z] 36218 36219 36220 36221 36222 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 36223 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 36224 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 36225 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 36226 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 36227 fi 36228 36229 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 36230 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 36231 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&5 36232 $as_echo "$as_me: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 36233 fi 36234 36235 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 36236 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&5 36237 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 36238 fi 36239 36240 COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$CC_VERSION_NUMBER"` 36241 36242 36243 if test "x$TOOLCHAIN_MINIMUM_VERSION" != x; then 36244 36245 36246 36247 36248 36249 36250 36251 36252 36253 36254 36255 36256 36257 36258 36259 36260 36261 36262 36263 36264 36265 36266 36267 36268 36269 36270 36271 36272 36273 36274 36275 36276 36277 36278 36279 36280 36281 36282 36283 36284 36285 36286 36287 36288 36289 36290 36291 36292 36293 # Execute function body 36294 36295 # Need to assign to a variable since m4 is blocked from modifying parts in []. 36296 REFERENCE_VERSION=$TOOLCHAIN_MINIMUM_VERSION 36297 36298 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 36299 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 36300 fi 36301 36302 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 36303 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only parts < 99999 is supported" "$LINENO" 5 36304 fi 36305 36306 # Version comparison method inspired by http://stackoverflow.com/a/24067243 36307 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 36308 36309 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 36310 : 36311 36312 else 36313 : 36314 36315 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: You are using $TOOLCHAIN_TYPE older than $TOOLCHAIN_MINIMUM_VERSION. This is not a supported configuration." >&5 36316 $as_echo "$as_me: WARNING: You are using $TOOLCHAIN_TYPE older than $TOOLCHAIN_MINIMUM_VERSION. This is not a supported configuration." >&2;} 36317 36318 36319 fi 36320 36321 36322 36323 36324 36325 36326 36327 36328 36329 36330 36331 36332 36333 36334 fi 36335 36336 # 36337 # Setup the preprocessor (CPP and CXXCPP) 36338 # 36339 ac_ext=c 36340 ac_cpp='$CPP $CPPFLAGS' 36341 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36342 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36343 ac_compiler_gnu=$ac_cv_c_compiler_gnu 36344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 36345 $as_echo_n "checking how to run the C preprocessor... " >&6; } 36346 # On Suns, sometimes $CPP names a directory. 36347 if test -n "$CPP" && test -d "$CPP"; then 36348 CPP= 36349 fi 36350 if test -z "$CPP"; then 36351 if ${ac_cv_prog_CPP+:} false; then : 36352 $as_echo_n "(cached) " >&6 36353 else 36354 # Double quotes because CPP needs to be expanded 36355 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 36356 do 36357 ac_preproc_ok=false 36358 for ac_c_preproc_warn_flag in '' yes 36359 do 36360 # Use a header file that comes with gcc, so configuring glibc 36361 # with a fresh cross-compiler works. 36362 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36363 # <limits.h> exists even on freestanding compilers. 36364 # On the NeXT, cc -E runs the code through the compiler's parser, 36365 # not just through cpp. "Syntax error" is here to catch this case. 36366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36367 /* end confdefs.h. */ 36368 #ifdef __STDC__ 36369 # include <limits.h> 36370 #else 36371 # include <assert.h> 36372 #endif 36373 Syntax error 36374 _ACEOF 36375 if ac_fn_c_try_cpp "$LINENO"; then : 36376 36377 else 36378 # Broken: fails on valid input. 36379 continue 36380 fi 36381 rm -f conftest.err conftest.i conftest.$ac_ext 36382 36383 # OK, works on sane cases. Now check whether nonexistent headers 36384 # can be detected and how. 36385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36386 /* end confdefs.h. */ 36387 #include <ac_nonexistent.h> 36388 _ACEOF 36389 if ac_fn_c_try_cpp "$LINENO"; then : 36390 # Broken: success on invalid input. 36391 continue 36392 else 36393 # Passes both tests. 36394 ac_preproc_ok=: 36395 break 36396 fi 36397 rm -f conftest.err conftest.i conftest.$ac_ext 36398 36399 done 36400 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36401 rm -f conftest.i conftest.err conftest.$ac_ext 36402 if $ac_preproc_ok; then : 36403 break 36404 fi 36405 36406 done 36407 ac_cv_prog_CPP=$CPP 36408 36409 fi 36410 CPP=$ac_cv_prog_CPP 36411 else 36412 ac_cv_prog_CPP=$CPP 36413 fi 36414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 36415 $as_echo "$CPP" >&6; } 36416 ac_preproc_ok=false 36417 for ac_c_preproc_warn_flag in '' yes 36418 do 36419 # Use a header file that comes with gcc, so configuring glibc 36420 # with a fresh cross-compiler works. 36421 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36422 # <limits.h> exists even on freestanding compilers. 36423 # On the NeXT, cc -E runs the code through the compiler's parser, 36424 # not just through cpp. "Syntax error" is here to catch this case. 36425 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36426 /* end confdefs.h. */ 36427 #ifdef __STDC__ 36428 # include <limits.h> 36429 #else 36430 # include <assert.h> 36431 #endif 36432 Syntax error 36433 _ACEOF 36434 if ac_fn_c_try_cpp "$LINENO"; then : 36435 36436 else 36437 # Broken: fails on valid input. 36438 continue 36439 fi 36440 rm -f conftest.err conftest.i conftest.$ac_ext 36441 36442 # OK, works on sane cases. Now check whether nonexistent headers 36443 # can be detected and how. 36444 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36445 /* end confdefs.h. */ 36446 #include <ac_nonexistent.h> 36447 _ACEOF 36448 if ac_fn_c_try_cpp "$LINENO"; then : 36449 # Broken: success on invalid input. 36450 continue 36451 else 36452 # Passes both tests. 36453 ac_preproc_ok=: 36454 break 36455 fi 36456 rm -f conftest.err conftest.i conftest.$ac_ext 36457 36458 done 36459 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36460 rm -f conftest.i conftest.err conftest.$ac_ext 36461 if $ac_preproc_ok; then : 36462 36463 else 36464 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 36465 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 36466 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 36467 See \`config.log' for more details" "$LINENO" 5; } 36468 fi 36469 36470 ac_ext=cpp 36471 ac_cpp='$CXXCPP $CPPFLAGS' 36472 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36473 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36474 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36475 36476 36477 # Only process if variable expands to non-empty 36478 36479 if test "x$CPP" != x; then 36480 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36481 36482 # First separate the path from the arguments. This will split at the first 36483 # space. 36484 complete="$CPP" 36485 path="${complete%% *}" 36486 tmp="$complete EOL" 36487 arguments="${tmp#* }" 36488 36489 # Input might be given as Windows format, start by converting to 36490 # unix format. 36491 new_path=`$CYGPATH -u "$path"` 36492 36493 # Now try to locate executable using which 36494 new_path=`$WHICH "$new_path" 2> /dev/null` 36495 # bat and cmd files are not always considered executable in cygwin causing which 36496 # to not find them 36497 if test "x$new_path" = x \ 36498 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36499 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36500 new_path=`$CYGPATH -u "$path"` 36501 fi 36502 if test "x$new_path" = x; then 36503 # Oops. Which didn't find the executable. 36504 # The splitting of arguments from the executable at a space might have been incorrect, 36505 # since paths with space are more likely in Windows. Give it another try with the whole 36506 # argument. 36507 path="$complete" 36508 arguments="EOL" 36509 new_path=`$CYGPATH -u "$path"` 36510 new_path=`$WHICH "$new_path" 2> /dev/null` 36511 # bat and cmd files are not always considered executable in cygwin causing which 36512 # to not find them 36513 if test "x$new_path" = x \ 36514 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36515 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36516 new_path=`$CYGPATH -u "$path"` 36517 fi 36518 if test "x$new_path" = x; then 36519 # It's still not found. Now this is an unrecoverable error. 36520 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36521 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36522 has_space=`$ECHO "$complete" | $GREP " "` 36523 if test "x$has_space" != x; then 36524 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36525 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36526 fi 36527 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36528 fi 36529 fi 36530 36531 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36532 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36533 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36534 # "foo.exe" is OK but "foo" is an error. 36535 # 36536 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36537 # It is also a way to make sure we got the proper file name for the real test later on. 36538 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36539 if test "x$test_shortpath" = x; then 36540 # Short path failed, file does not exist as specified. 36541 # Try adding .exe or .cmd 36542 if test -f "${new_path}.exe"; then 36543 input_to_shortpath="${new_path}.exe" 36544 elif test -f "${new_path}.cmd"; then 36545 input_to_shortpath="${new_path}.cmd" 36546 else 36547 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5 36548 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;} 36549 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36550 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36551 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36552 fi 36553 else 36554 input_to_shortpath="$new_path" 36555 fi 36556 36557 # Call helper function which possibly converts this using DOS-style short mode. 36558 # If so, the updated path is stored in $new_path. 36559 new_path="$input_to_shortpath" 36560 36561 input_path="$input_to_shortpath" 36562 # Check if we need to convert this using DOS-style short mode. If the path 36563 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36564 # take no chances and rewrite it. 36565 # Note: m4 eats our [], so we need to use [ and ] instead. 36566 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36567 if test "x$has_forbidden_chars" != x; then 36568 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36569 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36570 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36571 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36572 # Going to short mode and back again did indeed matter. Since short mode is 36573 # case insensitive, let's make it lowercase to improve readability. 36574 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36575 # Now convert it back to Unix-style (cygpath) 36576 input_path=`$CYGPATH -u "$shortmode_path"` 36577 new_path="$input_path" 36578 fi 36579 fi 36580 36581 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36582 if test "x$test_cygdrive_prefix" = x; then 36583 # As a simple fix, exclude /usr/bin since it's not a real path. 36584 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36585 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36586 # a path prefixed by /cygdrive for fixpath to work. 36587 new_path="$CYGWIN_ROOT_PATH$input_path" 36588 fi 36589 fi 36590 36591 # remove trailing .exe if any 36592 new_path="${new_path/%.exe/}" 36593 36594 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36595 36596 # First separate the path from the arguments. This will split at the first 36597 # space. 36598 complete="$CPP" 36599 path="${complete%% *}" 36600 tmp="$complete EOL" 36601 arguments="${tmp#* }" 36602 36603 # Input might be given as Windows format, start by converting to 36604 # unix format. 36605 new_path="$path" 36606 36607 windows_path="$new_path" 36608 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36609 unix_path=`$CYGPATH -u "$windows_path"` 36610 new_path="$unix_path" 36611 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36612 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36613 new_path="$unix_path" 36614 fi 36615 36616 36617 # Now try to locate executable using which 36618 new_path=`$WHICH "$new_path" 2> /dev/null` 36619 36620 if test "x$new_path" = x; then 36621 # Oops. Which didn't find the executable. 36622 # The splitting of arguments from the executable at a space might have been incorrect, 36623 # since paths with space are more likely in Windows. Give it another try with the whole 36624 # argument. 36625 path="$complete" 36626 arguments="EOL" 36627 new_path="$path" 36628 36629 windows_path="$new_path" 36630 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36631 unix_path=`$CYGPATH -u "$windows_path"` 36632 new_path="$unix_path" 36633 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36634 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36635 new_path="$unix_path" 36636 fi 36637 36638 36639 new_path=`$WHICH "$new_path" 2> /dev/null` 36640 # bat and cmd files are not always considered executable in MSYS causing which 36641 # to not find them 36642 if test "x$new_path" = x \ 36643 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36644 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36645 new_path="$path" 36646 36647 windows_path="$new_path" 36648 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36649 unix_path=`$CYGPATH -u "$windows_path"` 36650 new_path="$unix_path" 36651 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36652 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36653 new_path="$unix_path" 36654 fi 36655 36656 fi 36657 36658 if test "x$new_path" = x; then 36659 # It's still not found. Now this is an unrecoverable error. 36660 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36661 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36662 has_space=`$ECHO "$complete" | $GREP " "` 36663 if test "x$has_space" != x; then 36664 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36665 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36666 fi 36667 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36668 fi 36669 fi 36670 36671 # Now new_path has a complete unix path to the binary 36672 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36673 # Keep paths in /bin as-is, but remove trailing .exe if any 36674 new_path="${new_path/%.exe/}" 36675 # Do not save /bin paths to all_fixpath_prefixes! 36676 else 36677 # Not in mixed or Windows style, start by that. 36678 new_path=`cmd //c echo $new_path` 36679 36680 input_path="$new_path" 36681 # Check if we need to convert this using DOS-style short mode. If the path 36682 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36683 # take no chances and rewrite it. 36684 # Note: m4 eats our [], so we need to use [ and ] instead. 36685 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36686 if test "x$has_forbidden_chars" != x; then 36687 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36688 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36689 fi 36690 36691 # Output is in $new_path 36692 36693 windows_path="$new_path" 36694 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36695 unix_path=`$CYGPATH -u "$windows_path"` 36696 new_path="$unix_path" 36697 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36698 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36699 new_path="$unix_path" 36700 fi 36701 36702 # remove trailing .exe if any 36703 new_path="${new_path/%.exe/}" 36704 36705 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36706 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36707 fi 36708 36709 else 36710 # We're on a unix platform. Hooray! :) 36711 # First separate the path from the arguments. This will split at the first 36712 # space. 36713 complete="$CPP" 36714 path="${complete%% *}" 36715 tmp="$complete EOL" 36716 arguments="${tmp#* }" 36717 36718 # Cannot rely on the command "which" here since it doesn't always work. 36719 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36720 if test -z "$is_absolute_path"; then 36721 # Path to executable is not absolute. Find it. 36722 IFS_save="$IFS" 36723 IFS=: 36724 for p in $PATH; do 36725 if test -f "$p/$path" && test -x "$p/$path"; then 36726 new_path="$p/$path" 36727 break 36728 fi 36729 done 36730 IFS="$IFS_save" 36731 else 36732 # This is an absolute path, we can use it without further modifications. 36733 new_path="$path" 36734 fi 36735 36736 if test "x$new_path" = x; then 36737 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36738 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36739 has_space=`$ECHO "$complete" | $GREP " "` 36740 if test "x$has_space" != x; then 36741 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36742 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36743 fi 36744 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36745 fi 36746 fi 36747 36748 # Now join together the path and the arguments once again 36749 if test "x$arguments" != xEOL; then 36750 new_complete="$new_path ${arguments% *}" 36751 else 36752 new_complete="$new_path" 36753 fi 36754 36755 if test "x$complete" != "x$new_complete"; then 36756 CPP="$new_complete" 36757 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5 36758 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;} 36759 fi 36760 fi 36761 36762 ac_ext=cpp 36763 ac_cpp='$CXXCPP $CPPFLAGS' 36764 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36765 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36766 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 36768 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } 36769 if test -z "$CXXCPP"; then 36770 if ${ac_cv_prog_CXXCPP+:} false; then : 36771 $as_echo_n "(cached) " >&6 36772 else 36773 # Double quotes because CXXCPP needs to be expanded 36774 for CXXCPP in "$CXX -E" "/lib/cpp" 36775 do 36776 ac_preproc_ok=false 36777 for ac_cxx_preproc_warn_flag in '' yes 36778 do 36779 # Use a header file that comes with gcc, so configuring glibc 36780 # with a fresh cross-compiler works. 36781 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36782 # <limits.h> exists even on freestanding compilers. 36783 # On the NeXT, cc -E runs the code through the compiler's parser, 36784 # not just through cpp. "Syntax error" is here to catch this case. 36785 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36786 /* end confdefs.h. */ 36787 #ifdef __STDC__ 36788 # include <limits.h> 36789 #else 36790 # include <assert.h> 36791 #endif 36792 Syntax error 36793 _ACEOF 36794 if ac_fn_cxx_try_cpp "$LINENO"; then : 36795 36796 else 36797 # Broken: fails on valid input. 36798 continue 36799 fi 36800 rm -f conftest.err conftest.i conftest.$ac_ext 36801 36802 # OK, works on sane cases. Now check whether nonexistent headers 36803 # can be detected and how. 36804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36805 /* end confdefs.h. */ 36806 #include <ac_nonexistent.h> 36807 _ACEOF 36808 if ac_fn_cxx_try_cpp "$LINENO"; then : 36809 # Broken: success on invalid input. 36810 continue 36811 else 36812 # Passes both tests. 36813 ac_preproc_ok=: 36814 break 36815 fi 36816 rm -f conftest.err conftest.i conftest.$ac_ext 36817 36818 done 36819 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36820 rm -f conftest.i conftest.err conftest.$ac_ext 36821 if $ac_preproc_ok; then : 36822 break 36823 fi 36824 36825 done 36826 ac_cv_prog_CXXCPP=$CXXCPP 36827 36828 fi 36829 CXXCPP=$ac_cv_prog_CXXCPP 36830 else 36831 ac_cv_prog_CXXCPP=$CXXCPP 36832 fi 36833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 36834 $as_echo "$CXXCPP" >&6; } 36835 ac_preproc_ok=false 36836 for ac_cxx_preproc_warn_flag in '' yes 36837 do 36838 # Use a header file that comes with gcc, so configuring glibc 36839 # with a fresh cross-compiler works. 36840 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36841 # <limits.h> exists even on freestanding compilers. 36842 # On the NeXT, cc -E runs the code through the compiler's parser, 36843 # not just through cpp. "Syntax error" is here to catch this case. 36844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36845 /* end confdefs.h. */ 36846 #ifdef __STDC__ 36847 # include <limits.h> 36848 #else 36849 # include <assert.h> 36850 #endif 36851 Syntax error 36852 _ACEOF 36853 if ac_fn_cxx_try_cpp "$LINENO"; then : 36854 36855 else 36856 # Broken: fails on valid input. 36857 continue 36858 fi 36859 rm -f conftest.err conftest.i conftest.$ac_ext 36860 36861 # OK, works on sane cases. Now check whether nonexistent headers 36862 # can be detected and how. 36863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36864 /* end confdefs.h. */ 36865 #include <ac_nonexistent.h> 36866 _ACEOF 36867 if ac_fn_cxx_try_cpp "$LINENO"; then : 36868 # Broken: success on invalid input. 36869 continue 36870 else 36871 # Passes both tests. 36872 ac_preproc_ok=: 36873 break 36874 fi 36875 rm -f conftest.err conftest.i conftest.$ac_ext 36876 36877 done 36878 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36879 rm -f conftest.i conftest.err conftest.$ac_ext 36880 if $ac_preproc_ok; then : 36881 36882 else 36883 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 36884 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 36885 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check 36886 See \`config.log' for more details" "$LINENO" 5; } 36887 fi 36888 36889 ac_ext=cpp 36890 ac_cpp='$CXXCPP $CPPFLAGS' 36891 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36892 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36893 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36894 36895 36896 # Only process if variable expands to non-empty 36897 36898 if test "x$CXXCPP" != x; then 36899 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36900 36901 # First separate the path from the arguments. This will split at the first 36902 # space. 36903 complete="$CXXCPP" 36904 path="${complete%% *}" 36905 tmp="$complete EOL" 36906 arguments="${tmp#* }" 36907 36908 # Input might be given as Windows format, start by converting to 36909 # unix format. 36910 new_path=`$CYGPATH -u "$path"` 36911 36912 # Now try to locate executable using which 36913 new_path=`$WHICH "$new_path" 2> /dev/null` 36914 # bat and cmd files are not always considered executable in cygwin causing which 36915 # to not find them 36916 if test "x$new_path" = x \ 36917 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36918 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36919 new_path=`$CYGPATH -u "$path"` 36920 fi 36921 if test "x$new_path" = x; then 36922 # Oops. Which didn't find the executable. 36923 # The splitting of arguments from the executable at a space might have been incorrect, 36924 # since paths with space are more likely in Windows. Give it another try with the whole 36925 # argument. 36926 path="$complete" 36927 arguments="EOL" 36928 new_path=`$CYGPATH -u "$path"` 36929 new_path=`$WHICH "$new_path" 2> /dev/null` 36930 # bat and cmd files are not always considered executable in cygwin causing which 36931 # to not find them 36932 if test "x$new_path" = x \ 36933 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36934 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36935 new_path=`$CYGPATH -u "$path"` 36936 fi 36937 if test "x$new_path" = x; then 36938 # It's still not found. Now this is an unrecoverable error. 36939 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36940 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36941 has_space=`$ECHO "$complete" | $GREP " "` 36942 if test "x$has_space" != x; then 36943 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36944 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36945 fi 36946 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36947 fi 36948 fi 36949 36950 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36951 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36952 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36953 # "foo.exe" is OK but "foo" is an error. 36954 # 36955 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36956 # It is also a way to make sure we got the proper file name for the real test later on. 36957 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36958 if test "x$test_shortpath" = x; then 36959 # Short path failed, file does not exist as specified. 36960 # Try adding .exe or .cmd 36961 if test -f "${new_path}.exe"; then 36962 input_to_shortpath="${new_path}.exe" 36963 elif test -f "${new_path}.cmd"; then 36964 input_to_shortpath="${new_path}.cmd" 36965 else 36966 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5 36967 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;} 36968 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36969 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36970 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36971 fi 36972 else 36973 input_to_shortpath="$new_path" 36974 fi 36975 36976 # Call helper function which possibly converts this using DOS-style short mode. 36977 # If so, the updated path is stored in $new_path. 36978 new_path="$input_to_shortpath" 36979 36980 input_path="$input_to_shortpath" 36981 # Check if we need to convert this using DOS-style short mode. If the path 36982 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36983 # take no chances and rewrite it. 36984 # Note: m4 eats our [], so we need to use [ and ] instead. 36985 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36986 if test "x$has_forbidden_chars" != x; then 36987 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36988 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36989 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36990 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36991 # Going to short mode and back again did indeed matter. Since short mode is 36992 # case insensitive, let's make it lowercase to improve readability. 36993 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36994 # Now convert it back to Unix-style (cygpath) 36995 input_path=`$CYGPATH -u "$shortmode_path"` 36996 new_path="$input_path" 36997 fi 36998 fi 36999 37000 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37001 if test "x$test_cygdrive_prefix" = x; then 37002 # As a simple fix, exclude /usr/bin since it's not a real path. 37003 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37004 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37005 # a path prefixed by /cygdrive for fixpath to work. 37006 new_path="$CYGWIN_ROOT_PATH$input_path" 37007 fi 37008 fi 37009 37010 # remove trailing .exe if any 37011 new_path="${new_path/%.exe/}" 37012 37013 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37014 37015 # First separate the path from the arguments. This will split at the first 37016 # space. 37017 complete="$CXXCPP" 37018 path="${complete%% *}" 37019 tmp="$complete EOL" 37020 arguments="${tmp#* }" 37021 37022 # Input might be given as Windows format, start by converting to 37023 # unix format. 37024 new_path="$path" 37025 37026 windows_path="$new_path" 37027 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37028 unix_path=`$CYGPATH -u "$windows_path"` 37029 new_path="$unix_path" 37030 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37031 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37032 new_path="$unix_path" 37033 fi 37034 37035 37036 # Now try to locate executable using which 37037 new_path=`$WHICH "$new_path" 2> /dev/null` 37038 37039 if test "x$new_path" = x; then 37040 # Oops. Which didn't find the executable. 37041 # The splitting of arguments from the executable at a space might have been incorrect, 37042 # since paths with space are more likely in Windows. Give it another try with the whole 37043 # argument. 37044 path="$complete" 37045 arguments="EOL" 37046 new_path="$path" 37047 37048 windows_path="$new_path" 37049 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37050 unix_path=`$CYGPATH -u "$windows_path"` 37051 new_path="$unix_path" 37052 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37053 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37054 new_path="$unix_path" 37055 fi 37056 37057 37058 new_path=`$WHICH "$new_path" 2> /dev/null` 37059 # bat and cmd files are not always considered executable in MSYS causing which 37060 # to not find them 37061 if test "x$new_path" = x \ 37062 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37063 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37064 new_path="$path" 37065 37066 windows_path="$new_path" 37067 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37068 unix_path=`$CYGPATH -u "$windows_path"` 37069 new_path="$unix_path" 37070 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37071 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37072 new_path="$unix_path" 37073 fi 37074 37075 fi 37076 37077 if test "x$new_path" = x; then 37078 # It's still not found. Now this is an unrecoverable error. 37079 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 37080 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 37081 has_space=`$ECHO "$complete" | $GREP " "` 37082 if test "x$has_space" != x; then 37083 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37084 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37085 fi 37086 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 37087 fi 37088 fi 37089 37090 # Now new_path has a complete unix path to the binary 37091 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37092 # Keep paths in /bin as-is, but remove trailing .exe if any 37093 new_path="${new_path/%.exe/}" 37094 # Do not save /bin paths to all_fixpath_prefixes! 37095 else 37096 # Not in mixed or Windows style, start by that. 37097 new_path=`cmd //c echo $new_path` 37098 37099 input_path="$new_path" 37100 # Check if we need to convert this using DOS-style short mode. If the path 37101 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37102 # take no chances and rewrite it. 37103 # Note: m4 eats our [], so we need to use [ and ] instead. 37104 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37105 if test "x$has_forbidden_chars" != x; then 37106 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37107 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37108 fi 37109 37110 # Output is in $new_path 37111 37112 windows_path="$new_path" 37113 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37114 unix_path=`$CYGPATH -u "$windows_path"` 37115 new_path="$unix_path" 37116 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37117 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37118 new_path="$unix_path" 37119 fi 37120 37121 # remove trailing .exe if any 37122 new_path="${new_path/%.exe/}" 37123 37124 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37125 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37126 fi 37127 37128 else 37129 # We're on a unix platform. Hooray! :) 37130 # First separate the path from the arguments. This will split at the first 37131 # space. 37132 complete="$CXXCPP" 37133 path="${complete%% *}" 37134 tmp="$complete EOL" 37135 arguments="${tmp#* }" 37136 37137 # Cannot rely on the command "which" here since it doesn't always work. 37138 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37139 if test -z "$is_absolute_path"; then 37140 # Path to executable is not absolute. Find it. 37141 IFS_save="$IFS" 37142 IFS=: 37143 for p in $PATH; do 37144 if test -f "$p/$path" && test -x "$p/$path"; then 37145 new_path="$p/$path" 37146 break 37147 fi 37148 done 37149 IFS="$IFS_save" 37150 else 37151 # This is an absolute path, we can use it without further modifications. 37152 new_path="$path" 37153 fi 37154 37155 if test "x$new_path" = x; then 37156 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 37157 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 37158 has_space=`$ECHO "$complete" | $GREP " "` 37159 if test "x$has_space" != x; then 37160 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37161 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37162 fi 37163 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 37164 fi 37165 fi 37166 37167 # Now join together the path and the arguments once again 37168 if test "x$arguments" != xEOL; then 37169 new_complete="$new_path ${arguments% *}" 37170 else 37171 new_complete="$new_path" 37172 fi 37173 37174 if test "x$complete" != "x$new_complete"; then 37175 CXXCPP="$new_complete" 37176 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5 37177 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;} 37178 fi 37179 fi 37180 37181 37182 # 37183 # Setup the linker (LD) 37184 # 37185 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 37186 # In the Microsoft toolchain we have a separate LD command "link". 37187 # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is 37188 # a cygwin program for something completely different. 37189 # Extract the first word of "link", so it can be a program name with args. 37190 set dummy link; ac_word=$2 37191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37192 $as_echo_n "checking for $ac_word... " >&6; } 37193 if ${ac_cv_prog_LD+:} false; then : 37194 $as_echo_n "(cached) " >&6 37195 else 37196 if test -n "$LD"; then 37197 ac_cv_prog_LD="$LD" # Let the user override the test. 37198 else 37199 ac_prog_rejected=no 37200 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37201 for as_dir in $PATH 37202 do 37203 IFS=$as_save_IFS 37204 test -z "$as_dir" && as_dir=. 37205 for ac_exec_ext in '' $ac_executable_extensions; do 37206 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37207 if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then 37208 ac_prog_rejected=yes 37209 continue 37210 fi 37211 ac_cv_prog_LD="link" 37212 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37213 break 2 37214 fi 37215 done 37216 done 37217 IFS=$as_save_IFS 37218 37219 if test $ac_prog_rejected = yes; then 37220 # We found a bogon in the path, so make sure we never use it. 37221 set dummy $ac_cv_prog_LD 37222 shift 37223 if test $# != 0; then 37224 # We chose a different compiler from the bogus one. 37225 # However, it has the same basename, so the bogon will be chosen 37226 # first if we set LD to just the basename; use the full file name. 37227 shift 37228 ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@" 37229 fi 37230 fi 37231 fi 37232 fi 37233 LD=$ac_cv_prog_LD 37234 if test -n "$LD"; then 37235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 37236 $as_echo "$LD" >&6; } 37237 else 37238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37239 $as_echo "no" >&6; } 37240 fi 37241 37242 37243 37244 # Only process if variable expands to non-empty 37245 37246 if test "x$LD" != x; then 37247 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37248 37249 # First separate the path from the arguments. This will split at the first 37250 # space. 37251 complete="$LD" 37252 path="${complete%% *}" 37253 tmp="$complete EOL" 37254 arguments="${tmp#* }" 37255 37256 # Input might be given as Windows format, start by converting to 37257 # unix format. 37258 new_path=`$CYGPATH -u "$path"` 37259 37260 # Now try to locate executable using which 37261 new_path=`$WHICH "$new_path" 2> /dev/null` 37262 # bat and cmd files are not always considered executable in cygwin causing which 37263 # to not find them 37264 if test "x$new_path" = x \ 37265 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37266 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37267 new_path=`$CYGPATH -u "$path"` 37268 fi 37269 if test "x$new_path" = x; then 37270 # Oops. Which didn't find the executable. 37271 # The splitting of arguments from the executable at a space might have been incorrect, 37272 # since paths with space are more likely in Windows. Give it another try with the whole 37273 # argument. 37274 path="$complete" 37275 arguments="EOL" 37276 new_path=`$CYGPATH -u "$path"` 37277 new_path=`$WHICH "$new_path" 2> /dev/null` 37278 # bat and cmd files are not always considered executable in cygwin causing which 37279 # to not find them 37280 if test "x$new_path" = x \ 37281 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37282 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37283 new_path=`$CYGPATH -u "$path"` 37284 fi 37285 if test "x$new_path" = x; then 37286 # It's still not found. Now this is an unrecoverable error. 37287 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 37288 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 37289 has_space=`$ECHO "$complete" | $GREP " "` 37290 if test "x$has_space" != x; then 37291 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37292 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37293 fi 37294 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37295 fi 37296 fi 37297 37298 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37299 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37300 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37301 # "foo.exe" is OK but "foo" is an error. 37302 # 37303 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37304 # It is also a way to make sure we got the proper file name for the real test later on. 37305 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37306 if test "x$test_shortpath" = x; then 37307 # Short path failed, file does not exist as specified. 37308 # Try adding .exe or .cmd 37309 if test -f "${new_path}.exe"; then 37310 input_to_shortpath="${new_path}.exe" 37311 elif test -f "${new_path}.cmd"; then 37312 input_to_shortpath="${new_path}.cmd" 37313 else 37314 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5 37315 $as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;} 37316 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37317 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37318 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37319 fi 37320 else 37321 input_to_shortpath="$new_path" 37322 fi 37323 37324 # Call helper function which possibly converts this using DOS-style short mode. 37325 # If so, the updated path is stored in $new_path. 37326 new_path="$input_to_shortpath" 37327 37328 input_path="$input_to_shortpath" 37329 # Check if we need to convert this using DOS-style short mode. If the path 37330 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37331 # take no chances and rewrite it. 37332 # Note: m4 eats our [], so we need to use [ and ] instead. 37333 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37334 if test "x$has_forbidden_chars" != x; then 37335 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37336 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37337 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37338 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37339 # Going to short mode and back again did indeed matter. Since short mode is 37340 # case insensitive, let's make it lowercase to improve readability. 37341 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37342 # Now convert it back to Unix-style (cygpath) 37343 input_path=`$CYGPATH -u "$shortmode_path"` 37344 new_path="$input_path" 37345 fi 37346 fi 37347 37348 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37349 if test "x$test_cygdrive_prefix" = x; then 37350 # As a simple fix, exclude /usr/bin since it's not a real path. 37351 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37352 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37353 # a path prefixed by /cygdrive for fixpath to work. 37354 new_path="$CYGWIN_ROOT_PATH$input_path" 37355 fi 37356 fi 37357 37358 # remove trailing .exe if any 37359 new_path="${new_path/%.exe/}" 37360 37361 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37362 37363 # First separate the path from the arguments. This will split at the first 37364 # space. 37365 complete="$LD" 37366 path="${complete%% *}" 37367 tmp="$complete EOL" 37368 arguments="${tmp#* }" 37369 37370 # Input might be given as Windows format, start by converting to 37371 # unix format. 37372 new_path="$path" 37373 37374 windows_path="$new_path" 37375 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37376 unix_path=`$CYGPATH -u "$windows_path"` 37377 new_path="$unix_path" 37378 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37379 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37380 new_path="$unix_path" 37381 fi 37382 37383 37384 # Now try to locate executable using which 37385 new_path=`$WHICH "$new_path" 2> /dev/null` 37386 37387 if test "x$new_path" = x; then 37388 # Oops. Which didn't find the executable. 37389 # The splitting of arguments from the executable at a space might have been incorrect, 37390 # since paths with space are more likely in Windows. Give it another try with the whole 37391 # argument. 37392 path="$complete" 37393 arguments="EOL" 37394 new_path="$path" 37395 37396 windows_path="$new_path" 37397 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37398 unix_path=`$CYGPATH -u "$windows_path"` 37399 new_path="$unix_path" 37400 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37401 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37402 new_path="$unix_path" 37403 fi 37404 37405 37406 new_path=`$WHICH "$new_path" 2> /dev/null` 37407 # bat and cmd files are not always considered executable in MSYS causing which 37408 # to not find them 37409 if test "x$new_path" = x \ 37410 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37411 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37412 new_path="$path" 37413 37414 windows_path="$new_path" 37415 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37416 unix_path=`$CYGPATH -u "$windows_path"` 37417 new_path="$unix_path" 37418 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37419 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37420 new_path="$unix_path" 37421 fi 37422 37423 fi 37424 37425 if test "x$new_path" = x; then 37426 # It's still not found. Now this is an unrecoverable error. 37427 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 37428 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 37429 has_space=`$ECHO "$complete" | $GREP " "` 37430 if test "x$has_space" != x; then 37431 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37432 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37433 fi 37434 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37435 fi 37436 fi 37437 37438 # Now new_path has a complete unix path to the binary 37439 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37440 # Keep paths in /bin as-is, but remove trailing .exe if any 37441 new_path="${new_path/%.exe/}" 37442 # Do not save /bin paths to all_fixpath_prefixes! 37443 else 37444 # Not in mixed or Windows style, start by that. 37445 new_path=`cmd //c echo $new_path` 37446 37447 input_path="$new_path" 37448 # Check if we need to convert this using DOS-style short mode. If the path 37449 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37450 # take no chances and rewrite it. 37451 # Note: m4 eats our [], so we need to use [ and ] instead. 37452 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37453 if test "x$has_forbidden_chars" != x; then 37454 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37455 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37456 fi 37457 37458 # Output is in $new_path 37459 37460 windows_path="$new_path" 37461 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37462 unix_path=`$CYGPATH -u "$windows_path"` 37463 new_path="$unix_path" 37464 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37465 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37466 new_path="$unix_path" 37467 fi 37468 37469 # remove trailing .exe if any 37470 new_path="${new_path/%.exe/}" 37471 37472 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37473 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37474 fi 37475 37476 else 37477 # We're on a unix platform. Hooray! :) 37478 # First separate the path from the arguments. This will split at the first 37479 # space. 37480 complete="$LD" 37481 path="${complete%% *}" 37482 tmp="$complete EOL" 37483 arguments="${tmp#* }" 37484 37485 # Cannot rely on the command "which" here since it doesn't always work. 37486 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37487 if test -z "$is_absolute_path"; then 37488 # Path to executable is not absolute. Find it. 37489 IFS_save="$IFS" 37490 IFS=: 37491 for p in $PATH; do 37492 if test -f "$p/$path" && test -x "$p/$path"; then 37493 new_path="$p/$path" 37494 break 37495 fi 37496 done 37497 IFS="$IFS_save" 37498 else 37499 # This is an absolute path, we can use it without further modifications. 37500 new_path="$path" 37501 fi 37502 37503 if test "x$new_path" = x; then 37504 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 37505 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 37506 has_space=`$ECHO "$complete" | $GREP " "` 37507 if test "x$has_space" != x; then 37508 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37509 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37510 fi 37511 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37512 fi 37513 fi 37514 37515 # Now join together the path and the arguments once again 37516 if test "x$arguments" != xEOL; then 37517 new_complete="$new_path ${arguments% *}" 37518 else 37519 new_complete="$new_path" 37520 fi 37521 37522 if test "x$complete" != "x$new_complete"; then 37523 LD="$new_complete" 37524 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5 37525 $as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;} 37526 fi 37527 fi 37528 37529 # Verify that we indeed succeeded with this trick. 37530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5 37531 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; } 37532 "$LD" --version > /dev/null 37533 if test $? -eq 0 ; then 37534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37535 $as_echo "no" >&6; } 37536 as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5 37537 else 37538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 37539 $as_echo "yes" >&6; } 37540 fi 37541 LDCXX="$LD" 37542 else 37543 # All other toolchains use the compiler to link. 37544 LD="$CC" 37545 LDCXX="$CXX" 37546 fi 37547 37548 # FIXME: it should be CXXLD, according to standard (cf CXXCPP) 37549 37550 37551 # 37552 # Setup the assembler (AS) 37553 # 37554 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 37555 37556 37557 # Publish this variable in the help. 37558 37559 37560 if [ -z "${AS+x}" ]; then 37561 # The variable is not set by user, try to locate tool using the code snippet 37562 for ac_prog in as 37563 do 37564 # Extract the first word of "$ac_prog", so it can be a program name with args. 37565 set dummy $ac_prog; ac_word=$2 37566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37567 $as_echo_n "checking for $ac_word... " >&6; } 37568 if ${ac_cv_path_AS+:} false; then : 37569 $as_echo_n "(cached) " >&6 37570 else 37571 case $AS in 37572 [\\/]* | ?:[\\/]*) 37573 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37574 ;; 37575 *) 37576 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37577 for as_dir in $PATH 37578 do 37579 IFS=$as_save_IFS 37580 test -z "$as_dir" && as_dir=. 37581 for ac_exec_ext in '' $ac_executable_extensions; do 37582 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37583 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37584 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37585 break 2 37586 fi 37587 done 37588 done 37589 IFS=$as_save_IFS 37590 37591 ;; 37592 esac 37593 fi 37594 AS=$ac_cv_path_AS 37595 if test -n "$AS"; then 37596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37597 $as_echo "$AS" >&6; } 37598 else 37599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37600 $as_echo "no" >&6; } 37601 fi 37602 37603 37604 test -n "$AS" && break 37605 done 37606 37607 else 37608 # The variable is set, but is it from the command line or the environment? 37609 37610 # Try to remove the string !AS! from our list. 37611 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/} 37612 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37613 # If it failed, the variable was not from the command line. Ignore it, 37614 # but warn the user (except for BASH, which is always set by the calling BASH). 37615 if test "xAS" != xBASH; then 37616 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5 37617 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;} 37618 fi 37619 # Try to locate tool using the code snippet 37620 for ac_prog in as 37621 do 37622 # Extract the first word of "$ac_prog", so it can be a program name with args. 37623 set dummy $ac_prog; ac_word=$2 37624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37625 $as_echo_n "checking for $ac_word... " >&6; } 37626 if ${ac_cv_path_AS+:} false; then : 37627 $as_echo_n "(cached) " >&6 37628 else 37629 case $AS in 37630 [\\/]* | ?:[\\/]*) 37631 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37632 ;; 37633 *) 37634 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37635 for as_dir in $PATH 37636 do 37637 IFS=$as_save_IFS 37638 test -z "$as_dir" && as_dir=. 37639 for ac_exec_ext in '' $ac_executable_extensions; do 37640 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37641 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37642 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37643 break 2 37644 fi 37645 done 37646 done 37647 IFS=$as_save_IFS 37648 37649 ;; 37650 esac 37651 fi 37652 AS=$ac_cv_path_AS 37653 if test -n "$AS"; then 37654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37655 $as_echo "$AS" >&6; } 37656 else 37657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37658 $as_echo "no" >&6; } 37659 fi 37660 37661 37662 test -n "$AS" && break 37663 done 37664 37665 else 37666 # If it succeeded, then it was overridden by the user. We will use it 37667 # for the tool. 37668 37669 # First remove it from the list of overridden variables, so we can test 37670 # for unknown variables in the end. 37671 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37672 37673 # Check if we try to supply an empty value 37674 if test "x$AS" = x; then 37675 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AS= (no value)" >&5 37676 $as_echo "$as_me: Setting user supplied tool AS= (no value)" >&6;} 37677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 37678 $as_echo_n "checking for AS... " >&6; } 37679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37680 $as_echo "disabled" >&6; } 37681 else 37682 # Check if the provided tool contains a complete path. 37683 tool_specified="$AS" 37684 tool_basename="${tool_specified##*/}" 37685 if test "x$tool_basename" = "x$tool_specified"; then 37686 # A command without a complete path is provided, search $PATH. 37687 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5 37688 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;} 37689 # Extract the first word of "$tool_basename", so it can be a program name with args. 37690 set dummy $tool_basename; ac_word=$2 37691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37692 $as_echo_n "checking for $ac_word... " >&6; } 37693 if ${ac_cv_path_AS+:} false; then : 37694 $as_echo_n "(cached) " >&6 37695 else 37696 case $AS in 37697 [\\/]* | ?:[\\/]*) 37698 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37699 ;; 37700 *) 37701 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37702 for as_dir in $PATH 37703 do 37704 IFS=$as_save_IFS 37705 test -z "$as_dir" && as_dir=. 37706 for ac_exec_ext in '' $ac_executable_extensions; do 37707 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37708 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37709 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37710 break 2 37711 fi 37712 done 37713 done 37714 IFS=$as_save_IFS 37715 37716 ;; 37717 esac 37718 fi 37719 AS=$ac_cv_path_AS 37720 if test -n "$AS"; then 37721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37722 $as_echo "$AS" >&6; } 37723 else 37724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37725 $as_echo "no" >&6; } 37726 fi 37727 37728 37729 if test "x$AS" = x; then 37730 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37731 fi 37732 else 37733 # Otherwise we believe it is a complete path. Use it as it is. 37734 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5 37735 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;} 37736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 37737 $as_echo_n "checking for AS... " >&6; } 37738 if test ! -x "$tool_specified"; then 37739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37740 $as_echo "not found" >&6; } 37741 as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5 37742 fi 37743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37744 $as_echo "$tool_specified" >&6; } 37745 fi 37746 fi 37747 fi 37748 37749 fi 37750 37751 37752 37753 # Only process if variable expands to non-empty 37754 37755 if test "x$AS" != x; then 37756 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37757 37758 # First separate the path from the arguments. This will split at the first 37759 # space. 37760 complete="$AS" 37761 path="${complete%% *}" 37762 tmp="$complete EOL" 37763 arguments="${tmp#* }" 37764 37765 # Input might be given as Windows format, start by converting to 37766 # unix format. 37767 new_path=`$CYGPATH -u "$path"` 37768 37769 # Now try to locate executable using which 37770 new_path=`$WHICH "$new_path" 2> /dev/null` 37771 # bat and cmd files are not always considered executable in cygwin causing which 37772 # to not find them 37773 if test "x$new_path" = x \ 37774 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37775 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37776 new_path=`$CYGPATH -u "$path"` 37777 fi 37778 if test "x$new_path" = x; then 37779 # Oops. Which didn't find the executable. 37780 # The splitting of arguments from the executable at a space might have been incorrect, 37781 # since paths with space are more likely in Windows. Give it another try with the whole 37782 # argument. 37783 path="$complete" 37784 arguments="EOL" 37785 new_path=`$CYGPATH -u "$path"` 37786 new_path=`$WHICH "$new_path" 2> /dev/null` 37787 # bat and cmd files are not always considered executable in cygwin causing which 37788 # to not find them 37789 if test "x$new_path" = x \ 37790 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37791 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37792 new_path=`$CYGPATH -u "$path"` 37793 fi 37794 if test "x$new_path" = x; then 37795 # It's still not found. Now this is an unrecoverable error. 37796 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37797 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37798 has_space=`$ECHO "$complete" | $GREP " "` 37799 if test "x$has_space" != x; then 37800 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37801 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37802 fi 37803 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37804 fi 37805 fi 37806 37807 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37808 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37809 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37810 # "foo.exe" is OK but "foo" is an error. 37811 # 37812 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37813 # It is also a way to make sure we got the proper file name for the real test later on. 37814 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37815 if test "x$test_shortpath" = x; then 37816 # Short path failed, file does not exist as specified. 37817 # Try adding .exe or .cmd 37818 if test -f "${new_path}.exe"; then 37819 input_to_shortpath="${new_path}.exe" 37820 elif test -f "${new_path}.cmd"; then 37821 input_to_shortpath="${new_path}.cmd" 37822 else 37823 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5 37824 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;} 37825 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37826 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37827 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37828 fi 37829 else 37830 input_to_shortpath="$new_path" 37831 fi 37832 37833 # Call helper function which possibly converts this using DOS-style short mode. 37834 # If so, the updated path is stored in $new_path. 37835 new_path="$input_to_shortpath" 37836 37837 input_path="$input_to_shortpath" 37838 # Check if we need to convert this using DOS-style short mode. If the path 37839 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37840 # take no chances and rewrite it. 37841 # Note: m4 eats our [], so we need to use [ and ] instead. 37842 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37843 if test "x$has_forbidden_chars" != x; then 37844 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37845 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37846 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37847 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37848 # Going to short mode and back again did indeed matter. Since short mode is 37849 # case insensitive, let's make it lowercase to improve readability. 37850 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37851 # Now convert it back to Unix-style (cygpath) 37852 input_path=`$CYGPATH -u "$shortmode_path"` 37853 new_path="$input_path" 37854 fi 37855 fi 37856 37857 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37858 if test "x$test_cygdrive_prefix" = x; then 37859 # As a simple fix, exclude /usr/bin since it's not a real path. 37860 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37861 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37862 # a path prefixed by /cygdrive for fixpath to work. 37863 new_path="$CYGWIN_ROOT_PATH$input_path" 37864 fi 37865 fi 37866 37867 # remove trailing .exe if any 37868 new_path="${new_path/%.exe/}" 37869 37870 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37871 37872 # First separate the path from the arguments. This will split at the first 37873 # space. 37874 complete="$AS" 37875 path="${complete%% *}" 37876 tmp="$complete EOL" 37877 arguments="${tmp#* }" 37878 37879 # Input might be given as Windows format, start by converting to 37880 # unix format. 37881 new_path="$path" 37882 37883 windows_path="$new_path" 37884 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37885 unix_path=`$CYGPATH -u "$windows_path"` 37886 new_path="$unix_path" 37887 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37888 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37889 new_path="$unix_path" 37890 fi 37891 37892 37893 # Now try to locate executable using which 37894 new_path=`$WHICH "$new_path" 2> /dev/null` 37895 37896 if test "x$new_path" = x; then 37897 # Oops. Which didn't find the executable. 37898 # The splitting of arguments from the executable at a space might have been incorrect, 37899 # since paths with space are more likely in Windows. Give it another try with the whole 37900 # argument. 37901 path="$complete" 37902 arguments="EOL" 37903 new_path="$path" 37904 37905 windows_path="$new_path" 37906 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37907 unix_path=`$CYGPATH -u "$windows_path"` 37908 new_path="$unix_path" 37909 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37910 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37911 new_path="$unix_path" 37912 fi 37913 37914 37915 new_path=`$WHICH "$new_path" 2> /dev/null` 37916 # bat and cmd files are not always considered executable in MSYS causing which 37917 # to not find them 37918 if test "x$new_path" = x \ 37919 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37920 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37921 new_path="$path" 37922 37923 windows_path="$new_path" 37924 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37925 unix_path=`$CYGPATH -u "$windows_path"` 37926 new_path="$unix_path" 37927 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37928 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37929 new_path="$unix_path" 37930 fi 37931 37932 fi 37933 37934 if test "x$new_path" = x; then 37935 # It's still not found. Now this is an unrecoverable error. 37936 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37937 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37938 has_space=`$ECHO "$complete" | $GREP " "` 37939 if test "x$has_space" != x; then 37940 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37941 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37942 fi 37943 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37944 fi 37945 fi 37946 37947 # Now new_path has a complete unix path to the binary 37948 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37949 # Keep paths in /bin as-is, but remove trailing .exe if any 37950 new_path="${new_path/%.exe/}" 37951 # Do not save /bin paths to all_fixpath_prefixes! 37952 else 37953 # Not in mixed or Windows style, start by that. 37954 new_path=`cmd //c echo $new_path` 37955 37956 input_path="$new_path" 37957 # Check if we need to convert this using DOS-style short mode. If the path 37958 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37959 # take no chances and rewrite it. 37960 # Note: m4 eats our [], so we need to use [ and ] instead. 37961 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37962 if test "x$has_forbidden_chars" != x; then 37963 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37964 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37965 fi 37966 37967 # Output is in $new_path 37968 37969 windows_path="$new_path" 37970 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37971 unix_path=`$CYGPATH -u "$windows_path"` 37972 new_path="$unix_path" 37973 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37974 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37975 new_path="$unix_path" 37976 fi 37977 37978 # remove trailing .exe if any 37979 new_path="${new_path/%.exe/}" 37980 37981 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37982 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37983 fi 37984 37985 else 37986 # We're on a unix platform. Hooray! :) 37987 # First separate the path from the arguments. This will split at the first 37988 # space. 37989 complete="$AS" 37990 path="${complete%% *}" 37991 tmp="$complete EOL" 37992 arguments="${tmp#* }" 37993 37994 # Cannot rely on the command "which" here since it doesn't always work. 37995 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37996 if test -z "$is_absolute_path"; then 37997 # Path to executable is not absolute. Find it. 37998 IFS_save="$IFS" 37999 IFS=: 38000 for p in $PATH; do 38001 if test -f "$p/$path" && test -x "$p/$path"; then 38002 new_path="$p/$path" 38003 break 38004 fi 38005 done 38006 IFS="$IFS_save" 38007 else 38008 # This is an absolute path, we can use it without further modifications. 38009 new_path="$path" 38010 fi 38011 38012 if test "x$new_path" = x; then 38013 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 38014 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 38015 has_space=`$ECHO "$complete" | $GREP " "` 38016 if test "x$has_space" != x; then 38017 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38018 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38019 fi 38020 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 38021 fi 38022 fi 38023 38024 # Now join together the path and the arguments once again 38025 if test "x$arguments" != xEOL; then 38026 new_complete="$new_path ${arguments% *}" 38027 else 38028 new_complete="$new_path" 38029 fi 38030 38031 if test "x$complete" != "x$new_complete"; then 38032 AS="$new_complete" 38033 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5 38034 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;} 38035 fi 38036 fi 38037 38038 if test "x$AS" = x; then 38039 as_fn_error $? "Solaris assembler (as) is required. Please install via \"pkg install pkg:/developer/assembler\"." "$LINENO" 5 38040 fi 38041 else 38042 # FIXME: is this correct for microsoft? 38043 AS="$CC -c" 38044 fi 38045 38046 38047 # 38048 # Setup the archiver (AR) 38049 # 38050 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 38051 # The corresponding ar tool is lib.exe (used to create static libraries) 38052 # Extract the first word of "lib", so it can be a program name with args. 38053 set dummy lib; ac_word=$2 38054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38055 $as_echo_n "checking for $ac_word... " >&6; } 38056 if ${ac_cv_prog_AR+:} false; then : 38057 $as_echo_n "(cached) " >&6 38058 else 38059 if test -n "$AR"; then 38060 ac_cv_prog_AR="$AR" # Let the user override the test. 38061 else 38062 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38063 for as_dir in $PATH 38064 do 38065 IFS=$as_save_IFS 38066 test -z "$as_dir" && as_dir=. 38067 for ac_exec_ext in '' $ac_executable_extensions; do 38068 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38069 ac_cv_prog_AR="lib" 38070 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38071 break 2 38072 fi 38073 done 38074 done 38075 IFS=$as_save_IFS 38076 38077 fi 38078 fi 38079 AR=$ac_cv_prog_AR 38080 if test -n "$AR"; then 38081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38082 $as_echo "$AR" >&6; } 38083 else 38084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38085 $as_echo "no" >&6; } 38086 fi 38087 38088 38089 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 38090 38091 38092 # Publish this variable in the help. 38093 38094 38095 if [ -z "${AR+x}" ]; then 38096 # The variable is not set by user, try to locate tool using the code snippet 38097 if test -n "$ac_tool_prefix"; then 38098 for ac_prog in ar gcc-ar 38099 do 38100 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38101 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38103 $as_echo_n "checking for $ac_word... " >&6; } 38104 if ${ac_cv_prog_AR+:} false; then : 38105 $as_echo_n "(cached) " >&6 38106 else 38107 if test -n "$AR"; then 38108 ac_cv_prog_AR="$AR" # Let the user override the test. 38109 else 38110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38111 for as_dir in $PATH 38112 do 38113 IFS=$as_save_IFS 38114 test -z "$as_dir" && as_dir=. 38115 for ac_exec_ext in '' $ac_executable_extensions; do 38116 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38117 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38118 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38119 break 2 38120 fi 38121 done 38122 done 38123 IFS=$as_save_IFS 38124 38125 fi 38126 fi 38127 AR=$ac_cv_prog_AR 38128 if test -n "$AR"; then 38129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38130 $as_echo "$AR" >&6; } 38131 else 38132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38133 $as_echo "no" >&6; } 38134 fi 38135 38136 38137 test -n "$AR" && break 38138 done 38139 fi 38140 if test -z "$AR"; then 38141 ac_ct_AR=$AR 38142 for ac_prog in ar gcc-ar 38143 do 38144 # Extract the first word of "$ac_prog", so it can be a program name with args. 38145 set dummy $ac_prog; ac_word=$2 38146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38147 $as_echo_n "checking for $ac_word... " >&6; } 38148 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38149 $as_echo_n "(cached) " >&6 38150 else 38151 if test -n "$ac_ct_AR"; then 38152 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38153 else 38154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38155 for as_dir in $PATH 38156 do 38157 IFS=$as_save_IFS 38158 test -z "$as_dir" && as_dir=. 38159 for ac_exec_ext in '' $ac_executable_extensions; do 38160 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38161 ac_cv_prog_ac_ct_AR="$ac_prog" 38162 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38163 break 2 38164 fi 38165 done 38166 done 38167 IFS=$as_save_IFS 38168 38169 fi 38170 fi 38171 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38172 if test -n "$ac_ct_AR"; then 38173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38174 $as_echo "$ac_ct_AR" >&6; } 38175 else 38176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38177 $as_echo "no" >&6; } 38178 fi 38179 38180 38181 test -n "$ac_ct_AR" && break 38182 done 38183 38184 if test "x$ac_ct_AR" = x; then 38185 AR="" 38186 else 38187 case $cross_compiling:$ac_tool_warned in 38188 yes:) 38189 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38190 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38191 ac_tool_warned=yes ;; 38192 esac 38193 AR=$ac_ct_AR 38194 fi 38195 fi 38196 38197 else 38198 # The variable is set, but is it from the command line or the environment? 38199 38200 # Try to remove the string !AR! from our list. 38201 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 38202 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38203 # If it failed, the variable was not from the command line. Ignore it, 38204 # but warn the user (except for BASH, which is always set by the calling BASH). 38205 if test "xAR" != xBASH; then 38206 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 38207 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 38208 fi 38209 # Try to locate tool using the code snippet 38210 if test -n "$ac_tool_prefix"; then 38211 for ac_prog in ar gcc-ar 38212 do 38213 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38214 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38216 $as_echo_n "checking for $ac_word... " >&6; } 38217 if ${ac_cv_prog_AR+:} false; then : 38218 $as_echo_n "(cached) " >&6 38219 else 38220 if test -n "$AR"; then 38221 ac_cv_prog_AR="$AR" # Let the user override the test. 38222 else 38223 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38224 for as_dir in $PATH 38225 do 38226 IFS=$as_save_IFS 38227 test -z "$as_dir" && as_dir=. 38228 for ac_exec_ext in '' $ac_executable_extensions; do 38229 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38230 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38231 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38232 break 2 38233 fi 38234 done 38235 done 38236 IFS=$as_save_IFS 38237 38238 fi 38239 fi 38240 AR=$ac_cv_prog_AR 38241 if test -n "$AR"; then 38242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38243 $as_echo "$AR" >&6; } 38244 else 38245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38246 $as_echo "no" >&6; } 38247 fi 38248 38249 38250 test -n "$AR" && break 38251 done 38252 fi 38253 if test -z "$AR"; then 38254 ac_ct_AR=$AR 38255 for ac_prog in ar gcc-ar 38256 do 38257 # Extract the first word of "$ac_prog", so it can be a program name with args. 38258 set dummy $ac_prog; ac_word=$2 38259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38260 $as_echo_n "checking for $ac_word... " >&6; } 38261 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38262 $as_echo_n "(cached) " >&6 38263 else 38264 if test -n "$ac_ct_AR"; then 38265 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38266 else 38267 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38268 for as_dir in $PATH 38269 do 38270 IFS=$as_save_IFS 38271 test -z "$as_dir" && as_dir=. 38272 for ac_exec_ext in '' $ac_executable_extensions; do 38273 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38274 ac_cv_prog_ac_ct_AR="$ac_prog" 38275 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38276 break 2 38277 fi 38278 done 38279 done 38280 IFS=$as_save_IFS 38281 38282 fi 38283 fi 38284 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38285 if test -n "$ac_ct_AR"; then 38286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38287 $as_echo "$ac_ct_AR" >&6; } 38288 else 38289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38290 $as_echo "no" >&6; } 38291 fi 38292 38293 38294 test -n "$ac_ct_AR" && break 38295 done 38296 38297 if test "x$ac_ct_AR" = x; then 38298 AR="" 38299 else 38300 case $cross_compiling:$ac_tool_warned in 38301 yes:) 38302 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38303 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38304 ac_tool_warned=yes ;; 38305 esac 38306 AR=$ac_ct_AR 38307 fi 38308 fi 38309 38310 else 38311 # If it succeeded, then it was overridden by the user. We will use it 38312 # for the tool. 38313 38314 # First remove it from the list of overridden variables, so we can test 38315 # for unknown variables in the end. 38316 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38317 38318 # Check if we try to supply an empty value 38319 if test "x$AR" = x; then 38320 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 38321 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 38322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38323 $as_echo_n "checking for AR... " >&6; } 38324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38325 $as_echo "disabled" >&6; } 38326 else 38327 # Check if the provided tool contains a complete path. 38328 tool_specified="$AR" 38329 tool_basename="${tool_specified##*/}" 38330 if test "x$tool_basename" = "x$tool_specified"; then 38331 # A command without a complete path is provided, search $PATH. 38332 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 38333 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 38334 # Extract the first word of "$tool_basename", so it can be a program name with args. 38335 set dummy $tool_basename; ac_word=$2 38336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38337 $as_echo_n "checking for $ac_word... " >&6; } 38338 if ${ac_cv_path_AR+:} false; then : 38339 $as_echo_n "(cached) " >&6 38340 else 38341 case $AR in 38342 [\\/]* | ?:[\\/]*) 38343 ac_cv_path_AR="$AR" # Let the user override the test with a path. 38344 ;; 38345 *) 38346 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38347 for as_dir in $PATH 38348 do 38349 IFS=$as_save_IFS 38350 test -z "$as_dir" && as_dir=. 38351 for ac_exec_ext in '' $ac_executable_extensions; do 38352 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38353 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 38354 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38355 break 2 38356 fi 38357 done 38358 done 38359 IFS=$as_save_IFS 38360 38361 ;; 38362 esac 38363 fi 38364 AR=$ac_cv_path_AR 38365 if test -n "$AR"; then 38366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38367 $as_echo "$AR" >&6; } 38368 else 38369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38370 $as_echo "no" >&6; } 38371 fi 38372 38373 38374 if test "x$AR" = x; then 38375 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38376 fi 38377 else 38378 # Otherwise we believe it is a complete path. Use it as it is. 38379 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 38380 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 38381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38382 $as_echo_n "checking for AR... " >&6; } 38383 if test ! -x "$tool_specified"; then 38384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38385 $as_echo "not found" >&6; } 38386 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 38387 fi 38388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38389 $as_echo "$tool_specified" >&6; } 38390 fi 38391 fi 38392 fi 38393 38394 fi 38395 38396 38397 else 38398 38399 38400 # Publish this variable in the help. 38401 38402 38403 if [ -z "${AR+x}" ]; then 38404 # The variable is not set by user, try to locate tool using the code snippet 38405 if test -n "$ac_tool_prefix"; then 38406 for ac_prog in ar 38407 do 38408 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38409 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38411 $as_echo_n "checking for $ac_word... " >&6; } 38412 if ${ac_cv_prog_AR+:} false; then : 38413 $as_echo_n "(cached) " >&6 38414 else 38415 if test -n "$AR"; then 38416 ac_cv_prog_AR="$AR" # Let the user override the test. 38417 else 38418 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38419 for as_dir in $PATH 38420 do 38421 IFS=$as_save_IFS 38422 test -z "$as_dir" && as_dir=. 38423 for ac_exec_ext in '' $ac_executable_extensions; do 38424 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38425 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38426 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38427 break 2 38428 fi 38429 done 38430 done 38431 IFS=$as_save_IFS 38432 38433 fi 38434 fi 38435 AR=$ac_cv_prog_AR 38436 if test -n "$AR"; then 38437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38438 $as_echo "$AR" >&6; } 38439 else 38440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38441 $as_echo "no" >&6; } 38442 fi 38443 38444 38445 test -n "$AR" && break 38446 done 38447 fi 38448 if test -z "$AR"; then 38449 ac_ct_AR=$AR 38450 for ac_prog in ar 38451 do 38452 # Extract the first word of "$ac_prog", so it can be a program name with args. 38453 set dummy $ac_prog; ac_word=$2 38454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38455 $as_echo_n "checking for $ac_word... " >&6; } 38456 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38457 $as_echo_n "(cached) " >&6 38458 else 38459 if test -n "$ac_ct_AR"; then 38460 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38461 else 38462 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38463 for as_dir in $PATH 38464 do 38465 IFS=$as_save_IFS 38466 test -z "$as_dir" && as_dir=. 38467 for ac_exec_ext in '' $ac_executable_extensions; do 38468 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38469 ac_cv_prog_ac_ct_AR="$ac_prog" 38470 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38471 break 2 38472 fi 38473 done 38474 done 38475 IFS=$as_save_IFS 38476 38477 fi 38478 fi 38479 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38480 if test -n "$ac_ct_AR"; then 38481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38482 $as_echo "$ac_ct_AR" >&6; } 38483 else 38484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38485 $as_echo "no" >&6; } 38486 fi 38487 38488 38489 test -n "$ac_ct_AR" && break 38490 done 38491 38492 if test "x$ac_ct_AR" = x; then 38493 AR="" 38494 else 38495 case $cross_compiling:$ac_tool_warned in 38496 yes:) 38497 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38498 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38499 ac_tool_warned=yes ;; 38500 esac 38501 AR=$ac_ct_AR 38502 fi 38503 fi 38504 38505 else 38506 # The variable is set, but is it from the command line or the environment? 38507 38508 # Try to remove the string !AR! from our list. 38509 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 38510 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38511 # If it failed, the variable was not from the command line. Ignore it, 38512 # but warn the user (except for BASH, which is always set by the calling BASH). 38513 if test "xAR" != xBASH; then 38514 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 38515 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 38516 fi 38517 # Try to locate tool using the code snippet 38518 if test -n "$ac_tool_prefix"; then 38519 for ac_prog in ar 38520 do 38521 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38522 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38524 $as_echo_n "checking for $ac_word... " >&6; } 38525 if ${ac_cv_prog_AR+:} false; then : 38526 $as_echo_n "(cached) " >&6 38527 else 38528 if test -n "$AR"; then 38529 ac_cv_prog_AR="$AR" # Let the user override the test. 38530 else 38531 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38532 for as_dir in $PATH 38533 do 38534 IFS=$as_save_IFS 38535 test -z "$as_dir" && as_dir=. 38536 for ac_exec_ext in '' $ac_executable_extensions; do 38537 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38538 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38539 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38540 break 2 38541 fi 38542 done 38543 done 38544 IFS=$as_save_IFS 38545 38546 fi 38547 fi 38548 AR=$ac_cv_prog_AR 38549 if test -n "$AR"; then 38550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38551 $as_echo "$AR" >&6; } 38552 else 38553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38554 $as_echo "no" >&6; } 38555 fi 38556 38557 38558 test -n "$AR" && break 38559 done 38560 fi 38561 if test -z "$AR"; then 38562 ac_ct_AR=$AR 38563 for ac_prog in ar 38564 do 38565 # Extract the first word of "$ac_prog", so it can be a program name with args. 38566 set dummy $ac_prog; ac_word=$2 38567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38568 $as_echo_n "checking for $ac_word... " >&6; } 38569 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38570 $as_echo_n "(cached) " >&6 38571 else 38572 if test -n "$ac_ct_AR"; then 38573 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38574 else 38575 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38576 for as_dir in $PATH 38577 do 38578 IFS=$as_save_IFS 38579 test -z "$as_dir" && as_dir=. 38580 for ac_exec_ext in '' $ac_executable_extensions; do 38581 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38582 ac_cv_prog_ac_ct_AR="$ac_prog" 38583 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38584 break 2 38585 fi 38586 done 38587 done 38588 IFS=$as_save_IFS 38589 38590 fi 38591 fi 38592 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38593 if test -n "$ac_ct_AR"; then 38594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38595 $as_echo "$ac_ct_AR" >&6; } 38596 else 38597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38598 $as_echo "no" >&6; } 38599 fi 38600 38601 38602 test -n "$ac_ct_AR" && break 38603 done 38604 38605 if test "x$ac_ct_AR" = x; then 38606 AR="" 38607 else 38608 case $cross_compiling:$ac_tool_warned in 38609 yes:) 38610 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38611 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38612 ac_tool_warned=yes ;; 38613 esac 38614 AR=$ac_ct_AR 38615 fi 38616 fi 38617 38618 else 38619 # If it succeeded, then it was overridden by the user. We will use it 38620 # for the tool. 38621 38622 # First remove it from the list of overridden variables, so we can test 38623 # for unknown variables in the end. 38624 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38625 38626 # Check if we try to supply an empty value 38627 if test "x$AR" = x; then 38628 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 38629 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 38630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38631 $as_echo_n "checking for AR... " >&6; } 38632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38633 $as_echo "disabled" >&6; } 38634 else 38635 # Check if the provided tool contains a complete path. 38636 tool_specified="$AR" 38637 tool_basename="${tool_specified##*/}" 38638 if test "x$tool_basename" = "x$tool_specified"; then 38639 # A command without a complete path is provided, search $PATH. 38640 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 38641 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 38642 # Extract the first word of "$tool_basename", so it can be a program name with args. 38643 set dummy $tool_basename; ac_word=$2 38644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38645 $as_echo_n "checking for $ac_word... " >&6; } 38646 if ${ac_cv_path_AR+:} false; then : 38647 $as_echo_n "(cached) " >&6 38648 else 38649 case $AR in 38650 [\\/]* | ?:[\\/]*) 38651 ac_cv_path_AR="$AR" # Let the user override the test with a path. 38652 ;; 38653 *) 38654 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38655 for as_dir in $PATH 38656 do 38657 IFS=$as_save_IFS 38658 test -z "$as_dir" && as_dir=. 38659 for ac_exec_ext in '' $ac_executable_extensions; do 38660 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38661 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 38662 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38663 break 2 38664 fi 38665 done 38666 done 38667 IFS=$as_save_IFS 38668 38669 ;; 38670 esac 38671 fi 38672 AR=$ac_cv_path_AR 38673 if test -n "$AR"; then 38674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38675 $as_echo "$AR" >&6; } 38676 else 38677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38678 $as_echo "no" >&6; } 38679 fi 38680 38681 38682 if test "x$AR" = x; then 38683 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38684 fi 38685 else 38686 # Otherwise we believe it is a complete path. Use it as it is. 38687 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 38688 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 38689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38690 $as_echo_n "checking for AR... " >&6; } 38691 if test ! -x "$tool_specified"; then 38692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38693 $as_echo "not found" >&6; } 38694 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 38695 fi 38696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38697 $as_echo "$tool_specified" >&6; } 38698 fi 38699 fi 38700 fi 38701 38702 fi 38703 38704 38705 fi 38706 38707 # Only process if variable expands to non-empty 38708 38709 if test "x$AR" != x; then 38710 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38711 38712 # First separate the path from the arguments. This will split at the first 38713 # space. 38714 complete="$AR" 38715 path="${complete%% *}" 38716 tmp="$complete EOL" 38717 arguments="${tmp#* }" 38718 38719 # Input might be given as Windows format, start by converting to 38720 # unix format. 38721 new_path=`$CYGPATH -u "$path"` 38722 38723 # Now try to locate executable using which 38724 new_path=`$WHICH "$new_path" 2> /dev/null` 38725 # bat and cmd files are not always considered executable in cygwin causing which 38726 # to not find them 38727 if test "x$new_path" = x \ 38728 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38729 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38730 new_path=`$CYGPATH -u "$path"` 38731 fi 38732 if test "x$new_path" = x; then 38733 # Oops. Which didn't find the executable. 38734 # The splitting of arguments from the executable at a space might have been incorrect, 38735 # since paths with space are more likely in Windows. Give it another try with the whole 38736 # argument. 38737 path="$complete" 38738 arguments="EOL" 38739 new_path=`$CYGPATH -u "$path"` 38740 new_path=`$WHICH "$new_path" 2> /dev/null` 38741 # bat and cmd files are not always considered executable in cygwin causing which 38742 # to not find them 38743 if test "x$new_path" = x \ 38744 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38745 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38746 new_path=`$CYGPATH -u "$path"` 38747 fi 38748 if test "x$new_path" = x; then 38749 # It's still not found. Now this is an unrecoverable error. 38750 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38751 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38752 has_space=`$ECHO "$complete" | $GREP " "` 38753 if test "x$has_space" != x; then 38754 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38755 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38756 fi 38757 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38758 fi 38759 fi 38760 38761 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38762 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38763 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38764 # "foo.exe" is OK but "foo" is an error. 38765 # 38766 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38767 # It is also a way to make sure we got the proper file name for the real test later on. 38768 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38769 if test "x$test_shortpath" = x; then 38770 # Short path failed, file does not exist as specified. 38771 # Try adding .exe or .cmd 38772 if test -f "${new_path}.exe"; then 38773 input_to_shortpath="${new_path}.exe" 38774 elif test -f "${new_path}.cmd"; then 38775 input_to_shortpath="${new_path}.cmd" 38776 else 38777 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5 38778 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;} 38779 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38780 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38781 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38782 fi 38783 else 38784 input_to_shortpath="$new_path" 38785 fi 38786 38787 # Call helper function which possibly converts this using DOS-style short mode. 38788 # If so, the updated path is stored in $new_path. 38789 new_path="$input_to_shortpath" 38790 38791 input_path="$input_to_shortpath" 38792 # Check if we need to convert this using DOS-style short mode. If the path 38793 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38794 # take no chances and rewrite it. 38795 # Note: m4 eats our [], so we need to use [ and ] instead. 38796 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38797 if test "x$has_forbidden_chars" != x; then 38798 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38799 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38800 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38801 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38802 # Going to short mode and back again did indeed matter. Since short mode is 38803 # case insensitive, let's make it lowercase to improve readability. 38804 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38805 # Now convert it back to Unix-style (cygpath) 38806 input_path=`$CYGPATH -u "$shortmode_path"` 38807 new_path="$input_path" 38808 fi 38809 fi 38810 38811 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38812 if test "x$test_cygdrive_prefix" = x; then 38813 # As a simple fix, exclude /usr/bin since it's not a real path. 38814 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38815 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38816 # a path prefixed by /cygdrive for fixpath to work. 38817 new_path="$CYGWIN_ROOT_PATH$input_path" 38818 fi 38819 fi 38820 38821 # remove trailing .exe if any 38822 new_path="${new_path/%.exe/}" 38823 38824 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38825 38826 # First separate the path from the arguments. This will split at the first 38827 # space. 38828 complete="$AR" 38829 path="${complete%% *}" 38830 tmp="$complete EOL" 38831 arguments="${tmp#* }" 38832 38833 # Input might be given as Windows format, start by converting to 38834 # unix format. 38835 new_path="$path" 38836 38837 windows_path="$new_path" 38838 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38839 unix_path=`$CYGPATH -u "$windows_path"` 38840 new_path="$unix_path" 38841 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38842 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38843 new_path="$unix_path" 38844 fi 38845 38846 38847 # Now try to locate executable using which 38848 new_path=`$WHICH "$new_path" 2> /dev/null` 38849 38850 if test "x$new_path" = x; then 38851 # Oops. Which didn't find the executable. 38852 # The splitting of arguments from the executable at a space might have been incorrect, 38853 # since paths with space are more likely in Windows. Give it another try with the whole 38854 # argument. 38855 path="$complete" 38856 arguments="EOL" 38857 new_path="$path" 38858 38859 windows_path="$new_path" 38860 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38861 unix_path=`$CYGPATH -u "$windows_path"` 38862 new_path="$unix_path" 38863 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38864 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38865 new_path="$unix_path" 38866 fi 38867 38868 38869 new_path=`$WHICH "$new_path" 2> /dev/null` 38870 # bat and cmd files are not always considered executable in MSYS causing which 38871 # to not find them 38872 if test "x$new_path" = x \ 38873 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38874 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38875 new_path="$path" 38876 38877 windows_path="$new_path" 38878 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38879 unix_path=`$CYGPATH -u "$windows_path"` 38880 new_path="$unix_path" 38881 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38882 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38883 new_path="$unix_path" 38884 fi 38885 38886 fi 38887 38888 if test "x$new_path" = x; then 38889 # It's still not found. Now this is an unrecoverable error. 38890 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38891 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38892 has_space=`$ECHO "$complete" | $GREP " "` 38893 if test "x$has_space" != x; then 38894 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38895 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38896 fi 38897 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38898 fi 38899 fi 38900 38901 # Now new_path has a complete unix path to the binary 38902 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38903 # Keep paths in /bin as-is, but remove trailing .exe if any 38904 new_path="${new_path/%.exe/}" 38905 # Do not save /bin paths to all_fixpath_prefixes! 38906 else 38907 # Not in mixed or Windows style, start by that. 38908 new_path=`cmd //c echo $new_path` 38909 38910 input_path="$new_path" 38911 # Check if we need to convert this using DOS-style short mode. If the path 38912 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38913 # take no chances and rewrite it. 38914 # Note: m4 eats our [], so we need to use [ and ] instead. 38915 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38916 if test "x$has_forbidden_chars" != x; then 38917 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38918 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38919 fi 38920 38921 # Output is in $new_path 38922 38923 windows_path="$new_path" 38924 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38925 unix_path=`$CYGPATH -u "$windows_path"` 38926 new_path="$unix_path" 38927 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38928 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38929 new_path="$unix_path" 38930 fi 38931 38932 # remove trailing .exe if any 38933 new_path="${new_path/%.exe/}" 38934 38935 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38936 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38937 fi 38938 38939 else 38940 # We're on a unix platform. Hooray! :) 38941 # First separate the path from the arguments. This will split at the first 38942 # space. 38943 complete="$AR" 38944 path="${complete%% *}" 38945 tmp="$complete EOL" 38946 arguments="${tmp#* }" 38947 38948 # Cannot rely on the command "which" here since it doesn't always work. 38949 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38950 if test -z "$is_absolute_path"; then 38951 # Path to executable is not absolute. Find it. 38952 IFS_save="$IFS" 38953 IFS=: 38954 for p in $PATH; do 38955 if test -f "$p/$path" && test -x "$p/$path"; then 38956 new_path="$p/$path" 38957 break 38958 fi 38959 done 38960 IFS="$IFS_save" 38961 else 38962 # This is an absolute path, we can use it without further modifications. 38963 new_path="$path" 38964 fi 38965 38966 if test "x$new_path" = x; then 38967 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38968 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38969 has_space=`$ECHO "$complete" | $GREP " "` 38970 if test "x$has_space" != x; then 38971 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38972 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38973 fi 38974 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38975 fi 38976 fi 38977 38978 # Now join together the path and the arguments once again 38979 if test "x$arguments" != xEOL; then 38980 new_complete="$new_path ${arguments% *}" 38981 else 38982 new_complete="$new_path" 38983 fi 38984 38985 if test "x$complete" != "x$new_complete"; then 38986 AR="$new_complete" 38987 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5 38988 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;} 38989 fi 38990 fi 38991 38992 38993 38994 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 38995 38996 38997 # Publish this variable in the help. 38998 38999 39000 if [ -z "${LIPO+x}" ]; then 39001 # The variable is not set by user, try to locate tool using the code snippet 39002 for ac_prog in lipo 39003 do 39004 # Extract the first word of "$ac_prog", so it can be a program name with args. 39005 set dummy $ac_prog; ac_word=$2 39006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39007 $as_echo_n "checking for $ac_word... " >&6; } 39008 if ${ac_cv_path_LIPO+:} false; then : 39009 $as_echo_n "(cached) " >&6 39010 else 39011 case $LIPO in 39012 [\\/]* | ?:[\\/]*) 39013 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 39014 ;; 39015 *) 39016 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39017 for as_dir in $PATH 39018 do 39019 IFS=$as_save_IFS 39020 test -z "$as_dir" && as_dir=. 39021 for ac_exec_ext in '' $ac_executable_extensions; do 39022 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39023 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 39024 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39025 break 2 39026 fi 39027 done 39028 done 39029 IFS=$as_save_IFS 39030 39031 ;; 39032 esac 39033 fi 39034 LIPO=$ac_cv_path_LIPO 39035 if test -n "$LIPO"; then 39036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 39037 $as_echo "$LIPO" >&6; } 39038 else 39039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39040 $as_echo "no" >&6; } 39041 fi 39042 39043 39044 test -n "$LIPO" && break 39045 done 39046 39047 else 39048 # The variable is set, but is it from the command line or the environment? 39049 39050 # Try to remove the string !LIPO! from our list. 39051 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/} 39052 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 39053 # If it failed, the variable was not from the command line. Ignore it, 39054 # but warn the user (except for BASH, which is always set by the calling BASH). 39055 if test "xLIPO" != xBASH; then 39056 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5 39057 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;} 39058 fi 39059 # Try to locate tool using the code snippet 39060 for ac_prog in lipo 39061 do 39062 # Extract the first word of "$ac_prog", so it can be a program name with args. 39063 set dummy $ac_prog; ac_word=$2 39064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39065 $as_echo_n "checking for $ac_word... " >&6; } 39066 if ${ac_cv_path_LIPO+:} false; then : 39067 $as_echo_n "(cached) " >&6 39068 else 39069 case $LIPO in 39070 [\\/]* | ?:[\\/]*) 39071 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 39072 ;; 39073 *) 39074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39075 for as_dir in $PATH 39076 do 39077 IFS=$as_save_IFS 39078 test -z "$as_dir" && as_dir=. 39079 for ac_exec_ext in '' $ac_executable_extensions; do 39080 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39081 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 39082 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39083 break 2 39084 fi 39085 done 39086 done 39087 IFS=$as_save_IFS 39088 39089 ;; 39090 esac 39091 fi 39092 LIPO=$ac_cv_path_LIPO 39093 if test -n "$LIPO"; then 39094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 39095 $as_echo "$LIPO" >&6; } 39096 else 39097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39098 $as_echo "no" >&6; } 39099 fi 39100 39101 39102 test -n "$LIPO" && break 39103 done 39104 39105 else 39106 # If it succeeded, then it was overridden by the user. We will use it 39107 # for the tool. 39108 39109 # First remove it from the list of overridden variables, so we can test 39110 # for unknown variables in the end. 39111 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 39112 39113 # Check if we try to supply an empty value 39114 if test "x$LIPO" = x; then 39115 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LIPO= (no value)" >&5 39116 $as_echo "$as_me: Setting user supplied tool LIPO= (no value)" >&6;} 39117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 39118 $as_echo_n "checking for LIPO... " >&6; } 39119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 39120 $as_echo "disabled" >&6; } 39121 else 39122 # Check if the provided tool contains a complete path. 39123 tool_specified="$LIPO" 39124 tool_basename="${tool_specified##*/}" 39125 if test "x$tool_basename" = "x$tool_specified"; then 39126 # A command without a complete path is provided, search $PATH. 39127 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5 39128 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;} 39129 # Extract the first word of "$tool_basename", so it can be a program name with args. 39130 set dummy $tool_basename; ac_word=$2 39131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39132 $as_echo_n "checking for $ac_word... " >&6; } 39133 if ${ac_cv_path_LIPO+:} false; then : 39134 $as_echo_n "(cached) " >&6 39135 else 39136 case $LIPO in 39137 [\\/]* | ?:[\\/]*) 39138 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 39139 ;; 39140 *) 39141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39142 for as_dir in $PATH 39143 do 39144 IFS=$as_save_IFS 39145 test -z "$as_dir" && as_dir=. 39146 for ac_exec_ext in '' $ac_executable_extensions; do 39147 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39148 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 39149 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39150 break 2 39151 fi 39152 done 39153 done 39154 IFS=$as_save_IFS 39155 39156 ;; 39157 esac 39158 fi 39159 LIPO=$ac_cv_path_LIPO 39160 if test -n "$LIPO"; then 39161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 39162 $as_echo "$LIPO" >&6; } 39163 else 39164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39165 $as_echo "no" >&6; } 39166 fi 39167 39168 39169 if test "x$LIPO" = x; then 39170 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 39171 fi 39172 else 39173 # Otherwise we believe it is a complete path. Use it as it is. 39174 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5 39175 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;} 39176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 39177 $as_echo_n "checking for LIPO... " >&6; } 39178 if test ! -x "$tool_specified"; then 39179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 39180 $as_echo "not found" >&6; } 39181 as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5 39182 fi 39183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 39184 $as_echo "$tool_specified" >&6; } 39185 fi 39186 fi 39187 fi 39188 39189 fi 39190 39191 39192 39193 # Only process if variable expands to non-empty 39194 39195 if test "x$LIPO" != x; then 39196 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39197 39198 # First separate the path from the arguments. This will split at the first 39199 # space. 39200 complete="$LIPO" 39201 path="${complete%% *}" 39202 tmp="$complete EOL" 39203 arguments="${tmp#* }" 39204 39205 # Input might be given as Windows format, start by converting to 39206 # unix format. 39207 new_path=`$CYGPATH -u "$path"` 39208 39209 # Now try to locate executable using which 39210 new_path=`$WHICH "$new_path" 2> /dev/null` 39211 # bat and cmd files are not always considered executable in cygwin causing which 39212 # to not find them 39213 if test "x$new_path" = x \ 39214 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39215 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39216 new_path=`$CYGPATH -u "$path"` 39217 fi 39218 if test "x$new_path" = x; then 39219 # Oops. Which didn't find the executable. 39220 # The splitting of arguments from the executable at a space might have been incorrect, 39221 # since paths with space are more likely in Windows. Give it another try with the whole 39222 # argument. 39223 path="$complete" 39224 arguments="EOL" 39225 new_path=`$CYGPATH -u "$path"` 39226 new_path=`$WHICH "$new_path" 2> /dev/null` 39227 # bat and cmd files are not always considered executable in cygwin causing which 39228 # to not find them 39229 if test "x$new_path" = x \ 39230 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39231 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39232 new_path=`$CYGPATH -u "$path"` 39233 fi 39234 if test "x$new_path" = x; then 39235 # It's still not found. Now this is an unrecoverable error. 39236 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 39237 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 39238 has_space=`$ECHO "$complete" | $GREP " "` 39239 if test "x$has_space" != x; then 39240 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39241 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39242 fi 39243 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39244 fi 39245 fi 39246 39247 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39248 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39249 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39250 # "foo.exe" is OK but "foo" is an error. 39251 # 39252 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39253 # It is also a way to make sure we got the proper file name for the real test later on. 39254 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39255 if test "x$test_shortpath" = x; then 39256 # Short path failed, file does not exist as specified. 39257 # Try adding .exe or .cmd 39258 if test -f "${new_path}.exe"; then 39259 input_to_shortpath="${new_path}.exe" 39260 elif test -f "${new_path}.cmd"; then 39261 input_to_shortpath="${new_path}.cmd" 39262 else 39263 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5 39264 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;} 39265 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39266 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39267 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39268 fi 39269 else 39270 input_to_shortpath="$new_path" 39271 fi 39272 39273 # Call helper function which possibly converts this using DOS-style short mode. 39274 # If so, the updated path is stored in $new_path. 39275 new_path="$input_to_shortpath" 39276 39277 input_path="$input_to_shortpath" 39278 # Check if we need to convert this using DOS-style short mode. If the path 39279 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39280 # take no chances and rewrite it. 39281 # Note: m4 eats our [], so we need to use [ and ] instead. 39282 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39283 if test "x$has_forbidden_chars" != x; then 39284 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39285 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39286 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39287 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39288 # Going to short mode and back again did indeed matter. Since short mode is 39289 # case insensitive, let's make it lowercase to improve readability. 39290 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39291 # Now convert it back to Unix-style (cygpath) 39292 input_path=`$CYGPATH -u "$shortmode_path"` 39293 new_path="$input_path" 39294 fi 39295 fi 39296 39297 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39298 if test "x$test_cygdrive_prefix" = x; then 39299 # As a simple fix, exclude /usr/bin since it's not a real path. 39300 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39301 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39302 # a path prefixed by /cygdrive for fixpath to work. 39303 new_path="$CYGWIN_ROOT_PATH$input_path" 39304 fi 39305 fi 39306 39307 # remove trailing .exe if any 39308 new_path="${new_path/%.exe/}" 39309 39310 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39311 39312 # First separate the path from the arguments. This will split at the first 39313 # space. 39314 complete="$LIPO" 39315 path="${complete%% *}" 39316 tmp="$complete EOL" 39317 arguments="${tmp#* }" 39318 39319 # Input might be given as Windows format, start by converting to 39320 # unix format. 39321 new_path="$path" 39322 39323 windows_path="$new_path" 39324 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39325 unix_path=`$CYGPATH -u "$windows_path"` 39326 new_path="$unix_path" 39327 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39328 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39329 new_path="$unix_path" 39330 fi 39331 39332 39333 # Now try to locate executable using which 39334 new_path=`$WHICH "$new_path" 2> /dev/null` 39335 39336 if test "x$new_path" = x; then 39337 # Oops. Which didn't find the executable. 39338 # The splitting of arguments from the executable at a space might have been incorrect, 39339 # since paths with space are more likely in Windows. Give it another try with the whole 39340 # argument. 39341 path="$complete" 39342 arguments="EOL" 39343 new_path="$path" 39344 39345 windows_path="$new_path" 39346 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39347 unix_path=`$CYGPATH -u "$windows_path"` 39348 new_path="$unix_path" 39349 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39350 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39351 new_path="$unix_path" 39352 fi 39353 39354 39355 new_path=`$WHICH "$new_path" 2> /dev/null` 39356 # bat and cmd files are not always considered executable in MSYS causing which 39357 # to not find them 39358 if test "x$new_path" = x \ 39359 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39360 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39361 new_path="$path" 39362 39363 windows_path="$new_path" 39364 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39365 unix_path=`$CYGPATH -u "$windows_path"` 39366 new_path="$unix_path" 39367 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39368 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39369 new_path="$unix_path" 39370 fi 39371 39372 fi 39373 39374 if test "x$new_path" = x; then 39375 # It's still not found. Now this is an unrecoverable error. 39376 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 39377 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 39378 has_space=`$ECHO "$complete" | $GREP " "` 39379 if test "x$has_space" != x; then 39380 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39381 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39382 fi 39383 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39384 fi 39385 fi 39386 39387 # Now new_path has a complete unix path to the binary 39388 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39389 # Keep paths in /bin as-is, but remove trailing .exe if any 39390 new_path="${new_path/%.exe/}" 39391 # Do not save /bin paths to all_fixpath_prefixes! 39392 else 39393 # Not in mixed or Windows style, start by that. 39394 new_path=`cmd //c echo $new_path` 39395 39396 input_path="$new_path" 39397 # Check if we need to convert this using DOS-style short mode. If the path 39398 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39399 # take no chances and rewrite it. 39400 # Note: m4 eats our [], so we need to use [ and ] instead. 39401 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39402 if test "x$has_forbidden_chars" != x; then 39403 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39404 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39405 fi 39406 39407 # Output is in $new_path 39408 39409 windows_path="$new_path" 39410 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39411 unix_path=`$CYGPATH -u "$windows_path"` 39412 new_path="$unix_path" 39413 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39414 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39415 new_path="$unix_path" 39416 fi 39417 39418 # remove trailing .exe if any 39419 new_path="${new_path/%.exe/}" 39420 39421 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39422 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39423 fi 39424 39425 else 39426 # We're on a unix platform. Hooray! :) 39427 # First separate the path from the arguments. This will split at the first 39428 # space. 39429 complete="$LIPO" 39430 path="${complete%% *}" 39431 tmp="$complete EOL" 39432 arguments="${tmp#* }" 39433 39434 # Cannot rely on the command "which" here since it doesn't always work. 39435 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39436 if test -z "$is_absolute_path"; then 39437 # Path to executable is not absolute. Find it. 39438 IFS_save="$IFS" 39439 IFS=: 39440 for p in $PATH; do 39441 if test -f "$p/$path" && test -x "$p/$path"; then 39442 new_path="$p/$path" 39443 break 39444 fi 39445 done 39446 IFS="$IFS_save" 39447 else 39448 # This is an absolute path, we can use it without further modifications. 39449 new_path="$path" 39450 fi 39451 39452 if test "x$new_path" = x; then 39453 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 39454 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 39455 has_space=`$ECHO "$complete" | $GREP " "` 39456 if test "x$has_space" != x; then 39457 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39458 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39459 fi 39460 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39461 fi 39462 fi 39463 39464 # Now join together the path and the arguments once again 39465 if test "x$arguments" != xEOL; then 39466 new_complete="$new_path ${arguments% *}" 39467 else 39468 new_complete="$new_path" 39469 fi 39470 39471 if test "x$complete" != "x$new_complete"; then 39472 LIPO="$new_complete" 39473 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5 39474 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;} 39475 fi 39476 fi 39477 39478 fi 39479 39480 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 39481 # Extract the first word of "mt", so it can be a program name with args. 39482 set dummy mt; ac_word=$2 39483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39484 $as_echo_n "checking for $ac_word... " >&6; } 39485 if ${ac_cv_prog_MT+:} false; then : 39486 $as_echo_n "(cached) " >&6 39487 else 39488 if test -n "$MT"; then 39489 ac_cv_prog_MT="$MT" # Let the user override the test. 39490 else 39491 ac_prog_rejected=no 39492 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39493 for as_dir in $PATH 39494 do 39495 IFS=$as_save_IFS 39496 test -z "$as_dir" && as_dir=. 39497 for ac_exec_ext in '' $ac_executable_extensions; do 39498 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39499 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then 39500 ac_prog_rejected=yes 39501 continue 39502 fi 39503 ac_cv_prog_MT="mt" 39504 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39505 break 2 39506 fi 39507 done 39508 done 39509 IFS=$as_save_IFS 39510 39511 if test $ac_prog_rejected = yes; then 39512 # We found a bogon in the path, so make sure we never use it. 39513 set dummy $ac_cv_prog_MT 39514 shift 39515 if test $# != 0; then 39516 # We chose a different compiler from the bogus one. 39517 # However, it has the same basename, so the bogon will be chosen 39518 # first if we set MT to just the basename; use the full file name. 39519 shift 39520 ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@" 39521 fi 39522 fi 39523 fi 39524 fi 39525 MT=$ac_cv_prog_MT 39526 if test -n "$MT"; then 39527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 39528 $as_echo "$MT" >&6; } 39529 else 39530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39531 $as_echo "no" >&6; } 39532 fi 39533 39534 39535 39536 # Only process if variable expands to non-empty 39537 39538 if test "x$MT" != x; then 39539 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39540 39541 # First separate the path from the arguments. This will split at the first 39542 # space. 39543 complete="$MT" 39544 path="${complete%% *}" 39545 tmp="$complete EOL" 39546 arguments="${tmp#* }" 39547 39548 # Input might be given as Windows format, start by converting to 39549 # unix format. 39550 new_path=`$CYGPATH -u "$path"` 39551 39552 # Now try to locate executable using which 39553 new_path=`$WHICH "$new_path" 2> /dev/null` 39554 # bat and cmd files are not always considered executable in cygwin causing which 39555 # to not find them 39556 if test "x$new_path" = x \ 39557 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39558 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39559 new_path=`$CYGPATH -u "$path"` 39560 fi 39561 if test "x$new_path" = x; then 39562 # Oops. Which didn't find the executable. 39563 # The splitting of arguments from the executable at a space might have been incorrect, 39564 # since paths with space are more likely in Windows. Give it another try with the whole 39565 # argument. 39566 path="$complete" 39567 arguments="EOL" 39568 new_path=`$CYGPATH -u "$path"` 39569 new_path=`$WHICH "$new_path" 2> /dev/null` 39570 # bat and cmd files are not always considered executable in cygwin causing which 39571 # to not find them 39572 if test "x$new_path" = x \ 39573 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39574 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39575 new_path=`$CYGPATH -u "$path"` 39576 fi 39577 if test "x$new_path" = x; then 39578 # It's still not found. Now this is an unrecoverable error. 39579 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 39580 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 39581 has_space=`$ECHO "$complete" | $GREP " "` 39582 if test "x$has_space" != x; then 39583 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39584 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39585 fi 39586 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39587 fi 39588 fi 39589 39590 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39591 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39592 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39593 # "foo.exe" is OK but "foo" is an error. 39594 # 39595 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39596 # It is also a way to make sure we got the proper file name for the real test later on. 39597 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39598 if test "x$test_shortpath" = x; then 39599 # Short path failed, file does not exist as specified. 39600 # Try adding .exe or .cmd 39601 if test -f "${new_path}.exe"; then 39602 input_to_shortpath="${new_path}.exe" 39603 elif test -f "${new_path}.cmd"; then 39604 input_to_shortpath="${new_path}.cmd" 39605 else 39606 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5 39607 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;} 39608 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39609 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39610 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39611 fi 39612 else 39613 input_to_shortpath="$new_path" 39614 fi 39615 39616 # Call helper function which possibly converts this using DOS-style short mode. 39617 # If so, the updated path is stored in $new_path. 39618 new_path="$input_to_shortpath" 39619 39620 input_path="$input_to_shortpath" 39621 # Check if we need to convert this using DOS-style short mode. If the path 39622 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39623 # take no chances and rewrite it. 39624 # Note: m4 eats our [], so we need to use [ and ] instead. 39625 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39626 if test "x$has_forbidden_chars" != x; then 39627 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39628 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39629 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39630 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39631 # Going to short mode and back again did indeed matter. Since short mode is 39632 # case insensitive, let's make it lowercase to improve readability. 39633 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39634 # Now convert it back to Unix-style (cygpath) 39635 input_path=`$CYGPATH -u "$shortmode_path"` 39636 new_path="$input_path" 39637 fi 39638 fi 39639 39640 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39641 if test "x$test_cygdrive_prefix" = x; then 39642 # As a simple fix, exclude /usr/bin since it's not a real path. 39643 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39644 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39645 # a path prefixed by /cygdrive for fixpath to work. 39646 new_path="$CYGWIN_ROOT_PATH$input_path" 39647 fi 39648 fi 39649 39650 # remove trailing .exe if any 39651 new_path="${new_path/%.exe/}" 39652 39653 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39654 39655 # First separate the path from the arguments. This will split at the first 39656 # space. 39657 complete="$MT" 39658 path="${complete%% *}" 39659 tmp="$complete EOL" 39660 arguments="${tmp#* }" 39661 39662 # Input might be given as Windows format, start by converting to 39663 # unix format. 39664 new_path="$path" 39665 39666 windows_path="$new_path" 39667 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39668 unix_path=`$CYGPATH -u "$windows_path"` 39669 new_path="$unix_path" 39670 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39671 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39672 new_path="$unix_path" 39673 fi 39674 39675 39676 # Now try to locate executable using which 39677 new_path=`$WHICH "$new_path" 2> /dev/null` 39678 39679 if test "x$new_path" = x; then 39680 # Oops. Which didn't find the executable. 39681 # The splitting of arguments from the executable at a space might have been incorrect, 39682 # since paths with space are more likely in Windows. Give it another try with the whole 39683 # argument. 39684 path="$complete" 39685 arguments="EOL" 39686 new_path="$path" 39687 39688 windows_path="$new_path" 39689 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39690 unix_path=`$CYGPATH -u "$windows_path"` 39691 new_path="$unix_path" 39692 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39693 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39694 new_path="$unix_path" 39695 fi 39696 39697 39698 new_path=`$WHICH "$new_path" 2> /dev/null` 39699 # bat and cmd files are not always considered executable in MSYS causing which 39700 # to not find them 39701 if test "x$new_path" = x \ 39702 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39703 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39704 new_path="$path" 39705 39706 windows_path="$new_path" 39707 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39708 unix_path=`$CYGPATH -u "$windows_path"` 39709 new_path="$unix_path" 39710 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39711 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39712 new_path="$unix_path" 39713 fi 39714 39715 fi 39716 39717 if test "x$new_path" = x; then 39718 # It's still not found. Now this is an unrecoverable error. 39719 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 39720 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 39721 has_space=`$ECHO "$complete" | $GREP " "` 39722 if test "x$has_space" != x; then 39723 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39724 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39725 fi 39726 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39727 fi 39728 fi 39729 39730 # Now new_path has a complete unix path to the binary 39731 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39732 # Keep paths in /bin as-is, but remove trailing .exe if any 39733 new_path="${new_path/%.exe/}" 39734 # Do not save /bin paths to all_fixpath_prefixes! 39735 else 39736 # Not in mixed or Windows style, start by that. 39737 new_path=`cmd //c echo $new_path` 39738 39739 input_path="$new_path" 39740 # Check if we need to convert this using DOS-style short mode. If the path 39741 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39742 # take no chances and rewrite it. 39743 # Note: m4 eats our [], so we need to use [ and ] instead. 39744 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39745 if test "x$has_forbidden_chars" != x; then 39746 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39747 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39748 fi 39749 39750 # Output is in $new_path 39751 39752 windows_path="$new_path" 39753 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39754 unix_path=`$CYGPATH -u "$windows_path"` 39755 new_path="$unix_path" 39756 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39757 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39758 new_path="$unix_path" 39759 fi 39760 39761 # remove trailing .exe if any 39762 new_path="${new_path/%.exe/}" 39763 39764 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39765 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39766 fi 39767 39768 else 39769 # We're on a unix platform. Hooray! :) 39770 # First separate the path from the arguments. This will split at the first 39771 # space. 39772 complete="$MT" 39773 path="${complete%% *}" 39774 tmp="$complete EOL" 39775 arguments="${tmp#* }" 39776 39777 # Cannot rely on the command "which" here since it doesn't always work. 39778 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39779 if test -z "$is_absolute_path"; then 39780 # Path to executable is not absolute. Find it. 39781 IFS_save="$IFS" 39782 IFS=: 39783 for p in $PATH; do 39784 if test -f "$p/$path" && test -x "$p/$path"; then 39785 new_path="$p/$path" 39786 break 39787 fi 39788 done 39789 IFS="$IFS_save" 39790 else 39791 # This is an absolute path, we can use it without further modifications. 39792 new_path="$path" 39793 fi 39794 39795 if test "x$new_path" = x; then 39796 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 39797 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 39798 has_space=`$ECHO "$complete" | $GREP " "` 39799 if test "x$has_space" != x; then 39800 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39801 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39802 fi 39803 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39804 fi 39805 fi 39806 39807 # Now join together the path and the arguments once again 39808 if test "x$arguments" != xEOL; then 39809 new_complete="$new_path ${arguments% *}" 39810 else 39811 new_complete="$new_path" 39812 fi 39813 39814 if test "x$complete" != "x$new_complete"; then 39815 MT="$new_complete" 39816 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5 39817 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;} 39818 fi 39819 fi 39820 39821 # Setup the resource compiler (RC) 39822 # Extract the first word of "rc", so it can be a program name with args. 39823 set dummy rc; ac_word=$2 39824 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39825 $as_echo_n "checking for $ac_word... " >&6; } 39826 if ${ac_cv_prog_RC+:} false; then : 39827 $as_echo_n "(cached) " >&6 39828 else 39829 if test -n "$RC"; then 39830 ac_cv_prog_RC="$RC" # Let the user override the test. 39831 else 39832 ac_prog_rejected=no 39833 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39834 for as_dir in $PATH 39835 do 39836 IFS=$as_save_IFS 39837 test -z "$as_dir" && as_dir=. 39838 for ac_exec_ext in '' $ac_executable_extensions; do 39839 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39840 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then 39841 ac_prog_rejected=yes 39842 continue 39843 fi 39844 ac_cv_prog_RC="rc" 39845 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39846 break 2 39847 fi 39848 done 39849 done 39850 IFS=$as_save_IFS 39851 39852 if test $ac_prog_rejected = yes; then 39853 # We found a bogon in the path, so make sure we never use it. 39854 set dummy $ac_cv_prog_RC 39855 shift 39856 if test $# != 0; then 39857 # We chose a different compiler from the bogus one. 39858 # However, it has the same basename, so the bogon will be chosen 39859 # first if we set RC to just the basename; use the full file name. 39860 shift 39861 ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@" 39862 fi 39863 fi 39864 fi 39865 fi 39866 RC=$ac_cv_prog_RC 39867 if test -n "$RC"; then 39868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5 39869 $as_echo "$RC" >&6; } 39870 else 39871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39872 $as_echo "no" >&6; } 39873 fi 39874 39875 39876 39877 # Only process if variable expands to non-empty 39878 39879 if test "x$RC" != x; then 39880 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39881 39882 # First separate the path from the arguments. This will split at the first 39883 # space. 39884 complete="$RC" 39885 path="${complete%% *}" 39886 tmp="$complete EOL" 39887 arguments="${tmp#* }" 39888 39889 # Input might be given as Windows format, start by converting to 39890 # unix format. 39891 new_path=`$CYGPATH -u "$path"` 39892 39893 # Now try to locate executable using which 39894 new_path=`$WHICH "$new_path" 2> /dev/null` 39895 # bat and cmd files are not always considered executable in cygwin causing which 39896 # to not find them 39897 if test "x$new_path" = x \ 39898 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39899 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39900 new_path=`$CYGPATH -u "$path"` 39901 fi 39902 if test "x$new_path" = x; then 39903 # Oops. Which didn't find the executable. 39904 # The splitting of arguments from the executable at a space might have been incorrect, 39905 # since paths with space are more likely in Windows. Give it another try with the whole 39906 # argument. 39907 path="$complete" 39908 arguments="EOL" 39909 new_path=`$CYGPATH -u "$path"` 39910 new_path=`$WHICH "$new_path" 2> /dev/null` 39911 # bat and cmd files are not always considered executable in cygwin causing which 39912 # to not find them 39913 if test "x$new_path" = x \ 39914 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39915 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39916 new_path=`$CYGPATH -u "$path"` 39917 fi 39918 if test "x$new_path" = x; then 39919 # It's still not found. Now this is an unrecoverable error. 39920 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39921 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39922 has_space=`$ECHO "$complete" | $GREP " "` 39923 if test "x$has_space" != x; then 39924 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39925 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39926 fi 39927 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39928 fi 39929 fi 39930 39931 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39932 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39933 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39934 # "foo.exe" is OK but "foo" is an error. 39935 # 39936 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39937 # It is also a way to make sure we got the proper file name for the real test later on. 39938 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39939 if test "x$test_shortpath" = x; then 39940 # Short path failed, file does not exist as specified. 39941 # Try adding .exe or .cmd 39942 if test -f "${new_path}.exe"; then 39943 input_to_shortpath="${new_path}.exe" 39944 elif test -f "${new_path}.cmd"; then 39945 input_to_shortpath="${new_path}.cmd" 39946 else 39947 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5 39948 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;} 39949 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39950 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39951 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39952 fi 39953 else 39954 input_to_shortpath="$new_path" 39955 fi 39956 39957 # Call helper function which possibly converts this using DOS-style short mode. 39958 # If so, the updated path is stored in $new_path. 39959 new_path="$input_to_shortpath" 39960 39961 input_path="$input_to_shortpath" 39962 # Check if we need to convert this using DOS-style short mode. If the path 39963 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39964 # take no chances and rewrite it. 39965 # Note: m4 eats our [], so we need to use [ and ] instead. 39966 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39967 if test "x$has_forbidden_chars" != x; then 39968 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39969 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39970 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39971 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39972 # Going to short mode and back again did indeed matter. Since short mode is 39973 # case insensitive, let's make it lowercase to improve readability. 39974 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39975 # Now convert it back to Unix-style (cygpath) 39976 input_path=`$CYGPATH -u "$shortmode_path"` 39977 new_path="$input_path" 39978 fi 39979 fi 39980 39981 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39982 if test "x$test_cygdrive_prefix" = x; then 39983 # As a simple fix, exclude /usr/bin since it's not a real path. 39984 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39985 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39986 # a path prefixed by /cygdrive for fixpath to work. 39987 new_path="$CYGWIN_ROOT_PATH$input_path" 39988 fi 39989 fi 39990 39991 # remove trailing .exe if any 39992 new_path="${new_path/%.exe/}" 39993 39994 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39995 39996 # First separate the path from the arguments. This will split at the first 39997 # space. 39998 complete="$RC" 39999 path="${complete%% *}" 40000 tmp="$complete EOL" 40001 arguments="${tmp#* }" 40002 40003 # Input might be given as Windows format, start by converting to 40004 # unix format. 40005 new_path="$path" 40006 40007 windows_path="$new_path" 40008 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40009 unix_path=`$CYGPATH -u "$windows_path"` 40010 new_path="$unix_path" 40011 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40012 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40013 new_path="$unix_path" 40014 fi 40015 40016 40017 # Now try to locate executable using which 40018 new_path=`$WHICH "$new_path" 2> /dev/null` 40019 40020 if test "x$new_path" = x; then 40021 # Oops. Which didn't find the executable. 40022 # The splitting of arguments from the executable at a space might have been incorrect, 40023 # since paths with space are more likely in Windows. Give it another try with the whole 40024 # argument. 40025 path="$complete" 40026 arguments="EOL" 40027 new_path="$path" 40028 40029 windows_path="$new_path" 40030 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40031 unix_path=`$CYGPATH -u "$windows_path"` 40032 new_path="$unix_path" 40033 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40034 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40035 new_path="$unix_path" 40036 fi 40037 40038 40039 new_path=`$WHICH "$new_path" 2> /dev/null` 40040 # bat and cmd files are not always considered executable in MSYS causing which 40041 # to not find them 40042 if test "x$new_path" = x \ 40043 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40044 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40045 new_path="$path" 40046 40047 windows_path="$new_path" 40048 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40049 unix_path=`$CYGPATH -u "$windows_path"` 40050 new_path="$unix_path" 40051 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40052 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40053 new_path="$unix_path" 40054 fi 40055 40056 fi 40057 40058 if test "x$new_path" = x; then 40059 # It's still not found. Now this is an unrecoverable error. 40060 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 40061 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 40062 has_space=`$ECHO "$complete" | $GREP " "` 40063 if test "x$has_space" != x; then 40064 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40065 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40066 fi 40067 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 40068 fi 40069 fi 40070 40071 # Now new_path has a complete unix path to the binary 40072 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40073 # Keep paths in /bin as-is, but remove trailing .exe if any 40074 new_path="${new_path/%.exe/}" 40075 # Do not save /bin paths to all_fixpath_prefixes! 40076 else 40077 # Not in mixed or Windows style, start by that. 40078 new_path=`cmd //c echo $new_path` 40079 40080 input_path="$new_path" 40081 # Check if we need to convert this using DOS-style short mode. If the path 40082 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40083 # take no chances and rewrite it. 40084 # Note: m4 eats our [], so we need to use [ and ] instead. 40085 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40086 if test "x$has_forbidden_chars" != x; then 40087 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40088 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40089 fi 40090 40091 # Output is in $new_path 40092 40093 windows_path="$new_path" 40094 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40095 unix_path=`$CYGPATH -u "$windows_path"` 40096 new_path="$unix_path" 40097 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40098 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40099 new_path="$unix_path" 40100 fi 40101 40102 # remove trailing .exe if any 40103 new_path="${new_path/%.exe/}" 40104 40105 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40106 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40107 fi 40108 40109 else 40110 # We're on a unix platform. Hooray! :) 40111 # First separate the path from the arguments. This will split at the first 40112 # space. 40113 complete="$RC" 40114 path="${complete%% *}" 40115 tmp="$complete EOL" 40116 arguments="${tmp#* }" 40117 40118 # Cannot rely on the command "which" here since it doesn't always work. 40119 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40120 if test -z "$is_absolute_path"; then 40121 # Path to executable is not absolute. Find it. 40122 IFS_save="$IFS" 40123 IFS=: 40124 for p in $PATH; do 40125 if test -f "$p/$path" && test -x "$p/$path"; then 40126 new_path="$p/$path" 40127 break 40128 fi 40129 done 40130 IFS="$IFS_save" 40131 else 40132 # This is an absolute path, we can use it without further modifications. 40133 new_path="$path" 40134 fi 40135 40136 if test "x$new_path" = x; then 40137 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 40138 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 40139 has_space=`$ECHO "$complete" | $GREP " "` 40140 if test "x$has_space" != x; then 40141 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40142 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40143 fi 40144 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 40145 fi 40146 fi 40147 40148 # Now join together the path and the arguments once again 40149 if test "x$arguments" != xEOL; then 40150 new_complete="$new_path ${arguments% *}" 40151 else 40152 new_complete="$new_path" 40153 fi 40154 40155 if test "x$complete" != "x$new_complete"; then 40156 RC="$new_complete" 40157 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5 40158 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;} 40159 fi 40160 fi 40161 40162 # Extract the first word of "dumpbin", so it can be a program name with args. 40163 set dummy dumpbin; ac_word=$2 40164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40165 $as_echo_n "checking for $ac_word... " >&6; } 40166 if ${ac_cv_prog_DUMPBIN+:} false; then : 40167 $as_echo_n "(cached) " >&6 40168 else 40169 if test -n "$DUMPBIN"; then 40170 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. 40171 else 40172 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40173 for as_dir in $PATH 40174 do 40175 IFS=$as_save_IFS 40176 test -z "$as_dir" && as_dir=. 40177 for ac_exec_ext in '' $ac_executable_extensions; do 40178 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40179 ac_cv_prog_DUMPBIN="dumpbin" 40180 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40181 break 2 40182 fi 40183 done 40184 done 40185 IFS=$as_save_IFS 40186 40187 fi 40188 fi 40189 DUMPBIN=$ac_cv_prog_DUMPBIN 40190 if test -n "$DUMPBIN"; then 40191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 40192 $as_echo "$DUMPBIN" >&6; } 40193 else 40194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40195 $as_echo "no" >&6; } 40196 fi 40197 40198 40199 40200 # Only process if variable expands to non-empty 40201 40202 if test "x$DUMPBIN" != x; then 40203 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40204 40205 # First separate the path from the arguments. This will split at the first 40206 # space. 40207 complete="$DUMPBIN" 40208 path="${complete%% *}" 40209 tmp="$complete EOL" 40210 arguments="${tmp#* }" 40211 40212 # Input might be given as Windows format, start by converting to 40213 # unix format. 40214 new_path=`$CYGPATH -u "$path"` 40215 40216 # Now try to locate executable using which 40217 new_path=`$WHICH "$new_path" 2> /dev/null` 40218 # bat and cmd files are not always considered executable in cygwin causing which 40219 # to not find them 40220 if test "x$new_path" = x \ 40221 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40222 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40223 new_path=`$CYGPATH -u "$path"` 40224 fi 40225 if test "x$new_path" = x; then 40226 # Oops. Which didn't find the executable. 40227 # The splitting of arguments from the executable at a space might have been incorrect, 40228 # since paths with space are more likely in Windows. Give it another try with the whole 40229 # argument. 40230 path="$complete" 40231 arguments="EOL" 40232 new_path=`$CYGPATH -u "$path"` 40233 new_path=`$WHICH "$new_path" 2> /dev/null` 40234 # bat and cmd files are not always considered executable in cygwin causing which 40235 # to not find them 40236 if test "x$new_path" = x \ 40237 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40238 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40239 new_path=`$CYGPATH -u "$path"` 40240 fi 40241 if test "x$new_path" = x; then 40242 # It's still not found. Now this is an unrecoverable error. 40243 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 40244 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 40245 has_space=`$ECHO "$complete" | $GREP " "` 40246 if test "x$has_space" != x; then 40247 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40248 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40249 fi 40250 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 40251 fi 40252 fi 40253 40254 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40255 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40256 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40257 # "foo.exe" is OK but "foo" is an error. 40258 # 40259 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40260 # It is also a way to make sure we got the proper file name for the real test later on. 40261 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40262 if test "x$test_shortpath" = x; then 40263 # Short path failed, file does not exist as specified. 40264 # Try adding .exe or .cmd 40265 if test -f "${new_path}.exe"; then 40266 input_to_shortpath="${new_path}.exe" 40267 elif test -f "${new_path}.cmd"; then 40268 input_to_shortpath="${new_path}.cmd" 40269 else 40270 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5 40271 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;} 40272 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40273 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40274 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 40275 fi 40276 else 40277 input_to_shortpath="$new_path" 40278 fi 40279 40280 # Call helper function which possibly converts this using DOS-style short mode. 40281 # If so, the updated path is stored in $new_path. 40282 new_path="$input_to_shortpath" 40283 40284 input_path="$input_to_shortpath" 40285 # Check if we need to convert this using DOS-style short mode. If the path 40286 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40287 # take no chances and rewrite it. 40288 # Note: m4 eats our [], so we need to use [ and ] instead. 40289 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40290 if test "x$has_forbidden_chars" != x; then 40291 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40292 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40293 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40294 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40295 # Going to short mode and back again did indeed matter. Since short mode is 40296 # case insensitive, let's make it lowercase to improve readability. 40297 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40298 # Now convert it back to Unix-style (cygpath) 40299 input_path=`$CYGPATH -u "$shortmode_path"` 40300 new_path="$input_path" 40301 fi 40302 fi 40303 40304 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40305 if test "x$test_cygdrive_prefix" = x; then 40306 # As a simple fix, exclude /usr/bin since it's not a real path. 40307 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40308 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40309 # a path prefixed by /cygdrive for fixpath to work. 40310 new_path="$CYGWIN_ROOT_PATH$input_path" 40311 fi 40312 fi 40313 40314 # remove trailing .exe if any 40315 new_path="${new_path/%.exe/}" 40316 40317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40318 40319 # First separate the path from the arguments. This will split at the first 40320 # space. 40321 complete="$DUMPBIN" 40322 path="${complete%% *}" 40323 tmp="$complete EOL" 40324 arguments="${tmp#* }" 40325 40326 # Input might be given as Windows format, start by converting to 40327 # unix format. 40328 new_path="$path" 40329 40330 windows_path="$new_path" 40331 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40332 unix_path=`$CYGPATH -u "$windows_path"` 40333 new_path="$unix_path" 40334 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40335 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40336 new_path="$unix_path" 40337 fi 40338 40339 40340 # Now try to locate executable using which 40341 new_path=`$WHICH "$new_path" 2> /dev/null` 40342 40343 if test "x$new_path" = x; then 40344 # Oops. Which didn't find the executable. 40345 # The splitting of arguments from the executable at a space might have been incorrect, 40346 # since paths with space are more likely in Windows. Give it another try with the whole 40347 # argument. 40348 path="$complete" 40349 arguments="EOL" 40350 new_path="$path" 40351 40352 windows_path="$new_path" 40353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40354 unix_path=`$CYGPATH -u "$windows_path"` 40355 new_path="$unix_path" 40356 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40357 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40358 new_path="$unix_path" 40359 fi 40360 40361 40362 new_path=`$WHICH "$new_path" 2> /dev/null` 40363 # bat and cmd files are not always considered executable in MSYS causing which 40364 # to not find them 40365 if test "x$new_path" = x \ 40366 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40367 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40368 new_path="$path" 40369 40370 windows_path="$new_path" 40371 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40372 unix_path=`$CYGPATH -u "$windows_path"` 40373 new_path="$unix_path" 40374 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40375 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40376 new_path="$unix_path" 40377 fi 40378 40379 fi 40380 40381 if test "x$new_path" = x; then 40382 # It's still not found. Now this is an unrecoverable error. 40383 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 40384 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 40385 has_space=`$ECHO "$complete" | $GREP " "` 40386 if test "x$has_space" != x; then 40387 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40388 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40389 fi 40390 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 40391 fi 40392 fi 40393 40394 # Now new_path has a complete unix path to the binary 40395 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40396 # Keep paths in /bin as-is, but remove trailing .exe if any 40397 new_path="${new_path/%.exe/}" 40398 # Do not save /bin paths to all_fixpath_prefixes! 40399 else 40400 # Not in mixed or Windows style, start by that. 40401 new_path=`cmd //c echo $new_path` 40402 40403 input_path="$new_path" 40404 # Check if we need to convert this using DOS-style short mode. If the path 40405 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40406 # take no chances and rewrite it. 40407 # Note: m4 eats our [], so we need to use [ and ] instead. 40408 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40409 if test "x$has_forbidden_chars" != x; then 40410 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40411 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40412 fi 40413 40414 # Output is in $new_path 40415 40416 windows_path="$new_path" 40417 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40418 unix_path=`$CYGPATH -u "$windows_path"` 40419 new_path="$unix_path" 40420 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40421 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40422 new_path="$unix_path" 40423 fi 40424 40425 # remove trailing .exe if any 40426 new_path="${new_path/%.exe/}" 40427 40428 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40429 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40430 fi 40431 40432 else 40433 # We're on a unix platform. Hooray! :) 40434 # First separate the path from the arguments. This will split at the first 40435 # space. 40436 complete="$DUMPBIN" 40437 path="${complete%% *}" 40438 tmp="$complete EOL" 40439 arguments="${tmp#* }" 40440 40441 # Cannot rely on the command "which" here since it doesn't always work. 40442 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40443 if test -z "$is_absolute_path"; then 40444 # Path to executable is not absolute. Find it. 40445 IFS_save="$IFS" 40446 IFS=: 40447 for p in $PATH; do 40448 if test -f "$p/$path" && test -x "$p/$path"; then 40449 new_path="$p/$path" 40450 break 40451 fi 40452 done 40453 IFS="$IFS_save" 40454 else 40455 # This is an absolute path, we can use it without further modifications. 40456 new_path="$path" 40457 fi 40458 40459 if test "x$new_path" = x; then 40460 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 40461 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 40462 has_space=`$ECHO "$complete" | $GREP " "` 40463 if test "x$has_space" != x; then 40464 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40465 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40466 fi 40467 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 40468 fi 40469 fi 40470 40471 # Now join together the path and the arguments once again 40472 if test "x$arguments" != xEOL; then 40473 new_complete="$new_path ${arguments% *}" 40474 else 40475 new_complete="$new_path" 40476 fi 40477 40478 if test "x$complete" != "x$new_complete"; then 40479 DUMPBIN="$new_complete" 40480 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5 40481 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;} 40482 fi 40483 fi 40484 40485 # We need to check for 'msbuild.exe' because at the place where we expect to 40486 # find 'msbuild.exe' there's also a directory called 'msbuild' and configure 40487 # won't find the 'msbuild.exe' executable in that case (and the 40488 # 'ac_executable_extensions' is unusable due to performance reasons). 40489 # Notice that we intentionally don't fix up the path to MSBUILD because we 40490 # will call it in a DOS shell during freetype detection on Windows (see 40491 # 'LIB_SETUP_FREETYPE' in "libraries.m4" 40492 # Extract the first word of "msbuild.exe", so it can be a program name with args. 40493 set dummy msbuild.exe; ac_word=$2 40494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40495 $as_echo_n "checking for $ac_word... " >&6; } 40496 if ${ac_cv_prog_MSBUILD+:} false; then : 40497 $as_echo_n "(cached) " >&6 40498 else 40499 if test -n "$MSBUILD"; then 40500 ac_cv_prog_MSBUILD="$MSBUILD" # Let the user override the test. 40501 else 40502 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40503 for as_dir in $PATH 40504 do 40505 IFS=$as_save_IFS 40506 test -z "$as_dir" && as_dir=. 40507 for ac_exec_ext in '' $ac_executable_extensions; do 40508 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40509 ac_cv_prog_MSBUILD="msbuild.exe" 40510 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40511 break 2 40512 fi 40513 done 40514 done 40515 IFS=$as_save_IFS 40516 40517 fi 40518 fi 40519 MSBUILD=$ac_cv_prog_MSBUILD 40520 if test -n "$MSBUILD"; then 40521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSBUILD" >&5 40522 $as_echo "$MSBUILD" >&6; } 40523 else 40524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40525 $as_echo "no" >&6; } 40526 fi 40527 40528 40529 fi 40530 40531 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 40532 40533 40534 # Publish this variable in the help. 40535 40536 40537 if [ -z "${STRIP+x}" ]; then 40538 # The variable is not set by user, try to locate tool using the code snippet 40539 for ac_prog in strip 40540 do 40541 # Extract the first word of "$ac_prog", so it can be a program name with args. 40542 set dummy $ac_prog; ac_word=$2 40543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40544 $as_echo_n "checking for $ac_word... " >&6; } 40545 if ${ac_cv_path_STRIP+:} false; then : 40546 $as_echo_n "(cached) " >&6 40547 else 40548 case $STRIP in 40549 [\\/]* | ?:[\\/]*) 40550 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 40551 ;; 40552 *) 40553 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40554 for as_dir in $PATH 40555 do 40556 IFS=$as_save_IFS 40557 test -z "$as_dir" && as_dir=. 40558 for ac_exec_ext in '' $ac_executable_extensions; do 40559 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40560 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 40561 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40562 break 2 40563 fi 40564 done 40565 done 40566 IFS=$as_save_IFS 40567 40568 ;; 40569 esac 40570 fi 40571 STRIP=$ac_cv_path_STRIP 40572 if test -n "$STRIP"; then 40573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40574 $as_echo "$STRIP" >&6; } 40575 else 40576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40577 $as_echo "no" >&6; } 40578 fi 40579 40580 40581 test -n "$STRIP" && break 40582 done 40583 40584 else 40585 # The variable is set, but is it from the command line or the environment? 40586 40587 # Try to remove the string !STRIP! from our list. 40588 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 40589 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40590 # If it failed, the variable was not from the command line. Ignore it, 40591 # but warn the user (except for BASH, which is always set by the calling BASH). 40592 if test "xSTRIP" != xBASH; then 40593 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 40594 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 40595 fi 40596 # Try to locate tool using the code snippet 40597 for ac_prog in strip 40598 do 40599 # Extract the first word of "$ac_prog", so it can be a program name with args. 40600 set dummy $ac_prog; ac_word=$2 40601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40602 $as_echo_n "checking for $ac_word... " >&6; } 40603 if ${ac_cv_path_STRIP+:} false; then : 40604 $as_echo_n "(cached) " >&6 40605 else 40606 case $STRIP in 40607 [\\/]* | ?:[\\/]*) 40608 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 40609 ;; 40610 *) 40611 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40612 for as_dir in $PATH 40613 do 40614 IFS=$as_save_IFS 40615 test -z "$as_dir" && as_dir=. 40616 for ac_exec_ext in '' $ac_executable_extensions; do 40617 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40618 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 40619 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40620 break 2 40621 fi 40622 done 40623 done 40624 IFS=$as_save_IFS 40625 40626 ;; 40627 esac 40628 fi 40629 STRIP=$ac_cv_path_STRIP 40630 if test -n "$STRIP"; then 40631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40632 $as_echo "$STRIP" >&6; } 40633 else 40634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40635 $as_echo "no" >&6; } 40636 fi 40637 40638 40639 test -n "$STRIP" && break 40640 done 40641 40642 else 40643 # If it succeeded, then it was overridden by the user. We will use it 40644 # for the tool. 40645 40646 # First remove it from the list of overridden variables, so we can test 40647 # for unknown variables in the end. 40648 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40649 40650 # Check if we try to supply an empty value 40651 if test "x$STRIP" = x; then 40652 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 40653 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 40654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 40655 $as_echo_n "checking for STRIP... " >&6; } 40656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40657 $as_echo "disabled" >&6; } 40658 else 40659 # Check if the provided tool contains a complete path. 40660 tool_specified="$STRIP" 40661 tool_basename="${tool_specified##*/}" 40662 if test "x$tool_basename" = "x$tool_specified"; then 40663 # A command without a complete path is provided, search $PATH. 40664 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 40665 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 40666 # Extract the first word of "$tool_basename", so it can be a program name with args. 40667 set dummy $tool_basename; ac_word=$2 40668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40669 $as_echo_n "checking for $ac_word... " >&6; } 40670 if ${ac_cv_path_STRIP+:} false; then : 40671 $as_echo_n "(cached) " >&6 40672 else 40673 case $STRIP in 40674 [\\/]* | ?:[\\/]*) 40675 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 40676 ;; 40677 *) 40678 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40679 for as_dir in $PATH 40680 do 40681 IFS=$as_save_IFS 40682 test -z "$as_dir" && as_dir=. 40683 for ac_exec_ext in '' $ac_executable_extensions; do 40684 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40685 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 40686 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40687 break 2 40688 fi 40689 done 40690 done 40691 IFS=$as_save_IFS 40692 40693 ;; 40694 esac 40695 fi 40696 STRIP=$ac_cv_path_STRIP 40697 if test -n "$STRIP"; then 40698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40699 $as_echo "$STRIP" >&6; } 40700 else 40701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40702 $as_echo "no" >&6; } 40703 fi 40704 40705 40706 if test "x$STRIP" = x; then 40707 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40708 fi 40709 else 40710 # Otherwise we believe it is a complete path. Use it as it is. 40711 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 40712 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 40713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 40714 $as_echo_n "checking for STRIP... " >&6; } 40715 if test ! -x "$tool_specified"; then 40716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40717 $as_echo "not found" >&6; } 40718 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 40719 fi 40720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40721 $as_echo "$tool_specified" >&6; } 40722 fi 40723 fi 40724 fi 40725 40726 fi 40727 40728 40729 40730 # Only process if variable expands to non-empty 40731 40732 if test "x$STRIP" != x; then 40733 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40734 40735 # First separate the path from the arguments. This will split at the first 40736 # space. 40737 complete="$STRIP" 40738 path="${complete%% *}" 40739 tmp="$complete EOL" 40740 arguments="${tmp#* }" 40741 40742 # Input might be given as Windows format, start by converting to 40743 # unix format. 40744 new_path=`$CYGPATH -u "$path"` 40745 40746 # Now try to locate executable using which 40747 new_path=`$WHICH "$new_path" 2> /dev/null` 40748 # bat and cmd files are not always considered executable in cygwin causing which 40749 # to not find them 40750 if test "x$new_path" = x \ 40751 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40752 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40753 new_path=`$CYGPATH -u "$path"` 40754 fi 40755 if test "x$new_path" = x; then 40756 # Oops. Which didn't find the executable. 40757 # The splitting of arguments from the executable at a space might have been incorrect, 40758 # since paths with space are more likely in Windows. Give it another try with the whole 40759 # argument. 40760 path="$complete" 40761 arguments="EOL" 40762 new_path=`$CYGPATH -u "$path"` 40763 new_path=`$WHICH "$new_path" 2> /dev/null` 40764 # bat and cmd files are not always considered executable in cygwin causing which 40765 # to not find them 40766 if test "x$new_path" = x \ 40767 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40768 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40769 new_path=`$CYGPATH -u "$path"` 40770 fi 40771 if test "x$new_path" = x; then 40772 # It's still not found. Now this is an unrecoverable error. 40773 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40774 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40775 has_space=`$ECHO "$complete" | $GREP " "` 40776 if test "x$has_space" != x; then 40777 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40778 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40779 fi 40780 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40781 fi 40782 fi 40783 40784 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40785 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40786 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40787 # "foo.exe" is OK but "foo" is an error. 40788 # 40789 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40790 # It is also a way to make sure we got the proper file name for the real test later on. 40791 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40792 if test "x$test_shortpath" = x; then 40793 # Short path failed, file does not exist as specified. 40794 # Try adding .exe or .cmd 40795 if test -f "${new_path}.exe"; then 40796 input_to_shortpath="${new_path}.exe" 40797 elif test -f "${new_path}.cmd"; then 40798 input_to_shortpath="${new_path}.cmd" 40799 else 40800 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 40801 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 40802 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40803 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40804 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40805 fi 40806 else 40807 input_to_shortpath="$new_path" 40808 fi 40809 40810 # Call helper function which possibly converts this using DOS-style short mode. 40811 # If so, the updated path is stored in $new_path. 40812 new_path="$input_to_shortpath" 40813 40814 input_path="$input_to_shortpath" 40815 # Check if we need to convert this using DOS-style short mode. If the path 40816 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40817 # take no chances and rewrite it. 40818 # Note: m4 eats our [], so we need to use [ and ] instead. 40819 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40820 if test "x$has_forbidden_chars" != x; then 40821 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40822 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40823 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40824 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40825 # Going to short mode and back again did indeed matter. Since short mode is 40826 # case insensitive, let's make it lowercase to improve readability. 40827 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40828 # Now convert it back to Unix-style (cygpath) 40829 input_path=`$CYGPATH -u "$shortmode_path"` 40830 new_path="$input_path" 40831 fi 40832 fi 40833 40834 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40835 if test "x$test_cygdrive_prefix" = x; then 40836 # As a simple fix, exclude /usr/bin since it's not a real path. 40837 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40838 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40839 # a path prefixed by /cygdrive for fixpath to work. 40840 new_path="$CYGWIN_ROOT_PATH$input_path" 40841 fi 40842 fi 40843 40844 # remove trailing .exe if any 40845 new_path="${new_path/%.exe/}" 40846 40847 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40848 40849 # First separate the path from the arguments. This will split at the first 40850 # space. 40851 complete="$STRIP" 40852 path="${complete%% *}" 40853 tmp="$complete EOL" 40854 arguments="${tmp#* }" 40855 40856 # Input might be given as Windows format, start by converting to 40857 # unix format. 40858 new_path="$path" 40859 40860 windows_path="$new_path" 40861 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40862 unix_path=`$CYGPATH -u "$windows_path"` 40863 new_path="$unix_path" 40864 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40865 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40866 new_path="$unix_path" 40867 fi 40868 40869 40870 # Now try to locate executable using which 40871 new_path=`$WHICH "$new_path" 2> /dev/null` 40872 40873 if test "x$new_path" = x; then 40874 # Oops. Which didn't find the executable. 40875 # The splitting of arguments from the executable at a space might have been incorrect, 40876 # since paths with space are more likely in Windows. Give it another try with the whole 40877 # argument. 40878 path="$complete" 40879 arguments="EOL" 40880 new_path="$path" 40881 40882 windows_path="$new_path" 40883 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40884 unix_path=`$CYGPATH -u "$windows_path"` 40885 new_path="$unix_path" 40886 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40887 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40888 new_path="$unix_path" 40889 fi 40890 40891 40892 new_path=`$WHICH "$new_path" 2> /dev/null` 40893 # bat and cmd files are not always considered executable in MSYS causing which 40894 # to not find them 40895 if test "x$new_path" = x \ 40896 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40897 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40898 new_path="$path" 40899 40900 windows_path="$new_path" 40901 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40902 unix_path=`$CYGPATH -u "$windows_path"` 40903 new_path="$unix_path" 40904 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40905 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40906 new_path="$unix_path" 40907 fi 40908 40909 fi 40910 40911 if test "x$new_path" = x; then 40912 # It's still not found. Now this is an unrecoverable error. 40913 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40914 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40915 has_space=`$ECHO "$complete" | $GREP " "` 40916 if test "x$has_space" != x; then 40917 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40918 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40919 fi 40920 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40921 fi 40922 fi 40923 40924 # Now new_path has a complete unix path to the binary 40925 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40926 # Keep paths in /bin as-is, but remove trailing .exe if any 40927 new_path="${new_path/%.exe/}" 40928 # Do not save /bin paths to all_fixpath_prefixes! 40929 else 40930 # Not in mixed or Windows style, start by that. 40931 new_path=`cmd //c echo $new_path` 40932 40933 input_path="$new_path" 40934 # Check if we need to convert this using DOS-style short mode. If the path 40935 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40936 # take no chances and rewrite it. 40937 # Note: m4 eats our [], so we need to use [ and ] instead. 40938 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40939 if test "x$has_forbidden_chars" != x; then 40940 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40941 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40942 fi 40943 40944 # Output is in $new_path 40945 40946 windows_path="$new_path" 40947 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40948 unix_path=`$CYGPATH -u "$windows_path"` 40949 new_path="$unix_path" 40950 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40951 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40952 new_path="$unix_path" 40953 fi 40954 40955 # remove trailing .exe if any 40956 new_path="${new_path/%.exe/}" 40957 40958 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40959 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40960 fi 40961 40962 else 40963 # We're on a unix platform. Hooray! :) 40964 # First separate the path from the arguments. This will split at the first 40965 # space. 40966 complete="$STRIP" 40967 path="${complete%% *}" 40968 tmp="$complete EOL" 40969 arguments="${tmp#* }" 40970 40971 # Cannot rely on the command "which" here since it doesn't always work. 40972 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40973 if test -z "$is_absolute_path"; then 40974 # Path to executable is not absolute. Find it. 40975 IFS_save="$IFS" 40976 IFS=: 40977 for p in $PATH; do 40978 if test -f "$p/$path" && test -x "$p/$path"; then 40979 new_path="$p/$path" 40980 break 40981 fi 40982 done 40983 IFS="$IFS_save" 40984 else 40985 # This is an absolute path, we can use it without further modifications. 40986 new_path="$path" 40987 fi 40988 40989 if test "x$new_path" = x; then 40990 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40991 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40992 has_space=`$ECHO "$complete" | $GREP " "` 40993 if test "x$has_space" != x; then 40994 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40995 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40996 fi 40997 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40998 fi 40999 fi 41000 41001 # Now join together the path and the arguments once again 41002 if test "x$arguments" != xEOL; then 41003 new_complete="$new_path ${arguments% *}" 41004 else 41005 new_complete="$new_path" 41006 fi 41007 41008 if test "x$complete" != "x$new_complete"; then 41009 STRIP="$new_complete" 41010 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 41011 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 41012 fi 41013 fi 41014 41015 41016 41017 # Publish this variable in the help. 41018 41019 41020 if [ -z "${NM+x}" ]; then 41021 # The variable is not set by user, try to locate tool using the code snippet 41022 for ac_prog in nm 41023 do 41024 # Extract the first word of "$ac_prog", so it can be a program name with args. 41025 set dummy $ac_prog; ac_word=$2 41026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41027 $as_echo_n "checking for $ac_word... " >&6; } 41028 if ${ac_cv_path_NM+:} false; then : 41029 $as_echo_n "(cached) " >&6 41030 else 41031 case $NM in 41032 [\\/]* | ?:[\\/]*) 41033 ac_cv_path_NM="$NM" # Let the user override the test with a path. 41034 ;; 41035 *) 41036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41037 for as_dir in $PATH 41038 do 41039 IFS=$as_save_IFS 41040 test -z "$as_dir" && as_dir=. 41041 for ac_exec_ext in '' $ac_executable_extensions; do 41042 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41043 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 41044 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41045 break 2 41046 fi 41047 done 41048 done 41049 IFS=$as_save_IFS 41050 41051 ;; 41052 esac 41053 fi 41054 NM=$ac_cv_path_NM 41055 if test -n "$NM"; then 41056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41057 $as_echo "$NM" >&6; } 41058 else 41059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41060 $as_echo "no" >&6; } 41061 fi 41062 41063 41064 test -n "$NM" && break 41065 done 41066 41067 else 41068 # The variable is set, but is it from the command line or the environment? 41069 41070 # Try to remove the string !NM! from our list. 41071 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 41072 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41073 # If it failed, the variable was not from the command line. Ignore it, 41074 # but warn the user (except for BASH, which is always set by the calling BASH). 41075 if test "xNM" != xBASH; then 41076 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 41077 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 41078 fi 41079 # Try to locate tool using the code snippet 41080 for ac_prog in nm 41081 do 41082 # Extract the first word of "$ac_prog", so it can be a program name with args. 41083 set dummy $ac_prog; ac_word=$2 41084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41085 $as_echo_n "checking for $ac_word... " >&6; } 41086 if ${ac_cv_path_NM+:} false; then : 41087 $as_echo_n "(cached) " >&6 41088 else 41089 case $NM in 41090 [\\/]* | ?:[\\/]*) 41091 ac_cv_path_NM="$NM" # Let the user override the test with a path. 41092 ;; 41093 *) 41094 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41095 for as_dir in $PATH 41096 do 41097 IFS=$as_save_IFS 41098 test -z "$as_dir" && as_dir=. 41099 for ac_exec_ext in '' $ac_executable_extensions; do 41100 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41101 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 41102 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41103 break 2 41104 fi 41105 done 41106 done 41107 IFS=$as_save_IFS 41108 41109 ;; 41110 esac 41111 fi 41112 NM=$ac_cv_path_NM 41113 if test -n "$NM"; then 41114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41115 $as_echo "$NM" >&6; } 41116 else 41117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41118 $as_echo "no" >&6; } 41119 fi 41120 41121 41122 test -n "$NM" && break 41123 done 41124 41125 else 41126 # If it succeeded, then it was overridden by the user. We will use it 41127 # for the tool. 41128 41129 # First remove it from the list of overridden variables, so we can test 41130 # for unknown variables in the end. 41131 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41132 41133 # Check if we try to supply an empty value 41134 if test "x$NM" = x; then 41135 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 41136 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 41137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41138 $as_echo_n "checking for NM... " >&6; } 41139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41140 $as_echo "disabled" >&6; } 41141 else 41142 # Check if the provided tool contains a complete path. 41143 tool_specified="$NM" 41144 tool_basename="${tool_specified##*/}" 41145 if test "x$tool_basename" = "x$tool_specified"; then 41146 # A command without a complete path is provided, search $PATH. 41147 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 41148 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 41149 # Extract the first word of "$tool_basename", so it can be a program name with args. 41150 set dummy $tool_basename; ac_word=$2 41151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41152 $as_echo_n "checking for $ac_word... " >&6; } 41153 if ${ac_cv_path_NM+:} false; then : 41154 $as_echo_n "(cached) " >&6 41155 else 41156 case $NM in 41157 [\\/]* | ?:[\\/]*) 41158 ac_cv_path_NM="$NM" # Let the user override the test with a path. 41159 ;; 41160 *) 41161 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41162 for as_dir in $PATH 41163 do 41164 IFS=$as_save_IFS 41165 test -z "$as_dir" && as_dir=. 41166 for ac_exec_ext in '' $ac_executable_extensions; do 41167 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41168 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 41169 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41170 break 2 41171 fi 41172 done 41173 done 41174 IFS=$as_save_IFS 41175 41176 ;; 41177 esac 41178 fi 41179 NM=$ac_cv_path_NM 41180 if test -n "$NM"; then 41181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41182 $as_echo "$NM" >&6; } 41183 else 41184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41185 $as_echo "no" >&6; } 41186 fi 41187 41188 41189 if test "x$NM" = x; then 41190 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41191 fi 41192 else 41193 # Otherwise we believe it is a complete path. Use it as it is. 41194 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 41195 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 41196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41197 $as_echo_n "checking for NM... " >&6; } 41198 if test ! -x "$tool_specified"; then 41199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41200 $as_echo "not found" >&6; } 41201 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 41202 fi 41203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41204 $as_echo "$tool_specified" >&6; } 41205 fi 41206 fi 41207 fi 41208 41209 fi 41210 41211 41212 41213 # Only process if variable expands to non-empty 41214 41215 if test "x$NM" != x; then 41216 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41217 41218 # First separate the path from the arguments. This will split at the first 41219 # space. 41220 complete="$NM" 41221 path="${complete%% *}" 41222 tmp="$complete EOL" 41223 arguments="${tmp#* }" 41224 41225 # Input might be given as Windows format, start by converting to 41226 # unix format. 41227 new_path=`$CYGPATH -u "$path"` 41228 41229 # Now try to locate executable using which 41230 new_path=`$WHICH "$new_path" 2> /dev/null` 41231 # bat and cmd files are not always considered executable in cygwin causing which 41232 # to not find them 41233 if test "x$new_path" = x \ 41234 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41235 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41236 new_path=`$CYGPATH -u "$path"` 41237 fi 41238 if test "x$new_path" = x; then 41239 # Oops. Which didn't find the executable. 41240 # The splitting of arguments from the executable at a space might have been incorrect, 41241 # since paths with space are more likely in Windows. Give it another try with the whole 41242 # argument. 41243 path="$complete" 41244 arguments="EOL" 41245 new_path=`$CYGPATH -u "$path"` 41246 new_path=`$WHICH "$new_path" 2> /dev/null` 41247 # bat and cmd files are not always considered executable in cygwin causing which 41248 # to not find them 41249 if test "x$new_path" = x \ 41250 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41251 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41252 new_path=`$CYGPATH -u "$path"` 41253 fi 41254 if test "x$new_path" = x; then 41255 # It's still not found. Now this is an unrecoverable error. 41256 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 41257 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 41258 has_space=`$ECHO "$complete" | $GREP " "` 41259 if test "x$has_space" != x; then 41260 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41261 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41262 fi 41263 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41264 fi 41265 fi 41266 41267 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41268 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41269 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41270 # "foo.exe" is OK but "foo" is an error. 41271 # 41272 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41273 # It is also a way to make sure we got the proper file name for the real test later on. 41274 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41275 if test "x$test_shortpath" = x; then 41276 # Short path failed, file does not exist as specified. 41277 # Try adding .exe or .cmd 41278 if test -f "${new_path}.exe"; then 41279 input_to_shortpath="${new_path}.exe" 41280 elif test -f "${new_path}.cmd"; then 41281 input_to_shortpath="${new_path}.cmd" 41282 else 41283 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 41284 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 41285 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41286 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41287 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41288 fi 41289 else 41290 input_to_shortpath="$new_path" 41291 fi 41292 41293 # Call helper function which possibly converts this using DOS-style short mode. 41294 # If so, the updated path is stored in $new_path. 41295 new_path="$input_to_shortpath" 41296 41297 input_path="$input_to_shortpath" 41298 # Check if we need to convert this using DOS-style short mode. If the path 41299 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41300 # take no chances and rewrite it. 41301 # Note: m4 eats our [], so we need to use [ and ] instead. 41302 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41303 if test "x$has_forbidden_chars" != x; then 41304 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41305 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41306 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41307 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41308 # Going to short mode and back again did indeed matter. Since short mode is 41309 # case insensitive, let's make it lowercase to improve readability. 41310 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41311 # Now convert it back to Unix-style (cygpath) 41312 input_path=`$CYGPATH -u "$shortmode_path"` 41313 new_path="$input_path" 41314 fi 41315 fi 41316 41317 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41318 if test "x$test_cygdrive_prefix" = x; then 41319 # As a simple fix, exclude /usr/bin since it's not a real path. 41320 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41321 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41322 # a path prefixed by /cygdrive for fixpath to work. 41323 new_path="$CYGWIN_ROOT_PATH$input_path" 41324 fi 41325 fi 41326 41327 # remove trailing .exe if any 41328 new_path="${new_path/%.exe/}" 41329 41330 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41331 41332 # First separate the path from the arguments. This will split at the first 41333 # space. 41334 complete="$NM" 41335 path="${complete%% *}" 41336 tmp="$complete EOL" 41337 arguments="${tmp#* }" 41338 41339 # Input might be given as Windows format, start by converting to 41340 # unix format. 41341 new_path="$path" 41342 41343 windows_path="$new_path" 41344 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41345 unix_path=`$CYGPATH -u "$windows_path"` 41346 new_path="$unix_path" 41347 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41348 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41349 new_path="$unix_path" 41350 fi 41351 41352 41353 # Now try to locate executable using which 41354 new_path=`$WHICH "$new_path" 2> /dev/null` 41355 41356 if test "x$new_path" = x; then 41357 # Oops. Which didn't find the executable. 41358 # The splitting of arguments from the executable at a space might have been incorrect, 41359 # since paths with space are more likely in Windows. Give it another try with the whole 41360 # argument. 41361 path="$complete" 41362 arguments="EOL" 41363 new_path="$path" 41364 41365 windows_path="$new_path" 41366 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41367 unix_path=`$CYGPATH -u "$windows_path"` 41368 new_path="$unix_path" 41369 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41370 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41371 new_path="$unix_path" 41372 fi 41373 41374 41375 new_path=`$WHICH "$new_path" 2> /dev/null` 41376 # bat and cmd files are not always considered executable in MSYS causing which 41377 # to not find them 41378 if test "x$new_path" = x \ 41379 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41380 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41381 new_path="$path" 41382 41383 windows_path="$new_path" 41384 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41385 unix_path=`$CYGPATH -u "$windows_path"` 41386 new_path="$unix_path" 41387 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41388 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41389 new_path="$unix_path" 41390 fi 41391 41392 fi 41393 41394 if test "x$new_path" = x; then 41395 # It's still not found. Now this is an unrecoverable error. 41396 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 41397 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 41398 has_space=`$ECHO "$complete" | $GREP " "` 41399 if test "x$has_space" != x; then 41400 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41401 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41402 fi 41403 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41404 fi 41405 fi 41406 41407 # Now new_path has a complete unix path to the binary 41408 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41409 # Keep paths in /bin as-is, but remove trailing .exe if any 41410 new_path="${new_path/%.exe/}" 41411 # Do not save /bin paths to all_fixpath_prefixes! 41412 else 41413 # Not in mixed or Windows style, start by that. 41414 new_path=`cmd //c echo $new_path` 41415 41416 input_path="$new_path" 41417 # Check if we need to convert this using DOS-style short mode. If the path 41418 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41419 # take no chances and rewrite it. 41420 # Note: m4 eats our [], so we need to use [ and ] instead. 41421 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41422 if test "x$has_forbidden_chars" != x; then 41423 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41424 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41425 fi 41426 41427 # Output is in $new_path 41428 41429 windows_path="$new_path" 41430 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41431 unix_path=`$CYGPATH -u "$windows_path"` 41432 new_path="$unix_path" 41433 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41434 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41435 new_path="$unix_path" 41436 fi 41437 41438 # remove trailing .exe if any 41439 new_path="${new_path/%.exe/}" 41440 41441 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41442 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41443 fi 41444 41445 else 41446 # We're on a unix platform. Hooray! :) 41447 # First separate the path from the arguments. This will split at the first 41448 # space. 41449 complete="$NM" 41450 path="${complete%% *}" 41451 tmp="$complete EOL" 41452 arguments="${tmp#* }" 41453 41454 # Cannot rely on the command "which" here since it doesn't always work. 41455 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41456 if test -z "$is_absolute_path"; then 41457 # Path to executable is not absolute. Find it. 41458 IFS_save="$IFS" 41459 IFS=: 41460 for p in $PATH; do 41461 if test -f "$p/$path" && test -x "$p/$path"; then 41462 new_path="$p/$path" 41463 break 41464 fi 41465 done 41466 IFS="$IFS_save" 41467 else 41468 # This is an absolute path, we can use it without further modifications. 41469 new_path="$path" 41470 fi 41471 41472 if test "x$new_path" = x; then 41473 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 41474 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 41475 has_space=`$ECHO "$complete" | $GREP " "` 41476 if test "x$has_space" != x; then 41477 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41478 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41479 fi 41480 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41481 fi 41482 fi 41483 41484 # Now join together the path and the arguments once again 41485 if test "x$arguments" != xEOL; then 41486 new_complete="$new_path ${arguments% *}" 41487 else 41488 new_complete="$new_path" 41489 fi 41490 41491 if test "x$complete" != "x$new_complete"; then 41492 NM="$new_complete" 41493 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 41494 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 41495 fi 41496 fi 41497 41498 41499 41500 # Publish this variable in the help. 41501 41502 41503 if [ -z "${GNM+x}" ]; then 41504 # The variable is not set by user, try to locate tool using the code snippet 41505 for ac_prog in gnm 41506 do 41507 # Extract the first word of "$ac_prog", so it can be a program name with args. 41508 set dummy $ac_prog; ac_word=$2 41509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41510 $as_echo_n "checking for $ac_word... " >&6; } 41511 if ${ac_cv_path_GNM+:} false; then : 41512 $as_echo_n "(cached) " >&6 41513 else 41514 case $GNM in 41515 [\\/]* | ?:[\\/]*) 41516 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 41517 ;; 41518 *) 41519 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41520 for as_dir in $PATH 41521 do 41522 IFS=$as_save_IFS 41523 test -z "$as_dir" && as_dir=. 41524 for ac_exec_ext in '' $ac_executable_extensions; do 41525 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41526 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 41527 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41528 break 2 41529 fi 41530 done 41531 done 41532 IFS=$as_save_IFS 41533 41534 ;; 41535 esac 41536 fi 41537 GNM=$ac_cv_path_GNM 41538 if test -n "$GNM"; then 41539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 41540 $as_echo "$GNM" >&6; } 41541 else 41542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41543 $as_echo "no" >&6; } 41544 fi 41545 41546 41547 test -n "$GNM" && break 41548 done 41549 41550 else 41551 # The variable is set, but is it from the command line or the environment? 41552 41553 # Try to remove the string !GNM! from our list. 41554 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/} 41555 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41556 # If it failed, the variable was not from the command line. Ignore it, 41557 # but warn the user (except for BASH, which is always set by the calling BASH). 41558 if test "xGNM" != xBASH; then 41559 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5 41560 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;} 41561 fi 41562 # Try to locate tool using the code snippet 41563 for ac_prog in gnm 41564 do 41565 # Extract the first word of "$ac_prog", so it can be a program name with args. 41566 set dummy $ac_prog; ac_word=$2 41567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41568 $as_echo_n "checking for $ac_word... " >&6; } 41569 if ${ac_cv_path_GNM+:} false; then : 41570 $as_echo_n "(cached) " >&6 41571 else 41572 case $GNM in 41573 [\\/]* | ?:[\\/]*) 41574 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 41575 ;; 41576 *) 41577 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41578 for as_dir in $PATH 41579 do 41580 IFS=$as_save_IFS 41581 test -z "$as_dir" && as_dir=. 41582 for ac_exec_ext in '' $ac_executable_extensions; do 41583 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41584 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 41585 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41586 break 2 41587 fi 41588 done 41589 done 41590 IFS=$as_save_IFS 41591 41592 ;; 41593 esac 41594 fi 41595 GNM=$ac_cv_path_GNM 41596 if test -n "$GNM"; then 41597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 41598 $as_echo "$GNM" >&6; } 41599 else 41600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41601 $as_echo "no" >&6; } 41602 fi 41603 41604 41605 test -n "$GNM" && break 41606 done 41607 41608 else 41609 # If it succeeded, then it was overridden by the user. We will use it 41610 # for the tool. 41611 41612 # First remove it from the list of overridden variables, so we can test 41613 # for unknown variables in the end. 41614 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41615 41616 # Check if we try to supply an empty value 41617 if test "x$GNM" = x; then 41618 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GNM= (no value)" >&5 41619 $as_echo "$as_me: Setting user supplied tool GNM= (no value)" >&6;} 41620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 41621 $as_echo_n "checking for GNM... " >&6; } 41622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41623 $as_echo "disabled" >&6; } 41624 else 41625 # Check if the provided tool contains a complete path. 41626 tool_specified="$GNM" 41627 tool_basename="${tool_specified##*/}" 41628 if test "x$tool_basename" = "x$tool_specified"; then 41629 # A command without a complete path is provided, search $PATH. 41630 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5 41631 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;} 41632 # Extract the first word of "$tool_basename", so it can be a program name with args. 41633 set dummy $tool_basename; ac_word=$2 41634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41635 $as_echo_n "checking for $ac_word... " >&6; } 41636 if ${ac_cv_path_GNM+:} false; then : 41637 $as_echo_n "(cached) " >&6 41638 else 41639 case $GNM in 41640 [\\/]* | ?:[\\/]*) 41641 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 41642 ;; 41643 *) 41644 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41645 for as_dir in $PATH 41646 do 41647 IFS=$as_save_IFS 41648 test -z "$as_dir" && as_dir=. 41649 for ac_exec_ext in '' $ac_executable_extensions; do 41650 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41651 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 41652 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41653 break 2 41654 fi 41655 done 41656 done 41657 IFS=$as_save_IFS 41658 41659 ;; 41660 esac 41661 fi 41662 GNM=$ac_cv_path_GNM 41663 if test -n "$GNM"; then 41664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 41665 $as_echo "$GNM" >&6; } 41666 else 41667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41668 $as_echo "no" >&6; } 41669 fi 41670 41671 41672 if test "x$GNM" = x; then 41673 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41674 fi 41675 else 41676 # Otherwise we believe it is a complete path. Use it as it is. 41677 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5 41678 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;} 41679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 41680 $as_echo_n "checking for GNM... " >&6; } 41681 if test ! -x "$tool_specified"; then 41682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41683 $as_echo "not found" >&6; } 41684 as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5 41685 fi 41686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41687 $as_echo "$tool_specified" >&6; } 41688 fi 41689 fi 41690 fi 41691 41692 fi 41693 41694 41695 41696 # Only process if variable expands to non-empty 41697 41698 if test "x$GNM" != x; then 41699 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41700 41701 # First separate the path from the arguments. This will split at the first 41702 # space. 41703 complete="$GNM" 41704 path="${complete%% *}" 41705 tmp="$complete EOL" 41706 arguments="${tmp#* }" 41707 41708 # Input might be given as Windows format, start by converting to 41709 # unix format. 41710 new_path=`$CYGPATH -u "$path"` 41711 41712 # Now try to locate executable using which 41713 new_path=`$WHICH "$new_path" 2> /dev/null` 41714 # bat and cmd files are not always considered executable in cygwin causing which 41715 # to not find them 41716 if test "x$new_path" = x \ 41717 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41718 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41719 new_path=`$CYGPATH -u "$path"` 41720 fi 41721 if test "x$new_path" = x; then 41722 # Oops. Which didn't find the executable. 41723 # The splitting of arguments from the executable at a space might have been incorrect, 41724 # since paths with space are more likely in Windows. Give it another try with the whole 41725 # argument. 41726 path="$complete" 41727 arguments="EOL" 41728 new_path=`$CYGPATH -u "$path"` 41729 new_path=`$WHICH "$new_path" 2> /dev/null` 41730 # bat and cmd files are not always considered executable in cygwin causing which 41731 # to not find them 41732 if test "x$new_path" = x \ 41733 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41734 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41735 new_path=`$CYGPATH -u "$path"` 41736 fi 41737 if test "x$new_path" = x; then 41738 # It's still not found. Now this is an unrecoverable error. 41739 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 41740 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 41741 has_space=`$ECHO "$complete" | $GREP " "` 41742 if test "x$has_space" != x; then 41743 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41744 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41745 fi 41746 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41747 fi 41748 fi 41749 41750 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41751 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41752 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41753 # "foo.exe" is OK but "foo" is an error. 41754 # 41755 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41756 # It is also a way to make sure we got the proper file name for the real test later on. 41757 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41758 if test "x$test_shortpath" = x; then 41759 # Short path failed, file does not exist as specified. 41760 # Try adding .exe or .cmd 41761 if test -f "${new_path}.exe"; then 41762 input_to_shortpath="${new_path}.exe" 41763 elif test -f "${new_path}.cmd"; then 41764 input_to_shortpath="${new_path}.cmd" 41765 else 41766 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5 41767 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;} 41768 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41769 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41770 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41771 fi 41772 else 41773 input_to_shortpath="$new_path" 41774 fi 41775 41776 # Call helper function which possibly converts this using DOS-style short mode. 41777 # If so, the updated path is stored in $new_path. 41778 new_path="$input_to_shortpath" 41779 41780 input_path="$input_to_shortpath" 41781 # Check if we need to convert this using DOS-style short mode. If the path 41782 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41783 # take no chances and rewrite it. 41784 # Note: m4 eats our [], so we need to use [ and ] instead. 41785 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41786 if test "x$has_forbidden_chars" != x; then 41787 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41788 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41789 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41790 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41791 # Going to short mode and back again did indeed matter. Since short mode is 41792 # case insensitive, let's make it lowercase to improve readability. 41793 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41794 # Now convert it back to Unix-style (cygpath) 41795 input_path=`$CYGPATH -u "$shortmode_path"` 41796 new_path="$input_path" 41797 fi 41798 fi 41799 41800 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41801 if test "x$test_cygdrive_prefix" = x; then 41802 # As a simple fix, exclude /usr/bin since it's not a real path. 41803 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41804 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41805 # a path prefixed by /cygdrive for fixpath to work. 41806 new_path="$CYGWIN_ROOT_PATH$input_path" 41807 fi 41808 fi 41809 41810 # remove trailing .exe if any 41811 new_path="${new_path/%.exe/}" 41812 41813 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41814 41815 # First separate the path from the arguments. This will split at the first 41816 # space. 41817 complete="$GNM" 41818 path="${complete%% *}" 41819 tmp="$complete EOL" 41820 arguments="${tmp#* }" 41821 41822 # Input might be given as Windows format, start by converting to 41823 # unix format. 41824 new_path="$path" 41825 41826 windows_path="$new_path" 41827 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41828 unix_path=`$CYGPATH -u "$windows_path"` 41829 new_path="$unix_path" 41830 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41831 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41832 new_path="$unix_path" 41833 fi 41834 41835 41836 # Now try to locate executable using which 41837 new_path=`$WHICH "$new_path" 2> /dev/null` 41838 41839 if test "x$new_path" = x; then 41840 # Oops. Which didn't find the executable. 41841 # The splitting of arguments from the executable at a space might have been incorrect, 41842 # since paths with space are more likely in Windows. Give it another try with the whole 41843 # argument. 41844 path="$complete" 41845 arguments="EOL" 41846 new_path="$path" 41847 41848 windows_path="$new_path" 41849 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41850 unix_path=`$CYGPATH -u "$windows_path"` 41851 new_path="$unix_path" 41852 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41853 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41854 new_path="$unix_path" 41855 fi 41856 41857 41858 new_path=`$WHICH "$new_path" 2> /dev/null` 41859 # bat and cmd files are not always considered executable in MSYS causing which 41860 # to not find them 41861 if test "x$new_path" = x \ 41862 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41863 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41864 new_path="$path" 41865 41866 windows_path="$new_path" 41867 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41868 unix_path=`$CYGPATH -u "$windows_path"` 41869 new_path="$unix_path" 41870 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41871 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41872 new_path="$unix_path" 41873 fi 41874 41875 fi 41876 41877 if test "x$new_path" = x; then 41878 # It's still not found. Now this is an unrecoverable error. 41879 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 41880 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 41881 has_space=`$ECHO "$complete" | $GREP " "` 41882 if test "x$has_space" != x; then 41883 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41884 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41885 fi 41886 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41887 fi 41888 fi 41889 41890 # Now new_path has a complete unix path to the binary 41891 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41892 # Keep paths in /bin as-is, but remove trailing .exe if any 41893 new_path="${new_path/%.exe/}" 41894 # Do not save /bin paths to all_fixpath_prefixes! 41895 else 41896 # Not in mixed or Windows style, start by that. 41897 new_path=`cmd //c echo $new_path` 41898 41899 input_path="$new_path" 41900 # Check if we need to convert this using DOS-style short mode. If the path 41901 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41902 # take no chances and rewrite it. 41903 # Note: m4 eats our [], so we need to use [ and ] instead. 41904 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41905 if test "x$has_forbidden_chars" != x; then 41906 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41907 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41908 fi 41909 41910 # Output is in $new_path 41911 41912 windows_path="$new_path" 41913 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41914 unix_path=`$CYGPATH -u "$windows_path"` 41915 new_path="$unix_path" 41916 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41917 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41918 new_path="$unix_path" 41919 fi 41920 41921 # remove trailing .exe if any 41922 new_path="${new_path/%.exe/}" 41923 41924 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41925 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41926 fi 41927 41928 else 41929 # We're on a unix platform. Hooray! :) 41930 # First separate the path from the arguments. This will split at the first 41931 # space. 41932 complete="$GNM" 41933 path="${complete%% *}" 41934 tmp="$complete EOL" 41935 arguments="${tmp#* }" 41936 41937 # Cannot rely on the command "which" here since it doesn't always work. 41938 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41939 if test -z "$is_absolute_path"; then 41940 # Path to executable is not absolute. Find it. 41941 IFS_save="$IFS" 41942 IFS=: 41943 for p in $PATH; do 41944 if test -f "$p/$path" && test -x "$p/$path"; then 41945 new_path="$p/$path" 41946 break 41947 fi 41948 done 41949 IFS="$IFS_save" 41950 else 41951 # This is an absolute path, we can use it without further modifications. 41952 new_path="$path" 41953 fi 41954 41955 if test "x$new_path" = x; then 41956 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 41957 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 41958 has_space=`$ECHO "$complete" | $GREP " "` 41959 if test "x$has_space" != x; then 41960 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41961 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41962 fi 41963 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41964 fi 41965 fi 41966 41967 # Now join together the path and the arguments once again 41968 if test "x$arguments" != xEOL; then 41969 new_complete="$new_path ${arguments% *}" 41970 else 41971 new_complete="$new_path" 41972 fi 41973 41974 if test "x$complete" != "x$new_complete"; then 41975 GNM="$new_complete" 41976 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5 41977 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;} 41978 fi 41979 fi 41980 41981 elif test "x$OPENJDK_TARGET_OS" != xwindows; then 41982 # FIXME: we should unify this with the solaris case above. 41983 41984 41985 # Publish this variable in the help. 41986 41987 41988 if [ -z "${STRIP+x}" ]; then 41989 # The variable is not set by user, try to locate tool using the code snippet 41990 if test -n "$ac_tool_prefix"; then 41991 for ac_prog in strip 41992 do 41993 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41994 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41996 $as_echo_n "checking for $ac_word... " >&6; } 41997 if ${ac_cv_prog_STRIP+:} false; then : 41998 $as_echo_n "(cached) " >&6 41999 else 42000 if test -n "$STRIP"; then 42001 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 42002 else 42003 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42004 for as_dir in $PATH 42005 do 42006 IFS=$as_save_IFS 42007 test -z "$as_dir" && as_dir=. 42008 for ac_exec_ext in '' $ac_executable_extensions; do 42009 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42010 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 42011 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42012 break 2 42013 fi 42014 done 42015 done 42016 IFS=$as_save_IFS 42017 42018 fi 42019 fi 42020 STRIP=$ac_cv_prog_STRIP 42021 if test -n "$STRIP"; then 42022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 42023 $as_echo "$STRIP" >&6; } 42024 else 42025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42026 $as_echo "no" >&6; } 42027 fi 42028 42029 42030 test -n "$STRIP" && break 42031 done 42032 fi 42033 if test -z "$STRIP"; then 42034 ac_ct_STRIP=$STRIP 42035 for ac_prog in strip 42036 do 42037 # Extract the first word of "$ac_prog", so it can be a program name with args. 42038 set dummy $ac_prog; ac_word=$2 42039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42040 $as_echo_n "checking for $ac_word... " >&6; } 42041 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 42042 $as_echo_n "(cached) " >&6 42043 else 42044 if test -n "$ac_ct_STRIP"; then 42045 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 42046 else 42047 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42048 for as_dir in $PATH 42049 do 42050 IFS=$as_save_IFS 42051 test -z "$as_dir" && as_dir=. 42052 for ac_exec_ext in '' $ac_executable_extensions; do 42053 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42054 ac_cv_prog_ac_ct_STRIP="$ac_prog" 42055 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42056 break 2 42057 fi 42058 done 42059 done 42060 IFS=$as_save_IFS 42061 42062 fi 42063 fi 42064 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 42065 if test -n "$ac_ct_STRIP"; then 42066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 42067 $as_echo "$ac_ct_STRIP" >&6; } 42068 else 42069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42070 $as_echo "no" >&6; } 42071 fi 42072 42073 42074 test -n "$ac_ct_STRIP" && break 42075 done 42076 42077 if test "x$ac_ct_STRIP" = x; then 42078 STRIP="" 42079 else 42080 case $cross_compiling:$ac_tool_warned in 42081 yes:) 42082 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42083 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42084 ac_tool_warned=yes ;; 42085 esac 42086 STRIP=$ac_ct_STRIP 42087 fi 42088 fi 42089 42090 else 42091 # The variable is set, but is it from the command line or the environment? 42092 42093 # Try to remove the string !STRIP! from our list. 42094 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 42095 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42096 # If it failed, the variable was not from the command line. Ignore it, 42097 # but warn the user (except for BASH, which is always set by the calling BASH). 42098 if test "xSTRIP" != xBASH; then 42099 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 42100 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 42101 fi 42102 # Try to locate tool using the code snippet 42103 if test -n "$ac_tool_prefix"; then 42104 for ac_prog in strip 42105 do 42106 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42107 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42109 $as_echo_n "checking for $ac_word... " >&6; } 42110 if ${ac_cv_prog_STRIP+:} false; then : 42111 $as_echo_n "(cached) " >&6 42112 else 42113 if test -n "$STRIP"; then 42114 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 42115 else 42116 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42117 for as_dir in $PATH 42118 do 42119 IFS=$as_save_IFS 42120 test -z "$as_dir" && as_dir=. 42121 for ac_exec_ext in '' $ac_executable_extensions; do 42122 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42123 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 42124 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42125 break 2 42126 fi 42127 done 42128 done 42129 IFS=$as_save_IFS 42130 42131 fi 42132 fi 42133 STRIP=$ac_cv_prog_STRIP 42134 if test -n "$STRIP"; then 42135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 42136 $as_echo "$STRIP" >&6; } 42137 else 42138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42139 $as_echo "no" >&6; } 42140 fi 42141 42142 42143 test -n "$STRIP" && break 42144 done 42145 fi 42146 if test -z "$STRIP"; then 42147 ac_ct_STRIP=$STRIP 42148 for ac_prog in strip 42149 do 42150 # Extract the first word of "$ac_prog", so it can be a program name with args. 42151 set dummy $ac_prog; ac_word=$2 42152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42153 $as_echo_n "checking for $ac_word... " >&6; } 42154 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 42155 $as_echo_n "(cached) " >&6 42156 else 42157 if test -n "$ac_ct_STRIP"; then 42158 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 42159 else 42160 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42161 for as_dir in $PATH 42162 do 42163 IFS=$as_save_IFS 42164 test -z "$as_dir" && as_dir=. 42165 for ac_exec_ext in '' $ac_executable_extensions; do 42166 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42167 ac_cv_prog_ac_ct_STRIP="$ac_prog" 42168 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42169 break 2 42170 fi 42171 done 42172 done 42173 IFS=$as_save_IFS 42174 42175 fi 42176 fi 42177 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 42178 if test -n "$ac_ct_STRIP"; then 42179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 42180 $as_echo "$ac_ct_STRIP" >&6; } 42181 else 42182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42183 $as_echo "no" >&6; } 42184 fi 42185 42186 42187 test -n "$ac_ct_STRIP" && break 42188 done 42189 42190 if test "x$ac_ct_STRIP" = x; then 42191 STRIP="" 42192 else 42193 case $cross_compiling:$ac_tool_warned in 42194 yes:) 42195 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42196 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42197 ac_tool_warned=yes ;; 42198 esac 42199 STRIP=$ac_ct_STRIP 42200 fi 42201 fi 42202 42203 else 42204 # If it succeeded, then it was overridden by the user. We will use it 42205 # for the tool. 42206 42207 # First remove it from the list of overridden variables, so we can test 42208 # for unknown variables in the end. 42209 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42210 42211 # Check if we try to supply an empty value 42212 if test "x$STRIP" = x; then 42213 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 42214 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 42215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 42216 $as_echo_n "checking for STRIP... " >&6; } 42217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42218 $as_echo "disabled" >&6; } 42219 else 42220 # Check if the provided tool contains a complete path. 42221 tool_specified="$STRIP" 42222 tool_basename="${tool_specified##*/}" 42223 if test "x$tool_basename" = "x$tool_specified"; then 42224 # A command without a complete path is provided, search $PATH. 42225 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 42226 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 42227 # Extract the first word of "$tool_basename", so it can be a program name with args. 42228 set dummy $tool_basename; ac_word=$2 42229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42230 $as_echo_n "checking for $ac_word... " >&6; } 42231 if ${ac_cv_path_STRIP+:} false; then : 42232 $as_echo_n "(cached) " >&6 42233 else 42234 case $STRIP in 42235 [\\/]* | ?:[\\/]*) 42236 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 42237 ;; 42238 *) 42239 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42240 for as_dir in $PATH 42241 do 42242 IFS=$as_save_IFS 42243 test -z "$as_dir" && as_dir=. 42244 for ac_exec_ext in '' $ac_executable_extensions; do 42245 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42246 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 42247 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42248 break 2 42249 fi 42250 done 42251 done 42252 IFS=$as_save_IFS 42253 42254 ;; 42255 esac 42256 fi 42257 STRIP=$ac_cv_path_STRIP 42258 if test -n "$STRIP"; then 42259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 42260 $as_echo "$STRIP" >&6; } 42261 else 42262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42263 $as_echo "no" >&6; } 42264 fi 42265 42266 42267 if test "x$STRIP" = x; then 42268 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42269 fi 42270 else 42271 # Otherwise we believe it is a complete path. Use it as it is. 42272 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 42273 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 42274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 42275 $as_echo_n "checking for STRIP... " >&6; } 42276 if test ! -x "$tool_specified"; then 42277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42278 $as_echo "not found" >&6; } 42279 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 42280 fi 42281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42282 $as_echo "$tool_specified" >&6; } 42283 fi 42284 fi 42285 fi 42286 42287 fi 42288 42289 42290 42291 # Only process if variable expands to non-empty 42292 42293 if test "x$STRIP" != x; then 42294 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42295 42296 # First separate the path from the arguments. This will split at the first 42297 # space. 42298 complete="$STRIP" 42299 path="${complete%% *}" 42300 tmp="$complete EOL" 42301 arguments="${tmp#* }" 42302 42303 # Input might be given as Windows format, start by converting to 42304 # unix format. 42305 new_path=`$CYGPATH -u "$path"` 42306 42307 # Now try to locate executable using which 42308 new_path=`$WHICH "$new_path" 2> /dev/null` 42309 # bat and cmd files are not always considered executable in cygwin causing which 42310 # to not find them 42311 if test "x$new_path" = x \ 42312 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42313 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42314 new_path=`$CYGPATH -u "$path"` 42315 fi 42316 if test "x$new_path" = x; then 42317 # Oops. Which didn't find the executable. 42318 # The splitting of arguments from the executable at a space might have been incorrect, 42319 # since paths with space are more likely in Windows. Give it another try with the whole 42320 # argument. 42321 path="$complete" 42322 arguments="EOL" 42323 new_path=`$CYGPATH -u "$path"` 42324 new_path=`$WHICH "$new_path" 2> /dev/null` 42325 # bat and cmd files are not always considered executable in cygwin causing which 42326 # to not find them 42327 if test "x$new_path" = x \ 42328 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42329 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42330 new_path=`$CYGPATH -u "$path"` 42331 fi 42332 if test "x$new_path" = x; then 42333 # It's still not found. Now this is an unrecoverable error. 42334 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 42335 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 42336 has_space=`$ECHO "$complete" | $GREP " "` 42337 if test "x$has_space" != x; then 42338 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42339 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42340 fi 42341 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 42342 fi 42343 fi 42344 42345 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42346 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42347 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42348 # "foo.exe" is OK but "foo" is an error. 42349 # 42350 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42351 # It is also a way to make sure we got the proper file name for the real test later on. 42352 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42353 if test "x$test_shortpath" = x; then 42354 # Short path failed, file does not exist as specified. 42355 # Try adding .exe or .cmd 42356 if test -f "${new_path}.exe"; then 42357 input_to_shortpath="${new_path}.exe" 42358 elif test -f "${new_path}.cmd"; then 42359 input_to_shortpath="${new_path}.cmd" 42360 else 42361 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 42362 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 42363 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42364 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42365 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 42366 fi 42367 else 42368 input_to_shortpath="$new_path" 42369 fi 42370 42371 # Call helper function which possibly converts this using DOS-style short mode. 42372 # If so, the updated path is stored in $new_path. 42373 new_path="$input_to_shortpath" 42374 42375 input_path="$input_to_shortpath" 42376 # Check if we need to convert this using DOS-style short mode. If the path 42377 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42378 # take no chances and rewrite it. 42379 # Note: m4 eats our [], so we need to use [ and ] instead. 42380 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42381 if test "x$has_forbidden_chars" != x; then 42382 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42383 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42384 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42385 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42386 # Going to short mode and back again did indeed matter. Since short mode is 42387 # case insensitive, let's make it lowercase to improve readability. 42388 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42389 # Now convert it back to Unix-style (cygpath) 42390 input_path=`$CYGPATH -u "$shortmode_path"` 42391 new_path="$input_path" 42392 fi 42393 fi 42394 42395 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42396 if test "x$test_cygdrive_prefix" = x; then 42397 # As a simple fix, exclude /usr/bin since it's not a real path. 42398 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42399 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42400 # a path prefixed by /cygdrive for fixpath to work. 42401 new_path="$CYGWIN_ROOT_PATH$input_path" 42402 fi 42403 fi 42404 42405 # remove trailing .exe if any 42406 new_path="${new_path/%.exe/}" 42407 42408 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42409 42410 # First separate the path from the arguments. This will split at the first 42411 # space. 42412 complete="$STRIP" 42413 path="${complete%% *}" 42414 tmp="$complete EOL" 42415 arguments="${tmp#* }" 42416 42417 # Input might be given as Windows format, start by converting to 42418 # unix format. 42419 new_path="$path" 42420 42421 windows_path="$new_path" 42422 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42423 unix_path=`$CYGPATH -u "$windows_path"` 42424 new_path="$unix_path" 42425 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42426 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42427 new_path="$unix_path" 42428 fi 42429 42430 42431 # Now try to locate executable using which 42432 new_path=`$WHICH "$new_path" 2> /dev/null` 42433 42434 if test "x$new_path" = x; then 42435 # Oops. Which didn't find the executable. 42436 # The splitting of arguments from the executable at a space might have been incorrect, 42437 # since paths with space are more likely in Windows. Give it another try with the whole 42438 # argument. 42439 path="$complete" 42440 arguments="EOL" 42441 new_path="$path" 42442 42443 windows_path="$new_path" 42444 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42445 unix_path=`$CYGPATH -u "$windows_path"` 42446 new_path="$unix_path" 42447 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42448 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42449 new_path="$unix_path" 42450 fi 42451 42452 42453 new_path=`$WHICH "$new_path" 2> /dev/null` 42454 # bat and cmd files are not always considered executable in MSYS causing which 42455 # to not find them 42456 if test "x$new_path" = x \ 42457 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42458 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42459 new_path="$path" 42460 42461 windows_path="$new_path" 42462 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42463 unix_path=`$CYGPATH -u "$windows_path"` 42464 new_path="$unix_path" 42465 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42466 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42467 new_path="$unix_path" 42468 fi 42469 42470 fi 42471 42472 if test "x$new_path" = x; then 42473 # It's still not found. Now this is an unrecoverable error. 42474 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 42475 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 42476 has_space=`$ECHO "$complete" | $GREP " "` 42477 if test "x$has_space" != x; then 42478 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42479 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42480 fi 42481 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 42482 fi 42483 fi 42484 42485 # Now new_path has a complete unix path to the binary 42486 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 42487 # Keep paths in /bin as-is, but remove trailing .exe if any 42488 new_path="${new_path/%.exe/}" 42489 # Do not save /bin paths to all_fixpath_prefixes! 42490 else 42491 # Not in mixed or Windows style, start by that. 42492 new_path=`cmd //c echo $new_path` 42493 42494 input_path="$new_path" 42495 # Check if we need to convert this using DOS-style short mode. If the path 42496 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42497 # take no chances and rewrite it. 42498 # Note: m4 eats our [], so we need to use [ and ] instead. 42499 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42500 if test "x$has_forbidden_chars" != x; then 42501 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42502 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42503 fi 42504 42505 # Output is in $new_path 42506 42507 windows_path="$new_path" 42508 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42509 unix_path=`$CYGPATH -u "$windows_path"` 42510 new_path="$unix_path" 42511 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42512 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42513 new_path="$unix_path" 42514 fi 42515 42516 # remove trailing .exe if any 42517 new_path="${new_path/%.exe/}" 42518 42519 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42520 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42521 fi 42522 42523 else 42524 # We're on a unix platform. Hooray! :) 42525 # First separate the path from the arguments. This will split at the first 42526 # space. 42527 complete="$STRIP" 42528 path="${complete%% *}" 42529 tmp="$complete EOL" 42530 arguments="${tmp#* }" 42531 42532 # Cannot rely on the command "which" here since it doesn't always work. 42533 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42534 if test -z "$is_absolute_path"; then 42535 # Path to executable is not absolute. Find it. 42536 IFS_save="$IFS" 42537 IFS=: 42538 for p in $PATH; do 42539 if test -f "$p/$path" && test -x "$p/$path"; then 42540 new_path="$p/$path" 42541 break 42542 fi 42543 done 42544 IFS="$IFS_save" 42545 else 42546 # This is an absolute path, we can use it without further modifications. 42547 new_path="$path" 42548 fi 42549 42550 if test "x$new_path" = x; then 42551 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 42552 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 42553 has_space=`$ECHO "$complete" | $GREP " "` 42554 if test "x$has_space" != x; then 42555 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42556 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42557 fi 42558 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 42559 fi 42560 fi 42561 42562 # Now join together the path and the arguments once again 42563 if test "x$arguments" != xEOL; then 42564 new_complete="$new_path ${arguments% *}" 42565 else 42566 new_complete="$new_path" 42567 fi 42568 42569 if test "x$complete" != "x$new_complete"; then 42570 STRIP="$new_complete" 42571 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 42572 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 42573 fi 42574 fi 42575 42576 if test "x$TOOLCHAIN_TYPE" = xgcc; then 42577 42578 42579 # Publish this variable in the help. 42580 42581 42582 if [ -z "${NM+x}" ]; then 42583 # The variable is not set by user, try to locate tool using the code snippet 42584 if test -n "$ac_tool_prefix"; then 42585 for ac_prog in nm gcc-nm 42586 do 42587 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42588 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42590 $as_echo_n "checking for $ac_word... " >&6; } 42591 if ${ac_cv_prog_NM+:} false; then : 42592 $as_echo_n "(cached) " >&6 42593 else 42594 if test -n "$NM"; then 42595 ac_cv_prog_NM="$NM" # Let the user override the test. 42596 else 42597 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42598 for as_dir in $PATH 42599 do 42600 IFS=$as_save_IFS 42601 test -z "$as_dir" && as_dir=. 42602 for ac_exec_ext in '' $ac_executable_extensions; do 42603 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42604 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42605 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42606 break 2 42607 fi 42608 done 42609 done 42610 IFS=$as_save_IFS 42611 42612 fi 42613 fi 42614 NM=$ac_cv_prog_NM 42615 if test -n "$NM"; then 42616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42617 $as_echo "$NM" >&6; } 42618 else 42619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42620 $as_echo "no" >&6; } 42621 fi 42622 42623 42624 test -n "$NM" && break 42625 done 42626 fi 42627 if test -z "$NM"; then 42628 ac_ct_NM=$NM 42629 for ac_prog in nm gcc-nm 42630 do 42631 # Extract the first word of "$ac_prog", so it can be a program name with args. 42632 set dummy $ac_prog; ac_word=$2 42633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42634 $as_echo_n "checking for $ac_word... " >&6; } 42635 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42636 $as_echo_n "(cached) " >&6 42637 else 42638 if test -n "$ac_ct_NM"; then 42639 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42640 else 42641 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42642 for as_dir in $PATH 42643 do 42644 IFS=$as_save_IFS 42645 test -z "$as_dir" && as_dir=. 42646 for ac_exec_ext in '' $ac_executable_extensions; do 42647 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42648 ac_cv_prog_ac_ct_NM="$ac_prog" 42649 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42650 break 2 42651 fi 42652 done 42653 done 42654 IFS=$as_save_IFS 42655 42656 fi 42657 fi 42658 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42659 if test -n "$ac_ct_NM"; then 42660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42661 $as_echo "$ac_ct_NM" >&6; } 42662 else 42663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42664 $as_echo "no" >&6; } 42665 fi 42666 42667 42668 test -n "$ac_ct_NM" && break 42669 done 42670 42671 if test "x$ac_ct_NM" = x; then 42672 NM="" 42673 else 42674 case $cross_compiling:$ac_tool_warned in 42675 yes:) 42676 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42677 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42678 ac_tool_warned=yes ;; 42679 esac 42680 NM=$ac_ct_NM 42681 fi 42682 fi 42683 42684 else 42685 # The variable is set, but is it from the command line or the environment? 42686 42687 # Try to remove the string !NM! from our list. 42688 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 42689 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42690 # If it failed, the variable was not from the command line. Ignore it, 42691 # but warn the user (except for BASH, which is always set by the calling BASH). 42692 if test "xNM" != xBASH; then 42693 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 42694 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 42695 fi 42696 # Try to locate tool using the code snippet 42697 if test -n "$ac_tool_prefix"; then 42698 for ac_prog in nm gcc-nm 42699 do 42700 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42701 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42703 $as_echo_n "checking for $ac_word... " >&6; } 42704 if ${ac_cv_prog_NM+:} false; then : 42705 $as_echo_n "(cached) " >&6 42706 else 42707 if test -n "$NM"; then 42708 ac_cv_prog_NM="$NM" # Let the user override the test. 42709 else 42710 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42711 for as_dir in $PATH 42712 do 42713 IFS=$as_save_IFS 42714 test -z "$as_dir" && as_dir=. 42715 for ac_exec_ext in '' $ac_executable_extensions; do 42716 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42717 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42718 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42719 break 2 42720 fi 42721 done 42722 done 42723 IFS=$as_save_IFS 42724 42725 fi 42726 fi 42727 NM=$ac_cv_prog_NM 42728 if test -n "$NM"; then 42729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42730 $as_echo "$NM" >&6; } 42731 else 42732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42733 $as_echo "no" >&6; } 42734 fi 42735 42736 42737 test -n "$NM" && break 42738 done 42739 fi 42740 if test -z "$NM"; then 42741 ac_ct_NM=$NM 42742 for ac_prog in nm gcc-nm 42743 do 42744 # Extract the first word of "$ac_prog", so it can be a program name with args. 42745 set dummy $ac_prog; ac_word=$2 42746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42747 $as_echo_n "checking for $ac_word... " >&6; } 42748 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42749 $as_echo_n "(cached) " >&6 42750 else 42751 if test -n "$ac_ct_NM"; then 42752 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42753 else 42754 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42755 for as_dir in $PATH 42756 do 42757 IFS=$as_save_IFS 42758 test -z "$as_dir" && as_dir=. 42759 for ac_exec_ext in '' $ac_executable_extensions; do 42760 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42761 ac_cv_prog_ac_ct_NM="$ac_prog" 42762 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42763 break 2 42764 fi 42765 done 42766 done 42767 IFS=$as_save_IFS 42768 42769 fi 42770 fi 42771 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42772 if test -n "$ac_ct_NM"; then 42773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42774 $as_echo "$ac_ct_NM" >&6; } 42775 else 42776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42777 $as_echo "no" >&6; } 42778 fi 42779 42780 42781 test -n "$ac_ct_NM" && break 42782 done 42783 42784 if test "x$ac_ct_NM" = x; then 42785 NM="" 42786 else 42787 case $cross_compiling:$ac_tool_warned in 42788 yes:) 42789 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42790 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42791 ac_tool_warned=yes ;; 42792 esac 42793 NM=$ac_ct_NM 42794 fi 42795 fi 42796 42797 else 42798 # If it succeeded, then it was overridden by the user. We will use it 42799 # for the tool. 42800 42801 # First remove it from the list of overridden variables, so we can test 42802 # for unknown variables in the end. 42803 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42804 42805 # Check if we try to supply an empty value 42806 if test "x$NM" = x; then 42807 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 42808 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 42809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42810 $as_echo_n "checking for NM... " >&6; } 42811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42812 $as_echo "disabled" >&6; } 42813 else 42814 # Check if the provided tool contains a complete path. 42815 tool_specified="$NM" 42816 tool_basename="${tool_specified##*/}" 42817 if test "x$tool_basename" = "x$tool_specified"; then 42818 # A command without a complete path is provided, search $PATH. 42819 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 42820 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 42821 # Extract the first word of "$tool_basename", so it can be a program name with args. 42822 set dummy $tool_basename; ac_word=$2 42823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42824 $as_echo_n "checking for $ac_word... " >&6; } 42825 if ${ac_cv_path_NM+:} false; then : 42826 $as_echo_n "(cached) " >&6 42827 else 42828 case $NM in 42829 [\\/]* | ?:[\\/]*) 42830 ac_cv_path_NM="$NM" # Let the user override the test with a path. 42831 ;; 42832 *) 42833 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42834 for as_dir in $PATH 42835 do 42836 IFS=$as_save_IFS 42837 test -z "$as_dir" && as_dir=. 42838 for ac_exec_ext in '' $ac_executable_extensions; do 42839 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42840 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 42841 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42842 break 2 42843 fi 42844 done 42845 done 42846 IFS=$as_save_IFS 42847 42848 ;; 42849 esac 42850 fi 42851 NM=$ac_cv_path_NM 42852 if test -n "$NM"; then 42853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42854 $as_echo "$NM" >&6; } 42855 else 42856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42857 $as_echo "no" >&6; } 42858 fi 42859 42860 42861 if test "x$NM" = x; then 42862 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42863 fi 42864 else 42865 # Otherwise we believe it is a complete path. Use it as it is. 42866 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 42867 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 42868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42869 $as_echo_n "checking for NM... " >&6; } 42870 if test ! -x "$tool_specified"; then 42871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42872 $as_echo "not found" >&6; } 42873 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 42874 fi 42875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42876 $as_echo "$tool_specified" >&6; } 42877 fi 42878 fi 42879 fi 42880 42881 fi 42882 42883 42884 else 42885 42886 42887 # Publish this variable in the help. 42888 42889 42890 if [ -z "${NM+x}" ]; then 42891 # The variable is not set by user, try to locate tool using the code snippet 42892 if test -n "$ac_tool_prefix"; then 42893 for ac_prog in nm 42894 do 42895 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42896 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42898 $as_echo_n "checking for $ac_word... " >&6; } 42899 if ${ac_cv_prog_NM+:} false; then : 42900 $as_echo_n "(cached) " >&6 42901 else 42902 if test -n "$NM"; then 42903 ac_cv_prog_NM="$NM" # Let the user override the test. 42904 else 42905 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42906 for as_dir in $PATH 42907 do 42908 IFS=$as_save_IFS 42909 test -z "$as_dir" && as_dir=. 42910 for ac_exec_ext in '' $ac_executable_extensions; do 42911 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42912 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42913 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42914 break 2 42915 fi 42916 done 42917 done 42918 IFS=$as_save_IFS 42919 42920 fi 42921 fi 42922 NM=$ac_cv_prog_NM 42923 if test -n "$NM"; then 42924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42925 $as_echo "$NM" >&6; } 42926 else 42927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42928 $as_echo "no" >&6; } 42929 fi 42930 42931 42932 test -n "$NM" && break 42933 done 42934 fi 42935 if test -z "$NM"; then 42936 ac_ct_NM=$NM 42937 for ac_prog in nm 42938 do 42939 # Extract the first word of "$ac_prog", so it can be a program name with args. 42940 set dummy $ac_prog; ac_word=$2 42941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42942 $as_echo_n "checking for $ac_word... " >&6; } 42943 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42944 $as_echo_n "(cached) " >&6 42945 else 42946 if test -n "$ac_ct_NM"; then 42947 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42948 else 42949 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42950 for as_dir in $PATH 42951 do 42952 IFS=$as_save_IFS 42953 test -z "$as_dir" && as_dir=. 42954 for ac_exec_ext in '' $ac_executable_extensions; do 42955 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42956 ac_cv_prog_ac_ct_NM="$ac_prog" 42957 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42958 break 2 42959 fi 42960 done 42961 done 42962 IFS=$as_save_IFS 42963 42964 fi 42965 fi 42966 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42967 if test -n "$ac_ct_NM"; then 42968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42969 $as_echo "$ac_ct_NM" >&6; } 42970 else 42971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42972 $as_echo "no" >&6; } 42973 fi 42974 42975 42976 test -n "$ac_ct_NM" && break 42977 done 42978 42979 if test "x$ac_ct_NM" = x; then 42980 NM="" 42981 else 42982 case $cross_compiling:$ac_tool_warned in 42983 yes:) 42984 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42985 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42986 ac_tool_warned=yes ;; 42987 esac 42988 NM=$ac_ct_NM 42989 fi 42990 fi 42991 42992 else 42993 # The variable is set, but is it from the command line or the environment? 42994 42995 # Try to remove the string !NM! from our list. 42996 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 42997 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42998 # If it failed, the variable was not from the command line. Ignore it, 42999 # but warn the user (except for BASH, which is always set by the calling BASH). 43000 if test "xNM" != xBASH; then 43001 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 43002 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 43003 fi 43004 # Try to locate tool using the code snippet 43005 if test -n "$ac_tool_prefix"; then 43006 for ac_prog in nm 43007 do 43008 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43009 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43011 $as_echo_n "checking for $ac_word... " >&6; } 43012 if ${ac_cv_prog_NM+:} false; then : 43013 $as_echo_n "(cached) " >&6 43014 else 43015 if test -n "$NM"; then 43016 ac_cv_prog_NM="$NM" # Let the user override the test. 43017 else 43018 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43019 for as_dir in $PATH 43020 do 43021 IFS=$as_save_IFS 43022 test -z "$as_dir" && as_dir=. 43023 for ac_exec_ext in '' $ac_executable_extensions; do 43024 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43025 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 43026 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43027 break 2 43028 fi 43029 done 43030 done 43031 IFS=$as_save_IFS 43032 43033 fi 43034 fi 43035 NM=$ac_cv_prog_NM 43036 if test -n "$NM"; then 43037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 43038 $as_echo "$NM" >&6; } 43039 else 43040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43041 $as_echo "no" >&6; } 43042 fi 43043 43044 43045 test -n "$NM" && break 43046 done 43047 fi 43048 if test -z "$NM"; then 43049 ac_ct_NM=$NM 43050 for ac_prog in nm 43051 do 43052 # Extract the first word of "$ac_prog", so it can be a program name with args. 43053 set dummy $ac_prog; ac_word=$2 43054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43055 $as_echo_n "checking for $ac_word... " >&6; } 43056 if ${ac_cv_prog_ac_ct_NM+:} false; then : 43057 $as_echo_n "(cached) " >&6 43058 else 43059 if test -n "$ac_ct_NM"; then 43060 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 43061 else 43062 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43063 for as_dir in $PATH 43064 do 43065 IFS=$as_save_IFS 43066 test -z "$as_dir" && as_dir=. 43067 for ac_exec_ext in '' $ac_executable_extensions; do 43068 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43069 ac_cv_prog_ac_ct_NM="$ac_prog" 43070 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43071 break 2 43072 fi 43073 done 43074 done 43075 IFS=$as_save_IFS 43076 43077 fi 43078 fi 43079 ac_ct_NM=$ac_cv_prog_ac_ct_NM 43080 if test -n "$ac_ct_NM"; then 43081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 43082 $as_echo "$ac_ct_NM" >&6; } 43083 else 43084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43085 $as_echo "no" >&6; } 43086 fi 43087 43088 43089 test -n "$ac_ct_NM" && break 43090 done 43091 43092 if test "x$ac_ct_NM" = x; then 43093 NM="" 43094 else 43095 case $cross_compiling:$ac_tool_warned in 43096 yes:) 43097 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43098 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43099 ac_tool_warned=yes ;; 43100 esac 43101 NM=$ac_ct_NM 43102 fi 43103 fi 43104 43105 else 43106 # If it succeeded, then it was overridden by the user. We will use it 43107 # for the tool. 43108 43109 # First remove it from the list of overridden variables, so we can test 43110 # for unknown variables in the end. 43111 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43112 43113 # Check if we try to supply an empty value 43114 if test "x$NM" = x; then 43115 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 43116 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 43117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 43118 $as_echo_n "checking for NM... " >&6; } 43119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43120 $as_echo "disabled" >&6; } 43121 else 43122 # Check if the provided tool contains a complete path. 43123 tool_specified="$NM" 43124 tool_basename="${tool_specified##*/}" 43125 if test "x$tool_basename" = "x$tool_specified"; then 43126 # A command without a complete path is provided, search $PATH. 43127 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 43128 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 43129 # Extract the first word of "$tool_basename", so it can be a program name with args. 43130 set dummy $tool_basename; ac_word=$2 43131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43132 $as_echo_n "checking for $ac_word... " >&6; } 43133 if ${ac_cv_path_NM+:} false; then : 43134 $as_echo_n "(cached) " >&6 43135 else 43136 case $NM in 43137 [\\/]* | ?:[\\/]*) 43138 ac_cv_path_NM="$NM" # Let the user override the test with a path. 43139 ;; 43140 *) 43141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43142 for as_dir in $PATH 43143 do 43144 IFS=$as_save_IFS 43145 test -z "$as_dir" && as_dir=. 43146 for ac_exec_ext in '' $ac_executable_extensions; do 43147 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43148 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 43149 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43150 break 2 43151 fi 43152 done 43153 done 43154 IFS=$as_save_IFS 43155 43156 ;; 43157 esac 43158 fi 43159 NM=$ac_cv_path_NM 43160 if test -n "$NM"; then 43161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 43162 $as_echo "$NM" >&6; } 43163 else 43164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43165 $as_echo "no" >&6; } 43166 fi 43167 43168 43169 if test "x$NM" = x; then 43170 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43171 fi 43172 else 43173 # Otherwise we believe it is a complete path. Use it as it is. 43174 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 43175 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 43176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 43177 $as_echo_n "checking for NM... " >&6; } 43178 if test ! -x "$tool_specified"; then 43179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43180 $as_echo "not found" >&6; } 43181 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 43182 fi 43183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43184 $as_echo "$tool_specified" >&6; } 43185 fi 43186 fi 43187 fi 43188 43189 fi 43190 43191 43192 fi 43193 43194 # Only process if variable expands to non-empty 43195 43196 if test "x$NM" != x; then 43197 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43198 43199 # First separate the path from the arguments. This will split at the first 43200 # space. 43201 complete="$NM" 43202 path="${complete%% *}" 43203 tmp="$complete EOL" 43204 arguments="${tmp#* }" 43205 43206 # Input might be given as Windows format, start by converting to 43207 # unix format. 43208 new_path=`$CYGPATH -u "$path"` 43209 43210 # Now try to locate executable using which 43211 new_path=`$WHICH "$new_path" 2> /dev/null` 43212 # bat and cmd files are not always considered executable in cygwin causing which 43213 # to not find them 43214 if test "x$new_path" = x \ 43215 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43216 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43217 new_path=`$CYGPATH -u "$path"` 43218 fi 43219 if test "x$new_path" = x; then 43220 # Oops. Which didn't find the executable. 43221 # The splitting of arguments from the executable at a space might have been incorrect, 43222 # since paths with space are more likely in Windows. Give it another try with the whole 43223 # argument. 43224 path="$complete" 43225 arguments="EOL" 43226 new_path=`$CYGPATH -u "$path"` 43227 new_path=`$WHICH "$new_path" 2> /dev/null` 43228 # bat and cmd files are not always considered executable in cygwin causing which 43229 # to not find them 43230 if test "x$new_path" = x \ 43231 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43232 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43233 new_path=`$CYGPATH -u "$path"` 43234 fi 43235 if test "x$new_path" = x; then 43236 # It's still not found. Now this is an unrecoverable error. 43237 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 43238 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 43239 has_space=`$ECHO "$complete" | $GREP " "` 43240 if test "x$has_space" != x; then 43241 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43242 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43243 fi 43244 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 43245 fi 43246 fi 43247 43248 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43249 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43250 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43251 # "foo.exe" is OK but "foo" is an error. 43252 # 43253 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43254 # It is also a way to make sure we got the proper file name for the real test later on. 43255 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43256 if test "x$test_shortpath" = x; then 43257 # Short path failed, file does not exist as specified. 43258 # Try adding .exe or .cmd 43259 if test -f "${new_path}.exe"; then 43260 input_to_shortpath="${new_path}.exe" 43261 elif test -f "${new_path}.cmd"; then 43262 input_to_shortpath="${new_path}.cmd" 43263 else 43264 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 43265 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 43266 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 43267 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 43268 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 43269 fi 43270 else 43271 input_to_shortpath="$new_path" 43272 fi 43273 43274 # Call helper function which possibly converts this using DOS-style short mode. 43275 # If so, the updated path is stored in $new_path. 43276 new_path="$input_to_shortpath" 43277 43278 input_path="$input_to_shortpath" 43279 # Check if we need to convert this using DOS-style short mode. If the path 43280 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43281 # take no chances and rewrite it. 43282 # Note: m4 eats our [], so we need to use [ and ] instead. 43283 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43284 if test "x$has_forbidden_chars" != x; then 43285 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43286 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43287 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43288 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43289 # Going to short mode and back again did indeed matter. Since short mode is 43290 # case insensitive, let's make it lowercase to improve readability. 43291 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43292 # Now convert it back to Unix-style (cygpath) 43293 input_path=`$CYGPATH -u "$shortmode_path"` 43294 new_path="$input_path" 43295 fi 43296 fi 43297 43298 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43299 if test "x$test_cygdrive_prefix" = x; then 43300 # As a simple fix, exclude /usr/bin since it's not a real path. 43301 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 43302 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43303 # a path prefixed by /cygdrive for fixpath to work. 43304 new_path="$CYGWIN_ROOT_PATH$input_path" 43305 fi 43306 fi 43307 43308 # remove trailing .exe if any 43309 new_path="${new_path/%.exe/}" 43310 43311 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43312 43313 # First separate the path from the arguments. This will split at the first 43314 # space. 43315 complete="$NM" 43316 path="${complete%% *}" 43317 tmp="$complete EOL" 43318 arguments="${tmp#* }" 43319 43320 # Input might be given as Windows format, start by converting to 43321 # unix format. 43322 new_path="$path" 43323 43324 windows_path="$new_path" 43325 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43326 unix_path=`$CYGPATH -u "$windows_path"` 43327 new_path="$unix_path" 43328 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43329 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43330 new_path="$unix_path" 43331 fi 43332 43333 43334 # Now try to locate executable using which 43335 new_path=`$WHICH "$new_path" 2> /dev/null` 43336 43337 if test "x$new_path" = x; then 43338 # Oops. Which didn't find the executable. 43339 # The splitting of arguments from the executable at a space might have been incorrect, 43340 # since paths with space are more likely in Windows. Give it another try with the whole 43341 # argument. 43342 path="$complete" 43343 arguments="EOL" 43344 new_path="$path" 43345 43346 windows_path="$new_path" 43347 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43348 unix_path=`$CYGPATH -u "$windows_path"` 43349 new_path="$unix_path" 43350 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43351 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43352 new_path="$unix_path" 43353 fi 43354 43355 43356 new_path=`$WHICH "$new_path" 2> /dev/null` 43357 # bat and cmd files are not always considered executable in MSYS causing which 43358 # to not find them 43359 if test "x$new_path" = x \ 43360 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43361 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43362 new_path="$path" 43363 43364 windows_path="$new_path" 43365 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43366 unix_path=`$CYGPATH -u "$windows_path"` 43367 new_path="$unix_path" 43368 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43369 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43370 new_path="$unix_path" 43371 fi 43372 43373 fi 43374 43375 if test "x$new_path" = x; then 43376 # It's still not found. Now this is an unrecoverable error. 43377 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 43378 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 43379 has_space=`$ECHO "$complete" | $GREP " "` 43380 if test "x$has_space" != x; then 43381 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43382 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43383 fi 43384 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 43385 fi 43386 fi 43387 43388 # Now new_path has a complete unix path to the binary 43389 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43390 # Keep paths in /bin as-is, but remove trailing .exe if any 43391 new_path="${new_path/%.exe/}" 43392 # Do not save /bin paths to all_fixpath_prefixes! 43393 else 43394 # Not in mixed or Windows style, start by that. 43395 new_path=`cmd //c echo $new_path` 43396 43397 input_path="$new_path" 43398 # Check if we need to convert this using DOS-style short mode. If the path 43399 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43400 # take no chances and rewrite it. 43401 # Note: m4 eats our [], so we need to use [ and ] instead. 43402 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43403 if test "x$has_forbidden_chars" != x; then 43404 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43405 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43406 fi 43407 43408 # Output is in $new_path 43409 43410 windows_path="$new_path" 43411 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43412 unix_path=`$CYGPATH -u "$windows_path"` 43413 new_path="$unix_path" 43414 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43415 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43416 new_path="$unix_path" 43417 fi 43418 43419 # remove trailing .exe if any 43420 new_path="${new_path/%.exe/}" 43421 43422 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43423 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43424 fi 43425 43426 else 43427 # We're on a unix platform. Hooray! :) 43428 # First separate the path from the arguments. This will split at the first 43429 # space. 43430 complete="$NM" 43431 path="${complete%% *}" 43432 tmp="$complete EOL" 43433 arguments="${tmp#* }" 43434 43435 # Cannot rely on the command "which" here since it doesn't always work. 43436 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43437 if test -z "$is_absolute_path"; then 43438 # Path to executable is not absolute. Find it. 43439 IFS_save="$IFS" 43440 IFS=: 43441 for p in $PATH; do 43442 if test -f "$p/$path" && test -x "$p/$path"; then 43443 new_path="$p/$path" 43444 break 43445 fi 43446 done 43447 IFS="$IFS_save" 43448 else 43449 # This is an absolute path, we can use it without further modifications. 43450 new_path="$path" 43451 fi 43452 43453 if test "x$new_path" = x; then 43454 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 43455 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 43456 has_space=`$ECHO "$complete" | $GREP " "` 43457 if test "x$has_space" != x; then 43458 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43459 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43460 fi 43461 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 43462 fi 43463 fi 43464 43465 # Now join together the path and the arguments once again 43466 if test "x$arguments" != xEOL; then 43467 new_complete="$new_path ${arguments% *}" 43468 else 43469 new_complete="$new_path" 43470 fi 43471 43472 if test "x$complete" != "x$new_complete"; then 43473 NM="$new_complete" 43474 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 43475 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 43476 fi 43477 fi 43478 43479 GNM="$NM" 43480 43481 fi 43482 43483 # objcopy is used for moving debug symbols to separate files when 43484 # full debug symbols are enabled. 43485 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 43486 43487 43488 # Publish this variable in the help. 43489 43490 43491 if [ -z "${OBJCOPY+x}" ]; then 43492 # The variable is not set by user, try to locate tool using the code snippet 43493 if test -n "$ac_tool_prefix"; then 43494 for ac_prog in gobjcopy objcopy 43495 do 43496 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43497 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43499 $as_echo_n "checking for $ac_word... " >&6; } 43500 if ${ac_cv_prog_OBJCOPY+:} false; then : 43501 $as_echo_n "(cached) " >&6 43502 else 43503 if test -n "$OBJCOPY"; then 43504 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 43505 else 43506 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43507 for as_dir in $PATH 43508 do 43509 IFS=$as_save_IFS 43510 test -z "$as_dir" && as_dir=. 43511 for ac_exec_ext in '' $ac_executable_extensions; do 43512 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43513 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 43514 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43515 break 2 43516 fi 43517 done 43518 done 43519 IFS=$as_save_IFS 43520 43521 fi 43522 fi 43523 OBJCOPY=$ac_cv_prog_OBJCOPY 43524 if test -n "$OBJCOPY"; then 43525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 43526 $as_echo "$OBJCOPY" >&6; } 43527 else 43528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43529 $as_echo "no" >&6; } 43530 fi 43531 43532 43533 test -n "$OBJCOPY" && break 43534 done 43535 fi 43536 if test -z "$OBJCOPY"; then 43537 ac_ct_OBJCOPY=$OBJCOPY 43538 for ac_prog in gobjcopy objcopy 43539 do 43540 # Extract the first word of "$ac_prog", so it can be a program name with args. 43541 set dummy $ac_prog; ac_word=$2 43542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43543 $as_echo_n "checking for $ac_word... " >&6; } 43544 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 43545 $as_echo_n "(cached) " >&6 43546 else 43547 if test -n "$ac_ct_OBJCOPY"; then 43548 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 43549 else 43550 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43551 for as_dir in $PATH 43552 do 43553 IFS=$as_save_IFS 43554 test -z "$as_dir" && as_dir=. 43555 for ac_exec_ext in '' $ac_executable_extensions; do 43556 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43557 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 43558 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43559 break 2 43560 fi 43561 done 43562 done 43563 IFS=$as_save_IFS 43564 43565 fi 43566 fi 43567 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 43568 if test -n "$ac_ct_OBJCOPY"; then 43569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 43570 $as_echo "$ac_ct_OBJCOPY" >&6; } 43571 else 43572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43573 $as_echo "no" >&6; } 43574 fi 43575 43576 43577 test -n "$ac_ct_OBJCOPY" && break 43578 done 43579 43580 if test "x$ac_ct_OBJCOPY" = x; then 43581 OBJCOPY="" 43582 else 43583 case $cross_compiling:$ac_tool_warned in 43584 yes:) 43585 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43586 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43587 ac_tool_warned=yes ;; 43588 esac 43589 OBJCOPY=$ac_ct_OBJCOPY 43590 fi 43591 fi 43592 43593 else 43594 # The variable is set, but is it from the command line or the environment? 43595 43596 # Try to remove the string !OBJCOPY! from our list. 43597 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/} 43598 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43599 # If it failed, the variable was not from the command line. Ignore it, 43600 # but warn the user (except for BASH, which is always set by the calling BASH). 43601 if test "xOBJCOPY" != xBASH; then 43602 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5 43603 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;} 43604 fi 43605 # Try to locate tool using the code snippet 43606 if test -n "$ac_tool_prefix"; then 43607 for ac_prog in gobjcopy objcopy 43608 do 43609 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43610 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43612 $as_echo_n "checking for $ac_word... " >&6; } 43613 if ${ac_cv_prog_OBJCOPY+:} false; then : 43614 $as_echo_n "(cached) " >&6 43615 else 43616 if test -n "$OBJCOPY"; then 43617 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 43618 else 43619 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43620 for as_dir in $PATH 43621 do 43622 IFS=$as_save_IFS 43623 test -z "$as_dir" && as_dir=. 43624 for ac_exec_ext in '' $ac_executable_extensions; do 43625 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43626 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 43627 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43628 break 2 43629 fi 43630 done 43631 done 43632 IFS=$as_save_IFS 43633 43634 fi 43635 fi 43636 OBJCOPY=$ac_cv_prog_OBJCOPY 43637 if test -n "$OBJCOPY"; then 43638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 43639 $as_echo "$OBJCOPY" >&6; } 43640 else 43641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43642 $as_echo "no" >&6; } 43643 fi 43644 43645 43646 test -n "$OBJCOPY" && break 43647 done 43648 fi 43649 if test -z "$OBJCOPY"; then 43650 ac_ct_OBJCOPY=$OBJCOPY 43651 for ac_prog in gobjcopy objcopy 43652 do 43653 # Extract the first word of "$ac_prog", so it can be a program name with args. 43654 set dummy $ac_prog; ac_word=$2 43655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43656 $as_echo_n "checking for $ac_word... " >&6; } 43657 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 43658 $as_echo_n "(cached) " >&6 43659 else 43660 if test -n "$ac_ct_OBJCOPY"; then 43661 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 43662 else 43663 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43664 for as_dir in $PATH 43665 do 43666 IFS=$as_save_IFS 43667 test -z "$as_dir" && as_dir=. 43668 for ac_exec_ext in '' $ac_executable_extensions; do 43669 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43670 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 43671 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43672 break 2 43673 fi 43674 done 43675 done 43676 IFS=$as_save_IFS 43677 43678 fi 43679 fi 43680 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 43681 if test -n "$ac_ct_OBJCOPY"; then 43682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 43683 $as_echo "$ac_ct_OBJCOPY" >&6; } 43684 else 43685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43686 $as_echo "no" >&6; } 43687 fi 43688 43689 43690 test -n "$ac_ct_OBJCOPY" && break 43691 done 43692 43693 if test "x$ac_ct_OBJCOPY" = x; then 43694 OBJCOPY="" 43695 else 43696 case $cross_compiling:$ac_tool_warned in 43697 yes:) 43698 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43699 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43700 ac_tool_warned=yes ;; 43701 esac 43702 OBJCOPY=$ac_ct_OBJCOPY 43703 fi 43704 fi 43705 43706 else 43707 # If it succeeded, then it was overridden by the user. We will use it 43708 # for the tool. 43709 43710 # First remove it from the list of overridden variables, so we can test 43711 # for unknown variables in the end. 43712 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43713 43714 # Check if we try to supply an empty value 43715 if test "x$OBJCOPY" = x; then 43716 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJCOPY= (no value)" >&5 43717 $as_echo "$as_me: Setting user supplied tool OBJCOPY= (no value)" >&6;} 43718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 43719 $as_echo_n "checking for OBJCOPY... " >&6; } 43720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43721 $as_echo "disabled" >&6; } 43722 else 43723 # Check if the provided tool contains a complete path. 43724 tool_specified="$OBJCOPY" 43725 tool_basename="${tool_specified##*/}" 43726 if test "x$tool_basename" = "x$tool_specified"; then 43727 # A command without a complete path is provided, search $PATH. 43728 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5 43729 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;} 43730 # Extract the first word of "$tool_basename", so it can be a program name with args. 43731 set dummy $tool_basename; ac_word=$2 43732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43733 $as_echo_n "checking for $ac_word... " >&6; } 43734 if ${ac_cv_path_OBJCOPY+:} false; then : 43735 $as_echo_n "(cached) " >&6 43736 else 43737 case $OBJCOPY in 43738 [\\/]* | ?:[\\/]*) 43739 ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path. 43740 ;; 43741 *) 43742 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43743 for as_dir in $PATH 43744 do 43745 IFS=$as_save_IFS 43746 test -z "$as_dir" && as_dir=. 43747 for ac_exec_ext in '' $ac_executable_extensions; do 43748 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43749 ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 43750 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43751 break 2 43752 fi 43753 done 43754 done 43755 IFS=$as_save_IFS 43756 43757 ;; 43758 esac 43759 fi 43760 OBJCOPY=$ac_cv_path_OBJCOPY 43761 if test -n "$OBJCOPY"; then 43762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 43763 $as_echo "$OBJCOPY" >&6; } 43764 else 43765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43766 $as_echo "no" >&6; } 43767 fi 43768 43769 43770 if test "x$OBJCOPY" = x; then 43771 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43772 fi 43773 else 43774 # Otherwise we believe it is a complete path. Use it as it is. 43775 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5 43776 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;} 43777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 43778 $as_echo_n "checking for OBJCOPY... " >&6; } 43779 if test ! -x "$tool_specified"; then 43780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43781 $as_echo "not found" >&6; } 43782 as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 43783 fi 43784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43785 $as_echo "$tool_specified" >&6; } 43786 fi 43787 fi 43788 fi 43789 43790 fi 43791 43792 43793 # Only call fixup if objcopy was found. 43794 if test -n "$OBJCOPY"; then 43795 43796 # Only process if variable expands to non-empty 43797 43798 if test "x$OBJCOPY" != x; then 43799 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43800 43801 # First separate the path from the arguments. This will split at the first 43802 # space. 43803 complete="$OBJCOPY" 43804 path="${complete%% *}" 43805 tmp="$complete EOL" 43806 arguments="${tmp#* }" 43807 43808 # Input might be given as Windows format, start by converting to 43809 # unix format. 43810 new_path=`$CYGPATH -u "$path"` 43811 43812 # Now try to locate executable using which 43813 new_path=`$WHICH "$new_path" 2> /dev/null` 43814 # bat and cmd files are not always considered executable in cygwin causing which 43815 # to not find them 43816 if test "x$new_path" = x \ 43817 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43818 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43819 new_path=`$CYGPATH -u "$path"` 43820 fi 43821 if test "x$new_path" = x; then 43822 # Oops. Which didn't find the executable. 43823 # The splitting of arguments from the executable at a space might have been incorrect, 43824 # since paths with space are more likely in Windows. Give it another try with the whole 43825 # argument. 43826 path="$complete" 43827 arguments="EOL" 43828 new_path=`$CYGPATH -u "$path"` 43829 new_path=`$WHICH "$new_path" 2> /dev/null` 43830 # bat and cmd files are not always considered executable in cygwin causing which 43831 # to not find them 43832 if test "x$new_path" = x \ 43833 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43834 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43835 new_path=`$CYGPATH -u "$path"` 43836 fi 43837 if test "x$new_path" = x; then 43838 # It's still not found. Now this is an unrecoverable error. 43839 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43840 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43841 has_space=`$ECHO "$complete" | $GREP " "` 43842 if test "x$has_space" != x; then 43843 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43844 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43845 fi 43846 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43847 fi 43848 fi 43849 43850 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43851 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43852 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43853 # "foo.exe" is OK but "foo" is an error. 43854 # 43855 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43856 # It is also a way to make sure we got the proper file name for the real test later on. 43857 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43858 if test "x$test_shortpath" = x; then 43859 # Short path failed, file does not exist as specified. 43860 # Try adding .exe or .cmd 43861 if test -f "${new_path}.exe"; then 43862 input_to_shortpath="${new_path}.exe" 43863 elif test -f "${new_path}.cmd"; then 43864 input_to_shortpath="${new_path}.cmd" 43865 else 43866 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 43867 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 43868 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 43869 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 43870 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43871 fi 43872 else 43873 input_to_shortpath="$new_path" 43874 fi 43875 43876 # Call helper function which possibly converts this using DOS-style short mode. 43877 # If so, the updated path is stored in $new_path. 43878 new_path="$input_to_shortpath" 43879 43880 input_path="$input_to_shortpath" 43881 # Check if we need to convert this using DOS-style short mode. If the path 43882 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43883 # take no chances and rewrite it. 43884 # Note: m4 eats our [], so we need to use [ and ] instead. 43885 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43886 if test "x$has_forbidden_chars" != x; then 43887 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43888 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43889 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43890 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43891 # Going to short mode and back again did indeed matter. Since short mode is 43892 # case insensitive, let's make it lowercase to improve readability. 43893 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43894 # Now convert it back to Unix-style (cygpath) 43895 input_path=`$CYGPATH -u "$shortmode_path"` 43896 new_path="$input_path" 43897 fi 43898 fi 43899 43900 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43901 if test "x$test_cygdrive_prefix" = x; then 43902 # As a simple fix, exclude /usr/bin since it's not a real path. 43903 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 43904 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43905 # a path prefixed by /cygdrive for fixpath to work. 43906 new_path="$CYGWIN_ROOT_PATH$input_path" 43907 fi 43908 fi 43909 43910 # remove trailing .exe if any 43911 new_path="${new_path/%.exe/}" 43912 43913 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43914 43915 # First separate the path from the arguments. This will split at the first 43916 # space. 43917 complete="$OBJCOPY" 43918 path="${complete%% *}" 43919 tmp="$complete EOL" 43920 arguments="${tmp#* }" 43921 43922 # Input might be given as Windows format, start by converting to 43923 # unix format. 43924 new_path="$path" 43925 43926 windows_path="$new_path" 43927 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43928 unix_path=`$CYGPATH -u "$windows_path"` 43929 new_path="$unix_path" 43930 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43931 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43932 new_path="$unix_path" 43933 fi 43934 43935 43936 # Now try to locate executable using which 43937 new_path=`$WHICH "$new_path" 2> /dev/null` 43938 43939 if test "x$new_path" = x; then 43940 # Oops. Which didn't find the executable. 43941 # The splitting of arguments from the executable at a space might have been incorrect, 43942 # since paths with space are more likely in Windows. Give it another try with the whole 43943 # argument. 43944 path="$complete" 43945 arguments="EOL" 43946 new_path="$path" 43947 43948 windows_path="$new_path" 43949 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43950 unix_path=`$CYGPATH -u "$windows_path"` 43951 new_path="$unix_path" 43952 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43953 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43954 new_path="$unix_path" 43955 fi 43956 43957 43958 new_path=`$WHICH "$new_path" 2> /dev/null` 43959 # bat and cmd files are not always considered executable in MSYS causing which 43960 # to not find them 43961 if test "x$new_path" = x \ 43962 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43963 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43964 new_path="$path" 43965 43966 windows_path="$new_path" 43967 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43968 unix_path=`$CYGPATH -u "$windows_path"` 43969 new_path="$unix_path" 43970 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43971 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43972 new_path="$unix_path" 43973 fi 43974 43975 fi 43976 43977 if test "x$new_path" = x; then 43978 # It's still not found. Now this is an unrecoverable error. 43979 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43980 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43981 has_space=`$ECHO "$complete" | $GREP " "` 43982 if test "x$has_space" != x; then 43983 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43984 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43985 fi 43986 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43987 fi 43988 fi 43989 43990 # Now new_path has a complete unix path to the binary 43991 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43992 # Keep paths in /bin as-is, but remove trailing .exe if any 43993 new_path="${new_path/%.exe/}" 43994 # Do not save /bin paths to all_fixpath_prefixes! 43995 else 43996 # Not in mixed or Windows style, start by that. 43997 new_path=`cmd //c echo $new_path` 43998 43999 input_path="$new_path" 44000 # Check if we need to convert this using DOS-style short mode. If the path 44001 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44002 # take no chances and rewrite it. 44003 # Note: m4 eats our [], so we need to use [ and ] instead. 44004 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44005 if test "x$has_forbidden_chars" != x; then 44006 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44007 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44008 fi 44009 44010 # Output is in $new_path 44011 44012 windows_path="$new_path" 44013 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44014 unix_path=`$CYGPATH -u "$windows_path"` 44015 new_path="$unix_path" 44016 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44017 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44018 new_path="$unix_path" 44019 fi 44020 44021 # remove trailing .exe if any 44022 new_path="${new_path/%.exe/}" 44023 44024 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44025 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44026 fi 44027 44028 else 44029 # We're on a unix platform. Hooray! :) 44030 # First separate the path from the arguments. This will split at the first 44031 # space. 44032 complete="$OBJCOPY" 44033 path="${complete%% *}" 44034 tmp="$complete EOL" 44035 arguments="${tmp#* }" 44036 44037 # Cannot rely on the command "which" here since it doesn't always work. 44038 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44039 if test -z "$is_absolute_path"; then 44040 # Path to executable is not absolute. Find it. 44041 IFS_save="$IFS" 44042 IFS=: 44043 for p in $PATH; do 44044 if test -f "$p/$path" && test -x "$p/$path"; then 44045 new_path="$p/$path" 44046 break 44047 fi 44048 done 44049 IFS="$IFS_save" 44050 else 44051 # This is an absolute path, we can use it without further modifications. 44052 new_path="$path" 44053 fi 44054 44055 if test "x$new_path" = x; then 44056 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 44057 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 44058 has_space=`$ECHO "$complete" | $GREP " "` 44059 if test "x$has_space" != x; then 44060 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44061 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44062 fi 44063 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 44064 fi 44065 fi 44066 44067 # Now join together the path and the arguments once again 44068 if test "x$arguments" != xEOL; then 44069 new_complete="$new_path ${arguments% *}" 44070 else 44071 new_complete="$new_path" 44072 fi 44073 44074 if test "x$complete" != "x$new_complete"; then 44075 OBJCOPY="$new_complete" 44076 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5 44077 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;} 44078 fi 44079 fi 44080 44081 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 44082 # objcopy prior to 2.21.1 on solaris is broken and is not usable. 44083 # Rewrite objcopy version output to VALID_VERSION or BAD_VERSION. 44084 # - version number is last blank separate word on first line 44085 # - version number formats that have been seen: 44086 # - <major>.<minor> 44087 # - <major>.<minor>.<micro> 44088 OBJCOPY_VERSION=`$OBJCOPY --version | $HEAD -n 1` 44089 # The outer [ ] is to prevent m4 from eating the [] in the sed expression. 44090 OBJCOPY_VERSION_CHECK=`$ECHO $OBJCOPY_VERSION | $SED -n \ 44091 -e 's/.* //' \ 44092 -e '/^[01]\./b bad' \ 44093 -e '/^2\./{' \ 44094 -e ' s/^2\.//' \ 44095 -e ' /^[0-9]$/b bad' \ 44096 -e ' /^[0-9]\./b bad' \ 44097 -e ' /^1[0-9]$/b bad' \ 44098 -e ' /^1[0-9]\./b bad' \ 44099 -e ' /^20\./b bad' \ 44100 -e ' /^21\.0$/b bad' \ 44101 -e ' /^21\.0\./b bad' \ 44102 -e '}' \ 44103 -e ':good' \ 44104 -e 's/.*/VALID_VERSION/p' \ 44105 -e 'q' \ 44106 -e ':bad' \ 44107 -e 's/.*/BAD_VERSION/p' \ 44108 -e 'q'` 44109 if test "x$OBJCOPY_VERSION_CHECK" = xBAD_VERSION; then 44110 OBJCOPY= 44111 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring found objcopy since it is broken (prior to 2.21.1). No debug symbols will be generated." >&5 44112 $as_echo "$as_me: WARNING: Ignoring found objcopy since it is broken (prior to 2.21.1). No debug symbols will be generated." >&2;} 44113 { $as_echo "$as_me:${as_lineno-$LINENO}: objcopy reports version $OBJCOPY_VERSION" >&5 44114 $as_echo "$as_me: objcopy reports version $OBJCOPY_VERSION" >&6;} 44115 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&5 44116 $as_echo "$as_me: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&6;} 44117 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&5 44118 $as_echo "$as_me: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&6;} 44119 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: Solaris 11 Update 1 contains the correct version" >&5 44120 $as_echo "$as_me: Note: Solaris 11 Update 1 contains the correct version" >&6;} 44121 fi 44122 fi 44123 fi 44124 fi 44125 44126 44127 44128 # Publish this variable in the help. 44129 44130 44131 if [ -z "${OBJDUMP+x}" ]; then 44132 # The variable is not set by user, try to locate tool using the code snippet 44133 if test -n "$ac_tool_prefix"; then 44134 for ac_prog in gobjdump objdump 44135 do 44136 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 44137 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 44138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44139 $as_echo_n "checking for $ac_word... " >&6; } 44140 if ${ac_cv_prog_OBJDUMP+:} false; then : 44141 $as_echo_n "(cached) " >&6 44142 else 44143 if test -n "$OBJDUMP"; then 44144 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 44145 else 44146 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44147 for as_dir in $PATH 44148 do 44149 IFS=$as_save_IFS 44150 test -z "$as_dir" && as_dir=. 44151 for ac_exec_ext in '' $ac_executable_extensions; do 44152 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44153 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 44154 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44155 break 2 44156 fi 44157 done 44158 done 44159 IFS=$as_save_IFS 44160 44161 fi 44162 fi 44163 OBJDUMP=$ac_cv_prog_OBJDUMP 44164 if test -n "$OBJDUMP"; then 44165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 44166 $as_echo "$OBJDUMP" >&6; } 44167 else 44168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44169 $as_echo "no" >&6; } 44170 fi 44171 44172 44173 test -n "$OBJDUMP" && break 44174 done 44175 fi 44176 if test -z "$OBJDUMP"; then 44177 ac_ct_OBJDUMP=$OBJDUMP 44178 for ac_prog in gobjdump objdump 44179 do 44180 # Extract the first word of "$ac_prog", so it can be a program name with args. 44181 set dummy $ac_prog; ac_word=$2 44182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44183 $as_echo_n "checking for $ac_word... " >&6; } 44184 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 44185 $as_echo_n "(cached) " >&6 44186 else 44187 if test -n "$ac_ct_OBJDUMP"; then 44188 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 44189 else 44190 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44191 for as_dir in $PATH 44192 do 44193 IFS=$as_save_IFS 44194 test -z "$as_dir" && as_dir=. 44195 for ac_exec_ext in '' $ac_executable_extensions; do 44196 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44197 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 44198 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44199 break 2 44200 fi 44201 done 44202 done 44203 IFS=$as_save_IFS 44204 44205 fi 44206 fi 44207 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 44208 if test -n "$ac_ct_OBJDUMP"; then 44209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 44210 $as_echo "$ac_ct_OBJDUMP" >&6; } 44211 else 44212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44213 $as_echo "no" >&6; } 44214 fi 44215 44216 44217 test -n "$ac_ct_OBJDUMP" && break 44218 done 44219 44220 if test "x$ac_ct_OBJDUMP" = x; then 44221 OBJDUMP="" 44222 else 44223 case $cross_compiling:$ac_tool_warned in 44224 yes:) 44225 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 44226 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 44227 ac_tool_warned=yes ;; 44228 esac 44229 OBJDUMP=$ac_ct_OBJDUMP 44230 fi 44231 fi 44232 44233 else 44234 # The variable is set, but is it from the command line or the environment? 44235 44236 # Try to remove the string !OBJDUMP! from our list. 44237 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/} 44238 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44239 # If it failed, the variable was not from the command line. Ignore it, 44240 # but warn the user (except for BASH, which is always set by the calling BASH). 44241 if test "xOBJDUMP" != xBASH; then 44242 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5 44243 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;} 44244 fi 44245 # Try to locate tool using the code snippet 44246 if test -n "$ac_tool_prefix"; then 44247 for ac_prog in gobjdump objdump 44248 do 44249 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 44250 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 44251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44252 $as_echo_n "checking for $ac_word... " >&6; } 44253 if ${ac_cv_prog_OBJDUMP+:} false; then : 44254 $as_echo_n "(cached) " >&6 44255 else 44256 if test -n "$OBJDUMP"; then 44257 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 44258 else 44259 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44260 for as_dir in $PATH 44261 do 44262 IFS=$as_save_IFS 44263 test -z "$as_dir" && as_dir=. 44264 for ac_exec_ext in '' $ac_executable_extensions; do 44265 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44266 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 44267 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44268 break 2 44269 fi 44270 done 44271 done 44272 IFS=$as_save_IFS 44273 44274 fi 44275 fi 44276 OBJDUMP=$ac_cv_prog_OBJDUMP 44277 if test -n "$OBJDUMP"; then 44278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 44279 $as_echo "$OBJDUMP" >&6; } 44280 else 44281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44282 $as_echo "no" >&6; } 44283 fi 44284 44285 44286 test -n "$OBJDUMP" && break 44287 done 44288 fi 44289 if test -z "$OBJDUMP"; then 44290 ac_ct_OBJDUMP=$OBJDUMP 44291 for ac_prog in gobjdump objdump 44292 do 44293 # Extract the first word of "$ac_prog", so it can be a program name with args. 44294 set dummy $ac_prog; ac_word=$2 44295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44296 $as_echo_n "checking for $ac_word... " >&6; } 44297 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 44298 $as_echo_n "(cached) " >&6 44299 else 44300 if test -n "$ac_ct_OBJDUMP"; then 44301 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 44302 else 44303 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44304 for as_dir in $PATH 44305 do 44306 IFS=$as_save_IFS 44307 test -z "$as_dir" && as_dir=. 44308 for ac_exec_ext in '' $ac_executable_extensions; do 44309 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44310 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 44311 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44312 break 2 44313 fi 44314 done 44315 done 44316 IFS=$as_save_IFS 44317 44318 fi 44319 fi 44320 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 44321 if test -n "$ac_ct_OBJDUMP"; then 44322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 44323 $as_echo "$ac_ct_OBJDUMP" >&6; } 44324 else 44325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44326 $as_echo "no" >&6; } 44327 fi 44328 44329 44330 test -n "$ac_ct_OBJDUMP" && break 44331 done 44332 44333 if test "x$ac_ct_OBJDUMP" = x; then 44334 OBJDUMP="" 44335 else 44336 case $cross_compiling:$ac_tool_warned in 44337 yes:) 44338 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 44339 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 44340 ac_tool_warned=yes ;; 44341 esac 44342 OBJDUMP=$ac_ct_OBJDUMP 44343 fi 44344 fi 44345 44346 else 44347 # If it succeeded, then it was overridden by the user. We will use it 44348 # for the tool. 44349 44350 # First remove it from the list of overridden variables, so we can test 44351 # for unknown variables in the end. 44352 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44353 44354 # Check if we try to supply an empty value 44355 if test "x$OBJDUMP" = x; then 44356 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJDUMP= (no value)" >&5 44357 $as_echo "$as_me: Setting user supplied tool OBJDUMP= (no value)" >&6;} 44358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 44359 $as_echo_n "checking for OBJDUMP... " >&6; } 44360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44361 $as_echo "disabled" >&6; } 44362 else 44363 # Check if the provided tool contains a complete path. 44364 tool_specified="$OBJDUMP" 44365 tool_basename="${tool_specified##*/}" 44366 if test "x$tool_basename" = "x$tool_specified"; then 44367 # A command without a complete path is provided, search $PATH. 44368 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5 44369 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;} 44370 # Extract the first word of "$tool_basename", so it can be a program name with args. 44371 set dummy $tool_basename; ac_word=$2 44372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44373 $as_echo_n "checking for $ac_word... " >&6; } 44374 if ${ac_cv_path_OBJDUMP+:} false; then : 44375 $as_echo_n "(cached) " >&6 44376 else 44377 case $OBJDUMP in 44378 [\\/]* | ?:[\\/]*) 44379 ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path. 44380 ;; 44381 *) 44382 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44383 for as_dir in $PATH 44384 do 44385 IFS=$as_save_IFS 44386 test -z "$as_dir" && as_dir=. 44387 for ac_exec_ext in '' $ac_executable_extensions; do 44388 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44389 ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext" 44390 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44391 break 2 44392 fi 44393 done 44394 done 44395 IFS=$as_save_IFS 44396 44397 ;; 44398 esac 44399 fi 44400 OBJDUMP=$ac_cv_path_OBJDUMP 44401 if test -n "$OBJDUMP"; then 44402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 44403 $as_echo "$OBJDUMP" >&6; } 44404 else 44405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44406 $as_echo "no" >&6; } 44407 fi 44408 44409 44410 if test "x$OBJDUMP" = x; then 44411 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44412 fi 44413 else 44414 # Otherwise we believe it is a complete path. Use it as it is. 44415 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5 44416 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;} 44417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 44418 $as_echo_n "checking for OBJDUMP... " >&6; } 44419 if test ! -x "$tool_specified"; then 44420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44421 $as_echo "not found" >&6; } 44422 as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5 44423 fi 44424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44425 $as_echo "$tool_specified" >&6; } 44426 fi 44427 fi 44428 fi 44429 44430 fi 44431 44432 44433 if test "x$OBJDUMP" != x; then 44434 # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE 44435 # bails if argument is missing. 44436 44437 # Only process if variable expands to non-empty 44438 44439 if test "x$OBJDUMP" != x; then 44440 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44441 44442 # First separate the path from the arguments. This will split at the first 44443 # space. 44444 complete="$OBJDUMP" 44445 path="${complete%% *}" 44446 tmp="$complete EOL" 44447 arguments="${tmp#* }" 44448 44449 # Input might be given as Windows format, start by converting to 44450 # unix format. 44451 new_path=`$CYGPATH -u "$path"` 44452 44453 # Now try to locate executable using which 44454 new_path=`$WHICH "$new_path" 2> /dev/null` 44455 # bat and cmd files are not always considered executable in cygwin causing which 44456 # to not find them 44457 if test "x$new_path" = x \ 44458 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44459 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44460 new_path=`$CYGPATH -u "$path"` 44461 fi 44462 if test "x$new_path" = x; then 44463 # Oops. Which didn't find the executable. 44464 # The splitting of arguments from the executable at a space might have been incorrect, 44465 # since paths with space are more likely in Windows. Give it another try with the whole 44466 # argument. 44467 path="$complete" 44468 arguments="EOL" 44469 new_path=`$CYGPATH -u "$path"` 44470 new_path=`$WHICH "$new_path" 2> /dev/null` 44471 # bat and cmd files are not always considered executable in cygwin causing which 44472 # to not find them 44473 if test "x$new_path" = x \ 44474 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44475 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44476 new_path=`$CYGPATH -u "$path"` 44477 fi 44478 if test "x$new_path" = x; then 44479 # It's still not found. Now this is an unrecoverable error. 44480 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 44481 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 44482 has_space=`$ECHO "$complete" | $GREP " "` 44483 if test "x$has_space" != x; then 44484 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44485 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44486 fi 44487 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44488 fi 44489 fi 44490 44491 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44492 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44493 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44494 # "foo.exe" is OK but "foo" is an error. 44495 # 44496 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44497 # It is also a way to make sure we got the proper file name for the real test later on. 44498 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44499 if test "x$test_shortpath" = x; then 44500 # Short path failed, file does not exist as specified. 44501 # Try adding .exe or .cmd 44502 if test -f "${new_path}.exe"; then 44503 input_to_shortpath="${new_path}.exe" 44504 elif test -f "${new_path}.cmd"; then 44505 input_to_shortpath="${new_path}.cmd" 44506 else 44507 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5 44508 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;} 44509 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44510 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44511 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44512 fi 44513 else 44514 input_to_shortpath="$new_path" 44515 fi 44516 44517 # Call helper function which possibly converts this using DOS-style short mode. 44518 # If so, the updated path is stored in $new_path. 44519 new_path="$input_to_shortpath" 44520 44521 input_path="$input_to_shortpath" 44522 # Check if we need to convert this using DOS-style short mode. If the path 44523 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44524 # take no chances and rewrite it. 44525 # Note: m4 eats our [], so we need to use [ and ] instead. 44526 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44527 if test "x$has_forbidden_chars" != x; then 44528 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44529 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44530 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44531 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44532 # Going to short mode and back again did indeed matter. Since short mode is 44533 # case insensitive, let's make it lowercase to improve readability. 44534 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44535 # Now convert it back to Unix-style (cygpath) 44536 input_path=`$CYGPATH -u "$shortmode_path"` 44537 new_path="$input_path" 44538 fi 44539 fi 44540 44541 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44542 if test "x$test_cygdrive_prefix" = x; then 44543 # As a simple fix, exclude /usr/bin since it's not a real path. 44544 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44545 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44546 # a path prefixed by /cygdrive for fixpath to work. 44547 new_path="$CYGWIN_ROOT_PATH$input_path" 44548 fi 44549 fi 44550 44551 # remove trailing .exe if any 44552 new_path="${new_path/%.exe/}" 44553 44554 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44555 44556 # First separate the path from the arguments. This will split at the first 44557 # space. 44558 complete="$OBJDUMP" 44559 path="${complete%% *}" 44560 tmp="$complete EOL" 44561 arguments="${tmp#* }" 44562 44563 # Input might be given as Windows format, start by converting to 44564 # unix format. 44565 new_path="$path" 44566 44567 windows_path="$new_path" 44568 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44569 unix_path=`$CYGPATH -u "$windows_path"` 44570 new_path="$unix_path" 44571 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44572 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44573 new_path="$unix_path" 44574 fi 44575 44576 44577 # Now try to locate executable using which 44578 new_path=`$WHICH "$new_path" 2> /dev/null` 44579 44580 if test "x$new_path" = x; then 44581 # Oops. Which didn't find the executable. 44582 # The splitting of arguments from the executable at a space might have been incorrect, 44583 # since paths with space are more likely in Windows. Give it another try with the whole 44584 # argument. 44585 path="$complete" 44586 arguments="EOL" 44587 new_path="$path" 44588 44589 windows_path="$new_path" 44590 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44591 unix_path=`$CYGPATH -u "$windows_path"` 44592 new_path="$unix_path" 44593 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44594 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44595 new_path="$unix_path" 44596 fi 44597 44598 44599 new_path=`$WHICH "$new_path" 2> /dev/null` 44600 # bat and cmd files are not always considered executable in MSYS causing which 44601 # to not find them 44602 if test "x$new_path" = x \ 44603 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44604 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44605 new_path="$path" 44606 44607 windows_path="$new_path" 44608 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44609 unix_path=`$CYGPATH -u "$windows_path"` 44610 new_path="$unix_path" 44611 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44612 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44613 new_path="$unix_path" 44614 fi 44615 44616 fi 44617 44618 if test "x$new_path" = x; then 44619 # It's still not found. Now this is an unrecoverable error. 44620 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 44621 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 44622 has_space=`$ECHO "$complete" | $GREP " "` 44623 if test "x$has_space" != x; then 44624 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44625 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44626 fi 44627 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44628 fi 44629 fi 44630 44631 # Now new_path has a complete unix path to the binary 44632 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44633 # Keep paths in /bin as-is, but remove trailing .exe if any 44634 new_path="${new_path/%.exe/}" 44635 # Do not save /bin paths to all_fixpath_prefixes! 44636 else 44637 # Not in mixed or Windows style, start by that. 44638 new_path=`cmd //c echo $new_path` 44639 44640 input_path="$new_path" 44641 # Check if we need to convert this using DOS-style short mode. If the path 44642 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44643 # take no chances and rewrite it. 44644 # Note: m4 eats our [], so we need to use [ and ] instead. 44645 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44646 if test "x$has_forbidden_chars" != x; then 44647 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44648 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44649 fi 44650 44651 # Output is in $new_path 44652 44653 windows_path="$new_path" 44654 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44655 unix_path=`$CYGPATH -u "$windows_path"` 44656 new_path="$unix_path" 44657 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44658 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44659 new_path="$unix_path" 44660 fi 44661 44662 # remove trailing .exe if any 44663 new_path="${new_path/%.exe/}" 44664 44665 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44666 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44667 fi 44668 44669 else 44670 # We're on a unix platform. Hooray! :) 44671 # First separate the path from the arguments. This will split at the first 44672 # space. 44673 complete="$OBJDUMP" 44674 path="${complete%% *}" 44675 tmp="$complete EOL" 44676 arguments="${tmp#* }" 44677 44678 # Cannot rely on the command "which" here since it doesn't always work. 44679 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44680 if test -z "$is_absolute_path"; then 44681 # Path to executable is not absolute. Find it. 44682 IFS_save="$IFS" 44683 IFS=: 44684 for p in $PATH; do 44685 if test -f "$p/$path" && test -x "$p/$path"; then 44686 new_path="$p/$path" 44687 break 44688 fi 44689 done 44690 IFS="$IFS_save" 44691 else 44692 # This is an absolute path, we can use it without further modifications. 44693 new_path="$path" 44694 fi 44695 44696 if test "x$new_path" = x; then 44697 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 44698 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 44699 has_space=`$ECHO "$complete" | $GREP " "` 44700 if test "x$has_space" != x; then 44701 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44702 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44703 fi 44704 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44705 fi 44706 fi 44707 44708 # Now join together the path and the arguments once again 44709 if test "x$arguments" != xEOL; then 44710 new_complete="$new_path ${arguments% *}" 44711 else 44712 new_complete="$new_path" 44713 fi 44714 44715 if test "x$complete" != "x$new_complete"; then 44716 OBJDUMP="$new_complete" 44717 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5 44718 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;} 44719 fi 44720 fi 44721 44722 fi 44723 44724 44725 # Restore old path, except for the microsoft toolchain, which requires VS_PATH 44726 # to remain in place. Otherwise the compiler will not work in some siutations 44727 # in later configure checks. 44728 if test "x$TOOLCHAIN_TYPE" != "xmicrosoft"; then 44729 PATH="$OLD_PATH" 44730 fi 44731 44732 # Restore the flags to the user specified values. 44733 # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2" 44734 CFLAGS="$ORG_CFLAGS" 44735 CXXFLAGS="$ORG_CXXFLAGS" 44736 44737 44738 # Finally do some processing after the detection phase 44739 44740 if test "x$COMPILE_TYPE" = "xcross"; then 44741 # Now we need to find a C/C++ compiler that can build executables for the 44742 # build platform. We can't use the AC_PROG_CC macro, since it can only be 44743 # used once. Also, we need to do this without adding a tools dir to the 44744 # path, otherwise we might pick up cross-compilers which don't use standard 44745 # naming. 44746 44747 OLDPATH="$PATH" 44748 44749 44750 # Check whether --with-build-devkit was given. 44751 if test "${with_build_devkit+set}" = set; then : 44752 withval=$with_build_devkit; 44753 fi 44754 44755 if test "x$with_build_devkit" = "xyes"; then 44756 as_fn_error $? "--with-build-devkit must have a value" "$LINENO" 5 44757 elif test -n "$with_build_devkit"; then 44758 if test ! -d "$with_build_devkit"; then 44759 as_fn_error $? "--with-build-devkit points to non existing dir: $with_build_devkit" "$LINENO" 5 44760 else 44761 44762 # Only process if variable expands to non-empty 44763 44764 if test "x$with_build_devkit" != x; then 44765 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44766 44767 # Input might be given as Windows format, start by converting to 44768 # unix format. 44769 path="$with_build_devkit" 44770 new_path=`$CYGPATH -u "$path"` 44771 44772 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44773 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44774 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44775 # "foo.exe" is OK but "foo" is an error. 44776 # 44777 # This test is therefore slightly more accurate than "test -f" to check for file precense. 44778 # It is also a way to make sure we got the proper file name for the real test later on. 44779 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44780 if test "x$test_shortpath" = x; then 44781 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 44782 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 44783 as_fn_error $? "Cannot locate the the path of with_build_devkit" "$LINENO" 5 44784 fi 44785 44786 # Call helper function which possibly converts this using DOS-style short mode. 44787 # If so, the updated path is stored in $new_path. 44788 44789 input_path="$new_path" 44790 # Check if we need to convert this using DOS-style short mode. If the path 44791 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44792 # take no chances and rewrite it. 44793 # Note: m4 eats our [], so we need to use [ and ] instead. 44794 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44795 if test "x$has_forbidden_chars" != x; then 44796 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44797 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44798 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44799 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44800 # Going to short mode and back again did indeed matter. Since short mode is 44801 # case insensitive, let's make it lowercase to improve readability. 44802 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44803 # Now convert it back to Unix-style (cygpath) 44804 input_path=`$CYGPATH -u "$shortmode_path"` 44805 new_path="$input_path" 44806 fi 44807 fi 44808 44809 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44810 if test "x$test_cygdrive_prefix" = x; then 44811 # As a simple fix, exclude /usr/bin since it's not a real path. 44812 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 44813 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44814 # a path prefixed by /cygdrive for fixpath to work. 44815 new_path="$CYGWIN_ROOT_PATH$input_path" 44816 fi 44817 fi 44818 44819 44820 if test "x$path" != "x$new_path"; then 44821 with_build_devkit="$new_path" 44822 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 44823 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 44824 fi 44825 44826 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44827 44828 path="$with_build_devkit" 44829 has_colon=`$ECHO $path | $GREP ^.:` 44830 new_path="$path" 44831 if test "x$has_colon" = x; then 44832 # Not in mixed or Windows style, start by that. 44833 new_path=`cmd //c echo $path` 44834 fi 44835 44836 44837 input_path="$new_path" 44838 # Check if we need to convert this using DOS-style short mode. If the path 44839 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44840 # take no chances and rewrite it. 44841 # Note: m4 eats our [], so we need to use [ and ] instead. 44842 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44843 if test "x$has_forbidden_chars" != x; then 44844 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44845 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44846 fi 44847 44848 44849 windows_path="$new_path" 44850 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44851 unix_path=`$CYGPATH -u "$windows_path"` 44852 new_path="$unix_path" 44853 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44854 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44855 new_path="$unix_path" 44856 fi 44857 44858 if test "x$path" != "x$new_path"; then 44859 with_build_devkit="$new_path" 44860 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 44861 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 44862 fi 44863 44864 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44865 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44866 44867 else 44868 # We're on a unix platform. Hooray! :) 44869 path="$with_build_devkit" 44870 has_space=`$ECHO "$path" | $GREP " "` 44871 if test "x$has_space" != x; then 44872 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 44873 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 44874 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 44875 fi 44876 44877 # Use eval to expand a potential ~ 44878 eval path="$path" 44879 if test ! -f "$path" && test ! -d "$path"; then 44880 as_fn_error $? "The path of with_build_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 44881 fi 44882 44883 if test -d "$path"; then 44884 with_build_devkit="`cd "$path"; $THEPWDCMD -L`" 44885 else 44886 dir="`$DIRNAME "$path"`" 44887 base="`$BASENAME "$path"`" 44888 with_build_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 44889 fi 44890 fi 44891 fi 44892 44893 BUILD_DEVKIT_ROOT="$with_build_devkit" 44894 # Check for a meta data info file in the root of the devkit 44895 if test -f "$BUILD_DEVKIT_ROOT/devkit.info"; then 44896 # Process devkit.info so that existing devkit variables are not 44897 # modified by this 44898 $SED -e "s/^DEVKIT_/BUILD_DEVKIT_/g" \ 44899 -e "s/\$DEVKIT_ROOT/\$BUILD_DEVKIT_ROOT/g" \ 44900 -e "s/\$host/\$build/g" \ 44901 $BUILD_DEVKIT_ROOT/devkit.info \ 44902 > $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 44903 . $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 44904 # This potentially sets the following: 44905 # A descriptive name of the devkit 44906 44907 if test "x$BUILD_DEVKIT_NAME" = x; then 44908 eval BUILD_DEVKIT_NAME="\${BUILD_DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 44909 fi 44910 44911 # Corresponds to --with-extra-path 44912 44913 if test "x$BUILD_DEVKIT_EXTRA_PATH" = x; then 44914 eval BUILD_DEVKIT_EXTRA_PATH="\${BUILD_DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 44915 fi 44916 44917 # Corresponds to --with-toolchain-path 44918 44919 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 44920 eval BUILD_DEVKIT_TOOLCHAIN_PATH="\${BUILD_DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 44921 fi 44922 44923 # Corresponds to --with-sysroot 44924 44925 if test "x$BUILD_DEVKIT_SYSROOT" = x; then 44926 eval BUILD_DEVKIT_SYSROOT="\${BUILD_DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 44927 fi 44928 44929 # Skip the Window specific parts 44930 fi 44931 44932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build platform devkit" >&5 44933 $as_echo_n "checking for build platform devkit... " >&6; } 44934 if test "x$BUILD_DEVKIT_NAME" != x; then 44935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&5 44936 $as_echo "$BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&6; } 44937 else 44938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_ROOT" >&5 44939 $as_echo "$BUILD_DEVKIT_ROOT" >&6; } 44940 fi 44941 44942 BUILD_SYSROOT="$BUILD_DEVKIT_SYSROOT" 44943 44944 if test "x$BUILD_SYSROOT" != "x"; then 44945 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 44946 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 44947 # Solaris Studio does not have a concept of sysroot. Instead we must 44948 # make sure the default include and lib dirs are appended to each 44949 # compile and link command line. Must also add -I-xbuiltin to enable 44950 # inlining of system functions and intrinsics. 44951 BUILD_SYSROOT_CFLAGS="-I-xbuiltin -I$BUILD_SYSROOT/usr/include" 44952 BUILD_SYSROOT_LDFLAGS="-L$BUILD_SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 44953 -L$BUILD_SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 44954 fi 44955 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 44956 BUILD_SYSROOT_CFLAGS="--sysroot=$BUILD_SYSROOT" 44957 BUILD_SYSROOT_LDFLAGS="--sysroot=$BUILD_SYSROOT" 44958 elif test "x$TOOLCHAIN_TYPE" = xclang; then 44959 BUILD_SYSROOT_CFLAGS="-isysroot $BUILD_SYSROOT" 44960 BUILD_SYSROOT_LDFLAGS="-isysroot $BUILD_SYSROOT" 44961 fi 44962 # The global CFLAGS and LDFLAGS variables need these for configure to function 44963 BUILD_CFLAGS="$BUILD_CFLAGS $BUILD_SYSROOT_CFLAGS" 44964 BUILD_CPPFLAGS="$BUILD_CPPFLAGS $BUILD_SYSROOT_CFLAGS" 44965 BUILD_CXXFLAGS="$BUILD_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 44966 BUILD_LDFLAGS="$BUILD_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 44967 fi 44968 44969 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 44970 # We also need -iframework<path>/System/Library/Frameworks 44971 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44972 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44973 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 44974 # set this here so it doesn't have to be peppered throughout the forest 44975 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44976 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44977 fi 44978 44979 44980 44981 44982 44983 # Fallback default of just /bin if DEVKIT_PATH is not defined 44984 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 44985 BUILD_DEVKIT_TOOLCHAIN_PATH="$BUILD_DEVKIT_ROOT/bin" 44986 fi 44987 PATH="$BUILD_DEVKIT_TOOLCHAIN_PATH:$BUILD_DEVKIT_EXTRA_PATH" 44988 fi 44989 fi 44990 44991 # FIXME: we should list the discovered compilers as an exclude pattern! 44992 # If we do that, we can do this detection before POST_DETECTION, and still 44993 # find the build compilers in the tools dir, if needed. 44994 44995 44996 44997 # Publish this variable in the help. 44998 44999 45000 if [ -z "${BUILD_CC+x}" ]; then 45001 # The variable is not set by user, try to locate tool using the code snippet 45002 for ac_prog in cl cc gcc 45003 do 45004 # Extract the first word of "$ac_prog", so it can be a program name with args. 45005 set dummy $ac_prog; ac_word=$2 45006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45007 $as_echo_n "checking for $ac_word... " >&6; } 45008 if ${ac_cv_path_BUILD_CC+:} false; then : 45009 $as_echo_n "(cached) " >&6 45010 else 45011 case $BUILD_CC in 45012 [\\/]* | ?:[\\/]*) 45013 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 45014 ;; 45015 *) 45016 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45017 for as_dir in $PATH 45018 do 45019 IFS=$as_save_IFS 45020 test -z "$as_dir" && as_dir=. 45021 for ac_exec_ext in '' $ac_executable_extensions; do 45022 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45023 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 45024 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45025 break 2 45026 fi 45027 done 45028 done 45029 IFS=$as_save_IFS 45030 45031 ;; 45032 esac 45033 fi 45034 BUILD_CC=$ac_cv_path_BUILD_CC 45035 if test -n "$BUILD_CC"; then 45036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 45037 $as_echo "$BUILD_CC" >&6; } 45038 else 45039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45040 $as_echo "no" >&6; } 45041 fi 45042 45043 45044 test -n "$BUILD_CC" && break 45045 done 45046 45047 else 45048 # The variable is set, but is it from the command line or the environment? 45049 45050 # Try to remove the string !BUILD_CC! from our list. 45051 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/} 45052 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45053 # If it failed, the variable was not from the command line. Ignore it, 45054 # but warn the user (except for BASH, which is always set by the calling BASH). 45055 if test "xBUILD_CC" != xBASH; then 45056 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5 45057 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;} 45058 fi 45059 # Try to locate tool using the code snippet 45060 for ac_prog in cl cc gcc 45061 do 45062 # Extract the first word of "$ac_prog", so it can be a program name with args. 45063 set dummy $ac_prog; ac_word=$2 45064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45065 $as_echo_n "checking for $ac_word... " >&6; } 45066 if ${ac_cv_path_BUILD_CC+:} false; then : 45067 $as_echo_n "(cached) " >&6 45068 else 45069 case $BUILD_CC in 45070 [\\/]* | ?:[\\/]*) 45071 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 45072 ;; 45073 *) 45074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45075 for as_dir in $PATH 45076 do 45077 IFS=$as_save_IFS 45078 test -z "$as_dir" && as_dir=. 45079 for ac_exec_ext in '' $ac_executable_extensions; do 45080 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45081 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 45082 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45083 break 2 45084 fi 45085 done 45086 done 45087 IFS=$as_save_IFS 45088 45089 ;; 45090 esac 45091 fi 45092 BUILD_CC=$ac_cv_path_BUILD_CC 45093 if test -n "$BUILD_CC"; then 45094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 45095 $as_echo "$BUILD_CC" >&6; } 45096 else 45097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45098 $as_echo "no" >&6; } 45099 fi 45100 45101 45102 test -n "$BUILD_CC" && break 45103 done 45104 45105 else 45106 # If it succeeded, then it was overridden by the user. We will use it 45107 # for the tool. 45108 45109 # First remove it from the list of overridden variables, so we can test 45110 # for unknown variables in the end. 45111 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45112 45113 # Check if we try to supply an empty value 45114 if test "x$BUILD_CC" = x; then 45115 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CC= (no value)" >&5 45116 $as_echo "$as_me: Setting user supplied tool BUILD_CC= (no value)" >&6;} 45117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 45118 $as_echo_n "checking for BUILD_CC... " >&6; } 45119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45120 $as_echo "disabled" >&6; } 45121 else 45122 # Check if the provided tool contains a complete path. 45123 tool_specified="$BUILD_CC" 45124 tool_basename="${tool_specified##*/}" 45125 if test "x$tool_basename" = "x$tool_specified"; then 45126 # A command without a complete path is provided, search $PATH. 45127 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5 45128 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;} 45129 # Extract the first word of "$tool_basename", so it can be a program name with args. 45130 set dummy $tool_basename; ac_word=$2 45131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45132 $as_echo_n "checking for $ac_word... " >&6; } 45133 if ${ac_cv_path_BUILD_CC+:} false; then : 45134 $as_echo_n "(cached) " >&6 45135 else 45136 case $BUILD_CC in 45137 [\\/]* | ?:[\\/]*) 45138 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 45139 ;; 45140 *) 45141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45142 for as_dir in $PATH 45143 do 45144 IFS=$as_save_IFS 45145 test -z "$as_dir" && as_dir=. 45146 for ac_exec_ext in '' $ac_executable_extensions; do 45147 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45148 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 45149 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45150 break 2 45151 fi 45152 done 45153 done 45154 IFS=$as_save_IFS 45155 45156 ;; 45157 esac 45158 fi 45159 BUILD_CC=$ac_cv_path_BUILD_CC 45160 if test -n "$BUILD_CC"; then 45161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 45162 $as_echo "$BUILD_CC" >&6; } 45163 else 45164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45165 $as_echo "no" >&6; } 45166 fi 45167 45168 45169 if test "x$BUILD_CC" = x; then 45170 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45171 fi 45172 else 45173 # Otherwise we believe it is a complete path. Use it as it is. 45174 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5 45175 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;} 45176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 45177 $as_echo_n "checking for BUILD_CC... " >&6; } 45178 if test ! -x "$tool_specified"; then 45179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45180 $as_echo "not found" >&6; } 45181 as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5 45182 fi 45183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45184 $as_echo "$tool_specified" >&6; } 45185 fi 45186 fi 45187 fi 45188 45189 fi 45190 45191 45192 45193 if test "x$BUILD_CC" = x; then 45194 as_fn_error $? "Could not find required tool for BUILD_CC" "$LINENO" 5 45195 fi 45196 45197 45198 45199 # Only process if variable expands to non-empty 45200 45201 if test "x$BUILD_CC" != x; then 45202 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45203 45204 # First separate the path from the arguments. This will split at the first 45205 # space. 45206 complete="$BUILD_CC" 45207 path="${complete%% *}" 45208 tmp="$complete EOL" 45209 arguments="${tmp#* }" 45210 45211 # Input might be given as Windows format, start by converting to 45212 # unix format. 45213 new_path=`$CYGPATH -u "$path"` 45214 45215 # Now try to locate executable using which 45216 new_path=`$WHICH "$new_path" 2> /dev/null` 45217 # bat and cmd files are not always considered executable in cygwin causing which 45218 # to not find them 45219 if test "x$new_path" = x \ 45220 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45221 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45222 new_path=`$CYGPATH -u "$path"` 45223 fi 45224 if test "x$new_path" = x; then 45225 # Oops. Which didn't find the executable. 45226 # The splitting of arguments from the executable at a space might have been incorrect, 45227 # since paths with space are more likely in Windows. Give it another try with the whole 45228 # argument. 45229 path="$complete" 45230 arguments="EOL" 45231 new_path=`$CYGPATH -u "$path"` 45232 new_path=`$WHICH "$new_path" 2> /dev/null` 45233 # bat and cmd files are not always considered executable in cygwin causing which 45234 # to not find them 45235 if test "x$new_path" = x \ 45236 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45237 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45238 new_path=`$CYGPATH -u "$path"` 45239 fi 45240 if test "x$new_path" = x; then 45241 # It's still not found. Now this is an unrecoverable error. 45242 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 45243 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 45244 has_space=`$ECHO "$complete" | $GREP " "` 45245 if test "x$has_space" != x; then 45246 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45247 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45248 fi 45249 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 45250 fi 45251 fi 45252 45253 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45254 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45255 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45256 # "foo.exe" is OK but "foo" is an error. 45257 # 45258 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45259 # It is also a way to make sure we got the proper file name for the real test later on. 45260 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45261 if test "x$test_shortpath" = x; then 45262 # Short path failed, file does not exist as specified. 45263 # Try adding .exe or .cmd 45264 if test -f "${new_path}.exe"; then 45265 input_to_shortpath="${new_path}.exe" 45266 elif test -f "${new_path}.cmd"; then 45267 input_to_shortpath="${new_path}.cmd" 45268 else 45269 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5 45270 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;} 45271 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45272 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45273 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 45274 fi 45275 else 45276 input_to_shortpath="$new_path" 45277 fi 45278 45279 # Call helper function which possibly converts this using DOS-style short mode. 45280 # If so, the updated path is stored in $new_path. 45281 new_path="$input_to_shortpath" 45282 45283 input_path="$input_to_shortpath" 45284 # Check if we need to convert this using DOS-style short mode. If the path 45285 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45286 # take no chances and rewrite it. 45287 # Note: m4 eats our [], so we need to use [ and ] instead. 45288 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45289 if test "x$has_forbidden_chars" != x; then 45290 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45291 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45292 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45293 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45294 # Going to short mode and back again did indeed matter. Since short mode is 45295 # case insensitive, let's make it lowercase to improve readability. 45296 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45297 # Now convert it back to Unix-style (cygpath) 45298 input_path=`$CYGPATH -u "$shortmode_path"` 45299 new_path="$input_path" 45300 fi 45301 fi 45302 45303 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45304 if test "x$test_cygdrive_prefix" = x; then 45305 # As a simple fix, exclude /usr/bin since it's not a real path. 45306 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45307 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45308 # a path prefixed by /cygdrive for fixpath to work. 45309 new_path="$CYGWIN_ROOT_PATH$input_path" 45310 fi 45311 fi 45312 45313 # remove trailing .exe if any 45314 new_path="${new_path/%.exe/}" 45315 45316 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45317 45318 # First separate the path from the arguments. This will split at the first 45319 # space. 45320 complete="$BUILD_CC" 45321 path="${complete%% *}" 45322 tmp="$complete EOL" 45323 arguments="${tmp#* }" 45324 45325 # Input might be given as Windows format, start by converting to 45326 # unix format. 45327 new_path="$path" 45328 45329 windows_path="$new_path" 45330 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45331 unix_path=`$CYGPATH -u "$windows_path"` 45332 new_path="$unix_path" 45333 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45334 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45335 new_path="$unix_path" 45336 fi 45337 45338 45339 # Now try to locate executable using which 45340 new_path=`$WHICH "$new_path" 2> /dev/null` 45341 45342 if test "x$new_path" = x; then 45343 # Oops. Which didn't find the executable. 45344 # The splitting of arguments from the executable at a space might have been incorrect, 45345 # since paths with space are more likely in Windows. Give it another try with the whole 45346 # argument. 45347 path="$complete" 45348 arguments="EOL" 45349 new_path="$path" 45350 45351 windows_path="$new_path" 45352 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45353 unix_path=`$CYGPATH -u "$windows_path"` 45354 new_path="$unix_path" 45355 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45356 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45357 new_path="$unix_path" 45358 fi 45359 45360 45361 new_path=`$WHICH "$new_path" 2> /dev/null` 45362 # bat and cmd files are not always considered executable in MSYS causing which 45363 # to not find them 45364 if test "x$new_path" = x \ 45365 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45366 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45367 new_path="$path" 45368 45369 windows_path="$new_path" 45370 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45371 unix_path=`$CYGPATH -u "$windows_path"` 45372 new_path="$unix_path" 45373 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45374 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45375 new_path="$unix_path" 45376 fi 45377 45378 fi 45379 45380 if test "x$new_path" = x; then 45381 # It's still not found. Now this is an unrecoverable error. 45382 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 45383 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 45384 has_space=`$ECHO "$complete" | $GREP " "` 45385 if test "x$has_space" != x; then 45386 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45387 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45388 fi 45389 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 45390 fi 45391 fi 45392 45393 # Now new_path has a complete unix path to the binary 45394 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45395 # Keep paths in /bin as-is, but remove trailing .exe if any 45396 new_path="${new_path/%.exe/}" 45397 # Do not save /bin paths to all_fixpath_prefixes! 45398 else 45399 # Not in mixed or Windows style, start by that. 45400 new_path=`cmd //c echo $new_path` 45401 45402 input_path="$new_path" 45403 # Check if we need to convert this using DOS-style short mode. If the path 45404 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45405 # take no chances and rewrite it. 45406 # Note: m4 eats our [], so we need to use [ and ] instead. 45407 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45408 if test "x$has_forbidden_chars" != x; then 45409 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45410 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45411 fi 45412 45413 # Output is in $new_path 45414 45415 windows_path="$new_path" 45416 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45417 unix_path=`$CYGPATH -u "$windows_path"` 45418 new_path="$unix_path" 45419 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45420 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45421 new_path="$unix_path" 45422 fi 45423 45424 # remove trailing .exe if any 45425 new_path="${new_path/%.exe/}" 45426 45427 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45428 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45429 fi 45430 45431 else 45432 # We're on a unix platform. Hooray! :) 45433 # First separate the path from the arguments. This will split at the first 45434 # space. 45435 complete="$BUILD_CC" 45436 path="${complete%% *}" 45437 tmp="$complete EOL" 45438 arguments="${tmp#* }" 45439 45440 # Cannot rely on the command "which" here since it doesn't always work. 45441 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45442 if test -z "$is_absolute_path"; then 45443 # Path to executable is not absolute. Find it. 45444 IFS_save="$IFS" 45445 IFS=: 45446 for p in $PATH; do 45447 if test -f "$p/$path" && test -x "$p/$path"; then 45448 new_path="$p/$path" 45449 break 45450 fi 45451 done 45452 IFS="$IFS_save" 45453 else 45454 # This is an absolute path, we can use it without further modifications. 45455 new_path="$path" 45456 fi 45457 45458 if test "x$new_path" = x; then 45459 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 45460 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 45461 has_space=`$ECHO "$complete" | $GREP " "` 45462 if test "x$has_space" != x; then 45463 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45464 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45465 fi 45466 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 45467 fi 45468 fi 45469 45470 # Now join together the path and the arguments once again 45471 if test "x$arguments" != xEOL; then 45472 new_complete="$new_path ${arguments% *}" 45473 else 45474 new_complete="$new_path" 45475 fi 45476 45477 if test "x$complete" != "x$new_complete"; then 45478 BUILD_CC="$new_complete" 45479 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5 45480 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;} 45481 fi 45482 fi 45483 45484 45485 45486 45487 # Publish this variable in the help. 45488 45489 45490 if [ -z "${BUILD_CXX+x}" ]; then 45491 # The variable is not set by user, try to locate tool using the code snippet 45492 for ac_prog in cl CC g++ 45493 do 45494 # Extract the first word of "$ac_prog", so it can be a program name with args. 45495 set dummy $ac_prog; ac_word=$2 45496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45497 $as_echo_n "checking for $ac_word... " >&6; } 45498 if ${ac_cv_path_BUILD_CXX+:} false; then : 45499 $as_echo_n "(cached) " >&6 45500 else 45501 case $BUILD_CXX in 45502 [\\/]* | ?:[\\/]*) 45503 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 45504 ;; 45505 *) 45506 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45507 for as_dir in $PATH 45508 do 45509 IFS=$as_save_IFS 45510 test -z "$as_dir" && as_dir=. 45511 for ac_exec_ext in '' $ac_executable_extensions; do 45512 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45513 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 45514 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45515 break 2 45516 fi 45517 done 45518 done 45519 IFS=$as_save_IFS 45520 45521 ;; 45522 esac 45523 fi 45524 BUILD_CXX=$ac_cv_path_BUILD_CXX 45525 if test -n "$BUILD_CXX"; then 45526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 45527 $as_echo "$BUILD_CXX" >&6; } 45528 else 45529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45530 $as_echo "no" >&6; } 45531 fi 45532 45533 45534 test -n "$BUILD_CXX" && break 45535 done 45536 45537 else 45538 # The variable is set, but is it from the command line or the environment? 45539 45540 # Try to remove the string !BUILD_CXX! from our list. 45541 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/} 45542 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45543 # If it failed, the variable was not from the command line. Ignore it, 45544 # but warn the user (except for BASH, which is always set by the calling BASH). 45545 if test "xBUILD_CXX" != xBASH; then 45546 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5 45547 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;} 45548 fi 45549 # Try to locate tool using the code snippet 45550 for ac_prog in cl CC g++ 45551 do 45552 # Extract the first word of "$ac_prog", so it can be a program name with args. 45553 set dummy $ac_prog; ac_word=$2 45554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45555 $as_echo_n "checking for $ac_word... " >&6; } 45556 if ${ac_cv_path_BUILD_CXX+:} false; then : 45557 $as_echo_n "(cached) " >&6 45558 else 45559 case $BUILD_CXX in 45560 [\\/]* | ?:[\\/]*) 45561 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 45562 ;; 45563 *) 45564 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45565 for as_dir in $PATH 45566 do 45567 IFS=$as_save_IFS 45568 test -z "$as_dir" && as_dir=. 45569 for ac_exec_ext in '' $ac_executable_extensions; do 45570 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45571 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 45572 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45573 break 2 45574 fi 45575 done 45576 done 45577 IFS=$as_save_IFS 45578 45579 ;; 45580 esac 45581 fi 45582 BUILD_CXX=$ac_cv_path_BUILD_CXX 45583 if test -n "$BUILD_CXX"; then 45584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 45585 $as_echo "$BUILD_CXX" >&6; } 45586 else 45587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45588 $as_echo "no" >&6; } 45589 fi 45590 45591 45592 test -n "$BUILD_CXX" && break 45593 done 45594 45595 else 45596 # If it succeeded, then it was overridden by the user. We will use it 45597 # for the tool. 45598 45599 # First remove it from the list of overridden variables, so we can test 45600 # for unknown variables in the end. 45601 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45602 45603 # Check if we try to supply an empty value 45604 if test "x$BUILD_CXX" = x; then 45605 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CXX= (no value)" >&5 45606 $as_echo "$as_me: Setting user supplied tool BUILD_CXX= (no value)" >&6;} 45607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 45608 $as_echo_n "checking for BUILD_CXX... " >&6; } 45609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45610 $as_echo "disabled" >&6; } 45611 else 45612 # Check if the provided tool contains a complete path. 45613 tool_specified="$BUILD_CXX" 45614 tool_basename="${tool_specified##*/}" 45615 if test "x$tool_basename" = "x$tool_specified"; then 45616 # A command without a complete path is provided, search $PATH. 45617 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5 45618 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;} 45619 # Extract the first word of "$tool_basename", so it can be a program name with args. 45620 set dummy $tool_basename; ac_word=$2 45621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45622 $as_echo_n "checking for $ac_word... " >&6; } 45623 if ${ac_cv_path_BUILD_CXX+:} false; then : 45624 $as_echo_n "(cached) " >&6 45625 else 45626 case $BUILD_CXX in 45627 [\\/]* | ?:[\\/]*) 45628 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 45629 ;; 45630 *) 45631 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45632 for as_dir in $PATH 45633 do 45634 IFS=$as_save_IFS 45635 test -z "$as_dir" && as_dir=. 45636 for ac_exec_ext in '' $ac_executable_extensions; do 45637 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45638 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 45639 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45640 break 2 45641 fi 45642 done 45643 done 45644 IFS=$as_save_IFS 45645 45646 ;; 45647 esac 45648 fi 45649 BUILD_CXX=$ac_cv_path_BUILD_CXX 45650 if test -n "$BUILD_CXX"; then 45651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 45652 $as_echo "$BUILD_CXX" >&6; } 45653 else 45654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45655 $as_echo "no" >&6; } 45656 fi 45657 45658 45659 if test "x$BUILD_CXX" = x; then 45660 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45661 fi 45662 else 45663 # Otherwise we believe it is a complete path. Use it as it is. 45664 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5 45665 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;} 45666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 45667 $as_echo_n "checking for BUILD_CXX... " >&6; } 45668 if test ! -x "$tool_specified"; then 45669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45670 $as_echo "not found" >&6; } 45671 as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5 45672 fi 45673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45674 $as_echo "$tool_specified" >&6; } 45675 fi 45676 fi 45677 fi 45678 45679 fi 45680 45681 45682 45683 if test "x$BUILD_CXX" = x; then 45684 as_fn_error $? "Could not find required tool for BUILD_CXX" "$LINENO" 5 45685 fi 45686 45687 45688 45689 # Only process if variable expands to non-empty 45690 45691 if test "x$BUILD_CXX" != x; then 45692 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45693 45694 # First separate the path from the arguments. This will split at the first 45695 # space. 45696 complete="$BUILD_CXX" 45697 path="${complete%% *}" 45698 tmp="$complete EOL" 45699 arguments="${tmp#* }" 45700 45701 # Input might be given as Windows format, start by converting to 45702 # unix format. 45703 new_path=`$CYGPATH -u "$path"` 45704 45705 # Now try to locate executable using which 45706 new_path=`$WHICH "$new_path" 2> /dev/null` 45707 # bat and cmd files are not always considered executable in cygwin causing which 45708 # to not find them 45709 if test "x$new_path" = x \ 45710 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45711 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45712 new_path=`$CYGPATH -u "$path"` 45713 fi 45714 if test "x$new_path" = x; then 45715 # Oops. Which didn't find the executable. 45716 # The splitting of arguments from the executable at a space might have been incorrect, 45717 # since paths with space are more likely in Windows. Give it another try with the whole 45718 # argument. 45719 path="$complete" 45720 arguments="EOL" 45721 new_path=`$CYGPATH -u "$path"` 45722 new_path=`$WHICH "$new_path" 2> /dev/null` 45723 # bat and cmd files are not always considered executable in cygwin causing which 45724 # to not find them 45725 if test "x$new_path" = x \ 45726 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45727 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45728 new_path=`$CYGPATH -u "$path"` 45729 fi 45730 if test "x$new_path" = x; then 45731 # It's still not found. Now this is an unrecoverable error. 45732 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 45733 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 45734 has_space=`$ECHO "$complete" | $GREP " "` 45735 if test "x$has_space" != x; then 45736 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45737 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45738 fi 45739 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45740 fi 45741 fi 45742 45743 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45744 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45745 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45746 # "foo.exe" is OK but "foo" is an error. 45747 # 45748 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45749 # It is also a way to make sure we got the proper file name for the real test later on. 45750 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45751 if test "x$test_shortpath" = x; then 45752 # Short path failed, file does not exist as specified. 45753 # Try adding .exe or .cmd 45754 if test -f "${new_path}.exe"; then 45755 input_to_shortpath="${new_path}.exe" 45756 elif test -f "${new_path}.cmd"; then 45757 input_to_shortpath="${new_path}.cmd" 45758 else 45759 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5 45760 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;} 45761 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45762 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45763 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45764 fi 45765 else 45766 input_to_shortpath="$new_path" 45767 fi 45768 45769 # Call helper function which possibly converts this using DOS-style short mode. 45770 # If so, the updated path is stored in $new_path. 45771 new_path="$input_to_shortpath" 45772 45773 input_path="$input_to_shortpath" 45774 # Check if we need to convert this using DOS-style short mode. If the path 45775 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45776 # take no chances and rewrite it. 45777 # Note: m4 eats our [], so we need to use [ and ] instead. 45778 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45779 if test "x$has_forbidden_chars" != x; then 45780 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45781 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45782 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45783 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45784 # Going to short mode and back again did indeed matter. Since short mode is 45785 # case insensitive, let's make it lowercase to improve readability. 45786 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45787 # Now convert it back to Unix-style (cygpath) 45788 input_path=`$CYGPATH -u "$shortmode_path"` 45789 new_path="$input_path" 45790 fi 45791 fi 45792 45793 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45794 if test "x$test_cygdrive_prefix" = x; then 45795 # As a simple fix, exclude /usr/bin since it's not a real path. 45796 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45797 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45798 # a path prefixed by /cygdrive for fixpath to work. 45799 new_path="$CYGWIN_ROOT_PATH$input_path" 45800 fi 45801 fi 45802 45803 # remove trailing .exe if any 45804 new_path="${new_path/%.exe/}" 45805 45806 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45807 45808 # First separate the path from the arguments. This will split at the first 45809 # space. 45810 complete="$BUILD_CXX" 45811 path="${complete%% *}" 45812 tmp="$complete EOL" 45813 arguments="${tmp#* }" 45814 45815 # Input might be given as Windows format, start by converting to 45816 # unix format. 45817 new_path="$path" 45818 45819 windows_path="$new_path" 45820 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45821 unix_path=`$CYGPATH -u "$windows_path"` 45822 new_path="$unix_path" 45823 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45824 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45825 new_path="$unix_path" 45826 fi 45827 45828 45829 # Now try to locate executable using which 45830 new_path=`$WHICH "$new_path" 2> /dev/null` 45831 45832 if test "x$new_path" = x; then 45833 # Oops. Which didn't find the executable. 45834 # The splitting of arguments from the executable at a space might have been incorrect, 45835 # since paths with space are more likely in Windows. Give it another try with the whole 45836 # argument. 45837 path="$complete" 45838 arguments="EOL" 45839 new_path="$path" 45840 45841 windows_path="$new_path" 45842 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45843 unix_path=`$CYGPATH -u "$windows_path"` 45844 new_path="$unix_path" 45845 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45846 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45847 new_path="$unix_path" 45848 fi 45849 45850 45851 new_path=`$WHICH "$new_path" 2> /dev/null` 45852 # bat and cmd files are not always considered executable in MSYS causing which 45853 # to not find them 45854 if test "x$new_path" = x \ 45855 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45856 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45857 new_path="$path" 45858 45859 windows_path="$new_path" 45860 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45861 unix_path=`$CYGPATH -u "$windows_path"` 45862 new_path="$unix_path" 45863 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45864 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45865 new_path="$unix_path" 45866 fi 45867 45868 fi 45869 45870 if test "x$new_path" = x; then 45871 # It's still not found. Now this is an unrecoverable error. 45872 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 45873 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 45874 has_space=`$ECHO "$complete" | $GREP " "` 45875 if test "x$has_space" != x; then 45876 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45877 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45878 fi 45879 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45880 fi 45881 fi 45882 45883 # Now new_path has a complete unix path to the binary 45884 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45885 # Keep paths in /bin as-is, but remove trailing .exe if any 45886 new_path="${new_path/%.exe/}" 45887 # Do not save /bin paths to all_fixpath_prefixes! 45888 else 45889 # Not in mixed or Windows style, start by that. 45890 new_path=`cmd //c echo $new_path` 45891 45892 input_path="$new_path" 45893 # Check if we need to convert this using DOS-style short mode. If the path 45894 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45895 # take no chances and rewrite it. 45896 # Note: m4 eats our [], so we need to use [ and ] instead. 45897 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45898 if test "x$has_forbidden_chars" != x; then 45899 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45900 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45901 fi 45902 45903 # Output is in $new_path 45904 45905 windows_path="$new_path" 45906 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45907 unix_path=`$CYGPATH -u "$windows_path"` 45908 new_path="$unix_path" 45909 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45910 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45911 new_path="$unix_path" 45912 fi 45913 45914 # remove trailing .exe if any 45915 new_path="${new_path/%.exe/}" 45916 45917 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45918 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45919 fi 45920 45921 else 45922 # We're on a unix platform. Hooray! :) 45923 # First separate the path from the arguments. This will split at the first 45924 # space. 45925 complete="$BUILD_CXX" 45926 path="${complete%% *}" 45927 tmp="$complete EOL" 45928 arguments="${tmp#* }" 45929 45930 # Cannot rely on the command "which" here since it doesn't always work. 45931 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45932 if test -z "$is_absolute_path"; then 45933 # Path to executable is not absolute. Find it. 45934 IFS_save="$IFS" 45935 IFS=: 45936 for p in $PATH; do 45937 if test -f "$p/$path" && test -x "$p/$path"; then 45938 new_path="$p/$path" 45939 break 45940 fi 45941 done 45942 IFS="$IFS_save" 45943 else 45944 # This is an absolute path, we can use it without further modifications. 45945 new_path="$path" 45946 fi 45947 45948 if test "x$new_path" = x; then 45949 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 45950 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 45951 has_space=`$ECHO "$complete" | $GREP " "` 45952 if test "x$has_space" != x; then 45953 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45954 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45955 fi 45956 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45957 fi 45958 fi 45959 45960 # Now join together the path and the arguments once again 45961 if test "x$arguments" != xEOL; then 45962 new_complete="$new_path ${arguments% *}" 45963 else 45964 new_complete="$new_path" 45965 fi 45966 45967 if test "x$complete" != "x$new_complete"; then 45968 BUILD_CXX="$new_complete" 45969 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5 45970 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;} 45971 fi 45972 fi 45973 45974 45975 45976 # Publish this variable in the help. 45977 45978 45979 if [ -z "${BUILD_NM+x}" ]; then 45980 # The variable is not set by user, try to locate tool using the code snippet 45981 for ac_prog in nm gcc-nm 45982 do 45983 # Extract the first word of "$ac_prog", so it can be a program name with args. 45984 set dummy $ac_prog; ac_word=$2 45985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45986 $as_echo_n "checking for $ac_word... " >&6; } 45987 if ${ac_cv_path_BUILD_NM+:} false; then : 45988 $as_echo_n "(cached) " >&6 45989 else 45990 case $BUILD_NM in 45991 [\\/]* | ?:[\\/]*) 45992 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45993 ;; 45994 *) 45995 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45996 for as_dir in $PATH 45997 do 45998 IFS=$as_save_IFS 45999 test -z "$as_dir" && as_dir=. 46000 for ac_exec_ext in '' $ac_executable_extensions; do 46001 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46002 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 46003 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46004 break 2 46005 fi 46006 done 46007 done 46008 IFS=$as_save_IFS 46009 46010 ;; 46011 esac 46012 fi 46013 BUILD_NM=$ac_cv_path_BUILD_NM 46014 if test -n "$BUILD_NM"; then 46015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 46016 $as_echo "$BUILD_NM" >&6; } 46017 else 46018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46019 $as_echo "no" >&6; } 46020 fi 46021 46022 46023 test -n "$BUILD_NM" && break 46024 done 46025 46026 else 46027 # The variable is set, but is it from the command line or the environment? 46028 46029 # Try to remove the string !BUILD_NM! from our list. 46030 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_NM!/} 46031 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46032 # If it failed, the variable was not from the command line. Ignore it, 46033 # but warn the user (except for BASH, which is always set by the calling BASH). 46034 if test "xBUILD_NM" != xBASH; then 46035 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&5 46036 $as_echo "$as_me: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&2;} 46037 fi 46038 # Try to locate tool using the code snippet 46039 for ac_prog in nm gcc-nm 46040 do 46041 # Extract the first word of "$ac_prog", so it can be a program name with args. 46042 set dummy $ac_prog; ac_word=$2 46043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46044 $as_echo_n "checking for $ac_word... " >&6; } 46045 if ${ac_cv_path_BUILD_NM+:} false; then : 46046 $as_echo_n "(cached) " >&6 46047 else 46048 case $BUILD_NM in 46049 [\\/]* | ?:[\\/]*) 46050 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 46051 ;; 46052 *) 46053 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46054 for as_dir in $PATH 46055 do 46056 IFS=$as_save_IFS 46057 test -z "$as_dir" && as_dir=. 46058 for ac_exec_ext in '' $ac_executable_extensions; do 46059 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46060 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 46061 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46062 break 2 46063 fi 46064 done 46065 done 46066 IFS=$as_save_IFS 46067 46068 ;; 46069 esac 46070 fi 46071 BUILD_NM=$ac_cv_path_BUILD_NM 46072 if test -n "$BUILD_NM"; then 46073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 46074 $as_echo "$BUILD_NM" >&6; } 46075 else 46076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46077 $as_echo "no" >&6; } 46078 fi 46079 46080 46081 test -n "$BUILD_NM" && break 46082 done 46083 46084 else 46085 # If it succeeded, then it was overridden by the user. We will use it 46086 # for the tool. 46087 46088 # First remove it from the list of overridden variables, so we can test 46089 # for unknown variables in the end. 46090 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46091 46092 # Check if we try to supply an empty value 46093 if test "x$BUILD_NM" = x; then 46094 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_NM= (no value)" >&5 46095 $as_echo "$as_me: Setting user supplied tool BUILD_NM= (no value)" >&6;} 46096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 46097 $as_echo_n "checking for BUILD_NM... " >&6; } 46098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46099 $as_echo "disabled" >&6; } 46100 else 46101 # Check if the provided tool contains a complete path. 46102 tool_specified="$BUILD_NM" 46103 tool_basename="${tool_specified##*/}" 46104 if test "x$tool_basename" = "x$tool_specified"; then 46105 # A command without a complete path is provided, search $PATH. 46106 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_NM=$tool_basename" >&5 46107 $as_echo "$as_me: Will search for user supplied tool BUILD_NM=$tool_basename" >&6;} 46108 # Extract the first word of "$tool_basename", so it can be a program name with args. 46109 set dummy $tool_basename; ac_word=$2 46110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46111 $as_echo_n "checking for $ac_word... " >&6; } 46112 if ${ac_cv_path_BUILD_NM+:} false; then : 46113 $as_echo_n "(cached) " >&6 46114 else 46115 case $BUILD_NM in 46116 [\\/]* | ?:[\\/]*) 46117 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 46118 ;; 46119 *) 46120 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46121 for as_dir in $PATH 46122 do 46123 IFS=$as_save_IFS 46124 test -z "$as_dir" && as_dir=. 46125 for ac_exec_ext in '' $ac_executable_extensions; do 46126 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46127 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 46128 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46129 break 2 46130 fi 46131 done 46132 done 46133 IFS=$as_save_IFS 46134 46135 ;; 46136 esac 46137 fi 46138 BUILD_NM=$ac_cv_path_BUILD_NM 46139 if test -n "$BUILD_NM"; then 46140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 46141 $as_echo "$BUILD_NM" >&6; } 46142 else 46143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46144 $as_echo "no" >&6; } 46145 fi 46146 46147 46148 if test "x$BUILD_NM" = x; then 46149 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46150 fi 46151 else 46152 # Otherwise we believe it is a complete path. Use it as it is. 46153 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_NM=$tool_specified" >&5 46154 $as_echo "$as_me: Will use user supplied tool BUILD_NM=$tool_specified" >&6;} 46155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 46156 $as_echo_n "checking for BUILD_NM... " >&6; } 46157 if test ! -x "$tool_specified"; then 46158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46159 $as_echo "not found" >&6; } 46160 as_fn_error $? "User supplied tool BUILD_NM=$tool_specified does not exist or is not executable" "$LINENO" 5 46161 fi 46162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46163 $as_echo "$tool_specified" >&6; } 46164 fi 46165 fi 46166 fi 46167 46168 fi 46169 46170 46171 46172 # Only process if variable expands to non-empty 46173 46174 if test "x$BUILD_NM" != x; then 46175 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46176 46177 # First separate the path from the arguments. This will split at the first 46178 # space. 46179 complete="$BUILD_NM" 46180 path="${complete%% *}" 46181 tmp="$complete EOL" 46182 arguments="${tmp#* }" 46183 46184 # Input might be given as Windows format, start by converting to 46185 # unix format. 46186 new_path=`$CYGPATH -u "$path"` 46187 46188 # Now try to locate executable using which 46189 new_path=`$WHICH "$new_path" 2> /dev/null` 46190 # bat and cmd files are not always considered executable in cygwin causing which 46191 # to not find them 46192 if test "x$new_path" = x \ 46193 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46194 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46195 new_path=`$CYGPATH -u "$path"` 46196 fi 46197 if test "x$new_path" = x; then 46198 # Oops. Which didn't find the executable. 46199 # The splitting of arguments from the executable at a space might have been incorrect, 46200 # since paths with space are more likely in Windows. Give it another try with the whole 46201 # argument. 46202 path="$complete" 46203 arguments="EOL" 46204 new_path=`$CYGPATH -u "$path"` 46205 new_path=`$WHICH "$new_path" 2> /dev/null` 46206 # bat and cmd files are not always considered executable in cygwin causing which 46207 # to not find them 46208 if test "x$new_path" = x \ 46209 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46210 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46211 new_path=`$CYGPATH -u "$path"` 46212 fi 46213 if test "x$new_path" = x; then 46214 # It's still not found. Now this is an unrecoverable error. 46215 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 46216 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 46217 has_space=`$ECHO "$complete" | $GREP " "` 46218 if test "x$has_space" != x; then 46219 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46220 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46221 fi 46222 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 46223 fi 46224 fi 46225 46226 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46227 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46228 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46229 # "foo.exe" is OK but "foo" is an error. 46230 # 46231 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46232 # It is also a way to make sure we got the proper file name for the real test later on. 46233 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46234 if test "x$test_shortpath" = x; then 46235 # Short path failed, file does not exist as specified. 46236 # Try adding .exe or .cmd 46237 if test -f "${new_path}.exe"; then 46238 input_to_shortpath="${new_path}.exe" 46239 elif test -f "${new_path}.cmd"; then 46240 input_to_shortpath="${new_path}.cmd" 46241 else 46242 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&5 46243 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&6;} 46244 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46245 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46246 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 46247 fi 46248 else 46249 input_to_shortpath="$new_path" 46250 fi 46251 46252 # Call helper function which possibly converts this using DOS-style short mode. 46253 # If so, the updated path is stored in $new_path. 46254 new_path="$input_to_shortpath" 46255 46256 input_path="$input_to_shortpath" 46257 # Check if we need to convert this using DOS-style short mode. If the path 46258 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46259 # take no chances and rewrite it. 46260 # Note: m4 eats our [], so we need to use [ and ] instead. 46261 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46262 if test "x$has_forbidden_chars" != x; then 46263 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46264 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46265 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46266 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46267 # Going to short mode and back again did indeed matter. Since short mode is 46268 # case insensitive, let's make it lowercase to improve readability. 46269 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46270 # Now convert it back to Unix-style (cygpath) 46271 input_path=`$CYGPATH -u "$shortmode_path"` 46272 new_path="$input_path" 46273 fi 46274 fi 46275 46276 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46277 if test "x$test_cygdrive_prefix" = x; then 46278 # As a simple fix, exclude /usr/bin since it's not a real path. 46279 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46280 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46281 # a path prefixed by /cygdrive for fixpath to work. 46282 new_path="$CYGWIN_ROOT_PATH$input_path" 46283 fi 46284 fi 46285 46286 # remove trailing .exe if any 46287 new_path="${new_path/%.exe/}" 46288 46289 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46290 46291 # First separate the path from the arguments. This will split at the first 46292 # space. 46293 complete="$BUILD_NM" 46294 path="${complete%% *}" 46295 tmp="$complete EOL" 46296 arguments="${tmp#* }" 46297 46298 # Input might be given as Windows format, start by converting to 46299 # unix format. 46300 new_path="$path" 46301 46302 windows_path="$new_path" 46303 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46304 unix_path=`$CYGPATH -u "$windows_path"` 46305 new_path="$unix_path" 46306 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46307 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46308 new_path="$unix_path" 46309 fi 46310 46311 46312 # Now try to locate executable using which 46313 new_path=`$WHICH "$new_path" 2> /dev/null` 46314 46315 if test "x$new_path" = x; then 46316 # Oops. Which didn't find the executable. 46317 # The splitting of arguments from the executable at a space might have been incorrect, 46318 # since paths with space are more likely in Windows. Give it another try with the whole 46319 # argument. 46320 path="$complete" 46321 arguments="EOL" 46322 new_path="$path" 46323 46324 windows_path="$new_path" 46325 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46326 unix_path=`$CYGPATH -u "$windows_path"` 46327 new_path="$unix_path" 46328 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46329 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46330 new_path="$unix_path" 46331 fi 46332 46333 46334 new_path=`$WHICH "$new_path" 2> /dev/null` 46335 # bat and cmd files are not always considered executable in MSYS causing which 46336 # to not find them 46337 if test "x$new_path" = x \ 46338 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46339 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46340 new_path="$path" 46341 46342 windows_path="$new_path" 46343 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46344 unix_path=`$CYGPATH -u "$windows_path"` 46345 new_path="$unix_path" 46346 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46347 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46348 new_path="$unix_path" 46349 fi 46350 46351 fi 46352 46353 if test "x$new_path" = x; then 46354 # It's still not found. Now this is an unrecoverable error. 46355 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 46356 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 46357 has_space=`$ECHO "$complete" | $GREP " "` 46358 if test "x$has_space" != x; then 46359 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46360 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46361 fi 46362 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 46363 fi 46364 fi 46365 46366 # Now new_path has a complete unix path to the binary 46367 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46368 # Keep paths in /bin as-is, but remove trailing .exe if any 46369 new_path="${new_path/%.exe/}" 46370 # Do not save /bin paths to all_fixpath_prefixes! 46371 else 46372 # Not in mixed or Windows style, start by that. 46373 new_path=`cmd //c echo $new_path` 46374 46375 input_path="$new_path" 46376 # Check if we need to convert this using DOS-style short mode. If the path 46377 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46378 # take no chances and rewrite it. 46379 # Note: m4 eats our [], so we need to use [ and ] instead. 46380 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46381 if test "x$has_forbidden_chars" != x; then 46382 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46383 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46384 fi 46385 46386 # Output is in $new_path 46387 46388 windows_path="$new_path" 46389 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46390 unix_path=`$CYGPATH -u "$windows_path"` 46391 new_path="$unix_path" 46392 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46393 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46394 new_path="$unix_path" 46395 fi 46396 46397 # remove trailing .exe if any 46398 new_path="${new_path/%.exe/}" 46399 46400 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46401 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46402 fi 46403 46404 else 46405 # We're on a unix platform. Hooray! :) 46406 # First separate the path from the arguments. This will split at the first 46407 # space. 46408 complete="$BUILD_NM" 46409 path="${complete%% *}" 46410 tmp="$complete EOL" 46411 arguments="${tmp#* }" 46412 46413 # Cannot rely on the command "which" here since it doesn't always work. 46414 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46415 if test -z "$is_absolute_path"; then 46416 # Path to executable is not absolute. Find it. 46417 IFS_save="$IFS" 46418 IFS=: 46419 for p in $PATH; do 46420 if test -f "$p/$path" && test -x "$p/$path"; then 46421 new_path="$p/$path" 46422 break 46423 fi 46424 done 46425 IFS="$IFS_save" 46426 else 46427 # This is an absolute path, we can use it without further modifications. 46428 new_path="$path" 46429 fi 46430 46431 if test "x$new_path" = x; then 46432 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 46433 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 46434 has_space=`$ECHO "$complete" | $GREP " "` 46435 if test "x$has_space" != x; then 46436 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46437 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46438 fi 46439 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 46440 fi 46441 fi 46442 46443 # Now join together the path and the arguments once again 46444 if test "x$arguments" != xEOL; then 46445 new_complete="$new_path ${arguments% *}" 46446 else 46447 new_complete="$new_path" 46448 fi 46449 46450 if test "x$complete" != "x$new_complete"; then 46451 BUILD_NM="$new_complete" 46452 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_NM to \"$new_complete\"" >&5 46453 $as_echo "$as_me: Rewriting BUILD_NM to \"$new_complete\"" >&6;} 46454 fi 46455 fi 46456 46457 46458 46459 # Publish this variable in the help. 46460 46461 46462 if [ -z "${BUILD_AR+x}" ]; then 46463 # The variable is not set by user, try to locate tool using the code snippet 46464 for ac_prog in ar gcc-ar 46465 do 46466 # Extract the first word of "$ac_prog", so it can be a program name with args. 46467 set dummy $ac_prog; ac_word=$2 46468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46469 $as_echo_n "checking for $ac_word... " >&6; } 46470 if ${ac_cv_path_BUILD_AR+:} false; then : 46471 $as_echo_n "(cached) " >&6 46472 else 46473 case $BUILD_AR in 46474 [\\/]* | ?:[\\/]*) 46475 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 46476 ;; 46477 *) 46478 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46479 for as_dir in $PATH 46480 do 46481 IFS=$as_save_IFS 46482 test -z "$as_dir" && as_dir=. 46483 for ac_exec_ext in '' $ac_executable_extensions; do 46484 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46485 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 46486 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46487 break 2 46488 fi 46489 done 46490 done 46491 IFS=$as_save_IFS 46492 46493 ;; 46494 esac 46495 fi 46496 BUILD_AR=$ac_cv_path_BUILD_AR 46497 if test -n "$BUILD_AR"; then 46498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 46499 $as_echo "$BUILD_AR" >&6; } 46500 else 46501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46502 $as_echo "no" >&6; } 46503 fi 46504 46505 46506 test -n "$BUILD_AR" && break 46507 done 46508 46509 else 46510 # The variable is set, but is it from the command line or the environment? 46511 46512 # Try to remove the string !BUILD_AR! from our list. 46513 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_AR!/} 46514 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46515 # If it failed, the variable was not from the command line. Ignore it, 46516 # but warn the user (except for BASH, which is always set by the calling BASH). 46517 if test "xBUILD_AR" != xBASH; then 46518 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&5 46519 $as_echo "$as_me: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&2;} 46520 fi 46521 # Try to locate tool using the code snippet 46522 for ac_prog in ar gcc-ar 46523 do 46524 # Extract the first word of "$ac_prog", so it can be a program name with args. 46525 set dummy $ac_prog; ac_word=$2 46526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46527 $as_echo_n "checking for $ac_word... " >&6; } 46528 if ${ac_cv_path_BUILD_AR+:} false; then : 46529 $as_echo_n "(cached) " >&6 46530 else 46531 case $BUILD_AR in 46532 [\\/]* | ?:[\\/]*) 46533 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 46534 ;; 46535 *) 46536 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46537 for as_dir in $PATH 46538 do 46539 IFS=$as_save_IFS 46540 test -z "$as_dir" && as_dir=. 46541 for ac_exec_ext in '' $ac_executable_extensions; do 46542 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46543 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 46544 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46545 break 2 46546 fi 46547 done 46548 done 46549 IFS=$as_save_IFS 46550 46551 ;; 46552 esac 46553 fi 46554 BUILD_AR=$ac_cv_path_BUILD_AR 46555 if test -n "$BUILD_AR"; then 46556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 46557 $as_echo "$BUILD_AR" >&6; } 46558 else 46559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46560 $as_echo "no" >&6; } 46561 fi 46562 46563 46564 test -n "$BUILD_AR" && break 46565 done 46566 46567 else 46568 # If it succeeded, then it was overridden by the user. We will use it 46569 # for the tool. 46570 46571 # First remove it from the list of overridden variables, so we can test 46572 # for unknown variables in the end. 46573 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46574 46575 # Check if we try to supply an empty value 46576 if test "x$BUILD_AR" = x; then 46577 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_AR= (no value)" >&5 46578 $as_echo "$as_me: Setting user supplied tool BUILD_AR= (no value)" >&6;} 46579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 46580 $as_echo_n "checking for BUILD_AR... " >&6; } 46581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46582 $as_echo "disabled" >&6; } 46583 else 46584 # Check if the provided tool contains a complete path. 46585 tool_specified="$BUILD_AR" 46586 tool_basename="${tool_specified##*/}" 46587 if test "x$tool_basename" = "x$tool_specified"; then 46588 # A command without a complete path is provided, search $PATH. 46589 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_AR=$tool_basename" >&5 46590 $as_echo "$as_me: Will search for user supplied tool BUILD_AR=$tool_basename" >&6;} 46591 # Extract the first word of "$tool_basename", so it can be a program name with args. 46592 set dummy $tool_basename; ac_word=$2 46593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46594 $as_echo_n "checking for $ac_word... " >&6; } 46595 if ${ac_cv_path_BUILD_AR+:} false; then : 46596 $as_echo_n "(cached) " >&6 46597 else 46598 case $BUILD_AR in 46599 [\\/]* | ?:[\\/]*) 46600 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 46601 ;; 46602 *) 46603 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46604 for as_dir in $PATH 46605 do 46606 IFS=$as_save_IFS 46607 test -z "$as_dir" && as_dir=. 46608 for ac_exec_ext in '' $ac_executable_extensions; do 46609 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46610 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 46611 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46612 break 2 46613 fi 46614 done 46615 done 46616 IFS=$as_save_IFS 46617 46618 ;; 46619 esac 46620 fi 46621 BUILD_AR=$ac_cv_path_BUILD_AR 46622 if test -n "$BUILD_AR"; then 46623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 46624 $as_echo "$BUILD_AR" >&6; } 46625 else 46626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46627 $as_echo "no" >&6; } 46628 fi 46629 46630 46631 if test "x$BUILD_AR" = x; then 46632 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46633 fi 46634 else 46635 # Otherwise we believe it is a complete path. Use it as it is. 46636 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_AR=$tool_specified" >&5 46637 $as_echo "$as_me: Will use user supplied tool BUILD_AR=$tool_specified" >&6;} 46638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 46639 $as_echo_n "checking for BUILD_AR... " >&6; } 46640 if test ! -x "$tool_specified"; then 46641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46642 $as_echo "not found" >&6; } 46643 as_fn_error $? "User supplied tool BUILD_AR=$tool_specified does not exist or is not executable" "$LINENO" 5 46644 fi 46645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46646 $as_echo "$tool_specified" >&6; } 46647 fi 46648 fi 46649 fi 46650 46651 fi 46652 46653 46654 46655 # Only process if variable expands to non-empty 46656 46657 if test "x$BUILD_AR" != x; then 46658 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46659 46660 # First separate the path from the arguments. This will split at the first 46661 # space. 46662 complete="$BUILD_AR" 46663 path="${complete%% *}" 46664 tmp="$complete EOL" 46665 arguments="${tmp#* }" 46666 46667 # Input might be given as Windows format, start by converting to 46668 # unix format. 46669 new_path=`$CYGPATH -u "$path"` 46670 46671 # Now try to locate executable using which 46672 new_path=`$WHICH "$new_path" 2> /dev/null` 46673 # bat and cmd files are not always considered executable in cygwin causing which 46674 # to not find them 46675 if test "x$new_path" = x \ 46676 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46677 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46678 new_path=`$CYGPATH -u "$path"` 46679 fi 46680 if test "x$new_path" = x; then 46681 # Oops. Which didn't find the executable. 46682 # The splitting of arguments from the executable at a space might have been incorrect, 46683 # since paths with space are more likely in Windows. Give it another try with the whole 46684 # argument. 46685 path="$complete" 46686 arguments="EOL" 46687 new_path=`$CYGPATH -u "$path"` 46688 new_path=`$WHICH "$new_path" 2> /dev/null` 46689 # bat and cmd files are not always considered executable in cygwin causing which 46690 # to not find them 46691 if test "x$new_path" = x \ 46692 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46693 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46694 new_path=`$CYGPATH -u "$path"` 46695 fi 46696 if test "x$new_path" = x; then 46697 # It's still not found. Now this is an unrecoverable error. 46698 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 46699 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 46700 has_space=`$ECHO "$complete" | $GREP " "` 46701 if test "x$has_space" != x; then 46702 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46703 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46704 fi 46705 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46706 fi 46707 fi 46708 46709 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46710 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46711 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46712 # "foo.exe" is OK but "foo" is an error. 46713 # 46714 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46715 # It is also a way to make sure we got the proper file name for the real test later on. 46716 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46717 if test "x$test_shortpath" = x; then 46718 # Short path failed, file does not exist as specified. 46719 # Try adding .exe or .cmd 46720 if test -f "${new_path}.exe"; then 46721 input_to_shortpath="${new_path}.exe" 46722 elif test -f "${new_path}.cmd"; then 46723 input_to_shortpath="${new_path}.cmd" 46724 else 46725 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&5 46726 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&6;} 46727 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46728 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46729 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46730 fi 46731 else 46732 input_to_shortpath="$new_path" 46733 fi 46734 46735 # Call helper function which possibly converts this using DOS-style short mode. 46736 # If so, the updated path is stored in $new_path. 46737 new_path="$input_to_shortpath" 46738 46739 input_path="$input_to_shortpath" 46740 # Check if we need to convert this using DOS-style short mode. If the path 46741 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46742 # take no chances and rewrite it. 46743 # Note: m4 eats our [], so we need to use [ and ] instead. 46744 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46745 if test "x$has_forbidden_chars" != x; then 46746 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46747 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46748 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46749 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46750 # Going to short mode and back again did indeed matter. Since short mode is 46751 # case insensitive, let's make it lowercase to improve readability. 46752 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46753 # Now convert it back to Unix-style (cygpath) 46754 input_path=`$CYGPATH -u "$shortmode_path"` 46755 new_path="$input_path" 46756 fi 46757 fi 46758 46759 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46760 if test "x$test_cygdrive_prefix" = x; then 46761 # As a simple fix, exclude /usr/bin since it's not a real path. 46762 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46763 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46764 # a path prefixed by /cygdrive for fixpath to work. 46765 new_path="$CYGWIN_ROOT_PATH$input_path" 46766 fi 46767 fi 46768 46769 # remove trailing .exe if any 46770 new_path="${new_path/%.exe/}" 46771 46772 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46773 46774 # First separate the path from the arguments. This will split at the first 46775 # space. 46776 complete="$BUILD_AR" 46777 path="${complete%% *}" 46778 tmp="$complete EOL" 46779 arguments="${tmp#* }" 46780 46781 # Input might be given as Windows format, start by converting to 46782 # unix format. 46783 new_path="$path" 46784 46785 windows_path="$new_path" 46786 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46787 unix_path=`$CYGPATH -u "$windows_path"` 46788 new_path="$unix_path" 46789 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46790 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46791 new_path="$unix_path" 46792 fi 46793 46794 46795 # Now try to locate executable using which 46796 new_path=`$WHICH "$new_path" 2> /dev/null` 46797 46798 if test "x$new_path" = x; then 46799 # Oops. Which didn't find the executable. 46800 # The splitting of arguments from the executable at a space might have been incorrect, 46801 # since paths with space are more likely in Windows. Give it another try with the whole 46802 # argument. 46803 path="$complete" 46804 arguments="EOL" 46805 new_path="$path" 46806 46807 windows_path="$new_path" 46808 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46809 unix_path=`$CYGPATH -u "$windows_path"` 46810 new_path="$unix_path" 46811 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46812 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46813 new_path="$unix_path" 46814 fi 46815 46816 46817 new_path=`$WHICH "$new_path" 2> /dev/null` 46818 # bat and cmd files are not always considered executable in MSYS causing which 46819 # to not find them 46820 if test "x$new_path" = x \ 46821 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46822 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46823 new_path="$path" 46824 46825 windows_path="$new_path" 46826 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46827 unix_path=`$CYGPATH -u "$windows_path"` 46828 new_path="$unix_path" 46829 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46830 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46831 new_path="$unix_path" 46832 fi 46833 46834 fi 46835 46836 if test "x$new_path" = x; then 46837 # It's still not found. Now this is an unrecoverable error. 46838 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 46839 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 46840 has_space=`$ECHO "$complete" | $GREP " "` 46841 if test "x$has_space" != x; then 46842 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46843 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46844 fi 46845 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46846 fi 46847 fi 46848 46849 # Now new_path has a complete unix path to the binary 46850 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46851 # Keep paths in /bin as-is, but remove trailing .exe if any 46852 new_path="${new_path/%.exe/}" 46853 # Do not save /bin paths to all_fixpath_prefixes! 46854 else 46855 # Not in mixed or Windows style, start by that. 46856 new_path=`cmd //c echo $new_path` 46857 46858 input_path="$new_path" 46859 # Check if we need to convert this using DOS-style short mode. If the path 46860 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46861 # take no chances and rewrite it. 46862 # Note: m4 eats our [], so we need to use [ and ] instead. 46863 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46864 if test "x$has_forbidden_chars" != x; then 46865 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46866 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46867 fi 46868 46869 # Output is in $new_path 46870 46871 windows_path="$new_path" 46872 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46873 unix_path=`$CYGPATH -u "$windows_path"` 46874 new_path="$unix_path" 46875 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46876 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46877 new_path="$unix_path" 46878 fi 46879 46880 # remove trailing .exe if any 46881 new_path="${new_path/%.exe/}" 46882 46883 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46884 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46885 fi 46886 46887 else 46888 # We're on a unix platform. Hooray! :) 46889 # First separate the path from the arguments. This will split at the first 46890 # space. 46891 complete="$BUILD_AR" 46892 path="${complete%% *}" 46893 tmp="$complete EOL" 46894 arguments="${tmp#* }" 46895 46896 # Cannot rely on the command "which" here since it doesn't always work. 46897 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46898 if test -z "$is_absolute_path"; then 46899 # Path to executable is not absolute. Find it. 46900 IFS_save="$IFS" 46901 IFS=: 46902 for p in $PATH; do 46903 if test -f "$p/$path" && test -x "$p/$path"; then 46904 new_path="$p/$path" 46905 break 46906 fi 46907 done 46908 IFS="$IFS_save" 46909 else 46910 # This is an absolute path, we can use it without further modifications. 46911 new_path="$path" 46912 fi 46913 46914 if test "x$new_path" = x; then 46915 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 46916 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 46917 has_space=`$ECHO "$complete" | $GREP " "` 46918 if test "x$has_space" != x; then 46919 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46920 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46921 fi 46922 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46923 fi 46924 fi 46925 46926 # Now join together the path and the arguments once again 46927 if test "x$arguments" != xEOL; then 46928 new_complete="$new_path ${arguments% *}" 46929 else 46930 new_complete="$new_path" 46931 fi 46932 46933 if test "x$complete" != "x$new_complete"; then 46934 BUILD_AR="$new_complete" 46935 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_AR to \"$new_complete\"" >&5 46936 $as_echo "$as_me: Rewriting BUILD_AR to \"$new_complete\"" >&6;} 46937 fi 46938 fi 46939 46940 46941 46942 # Publish this variable in the help. 46943 46944 46945 if [ -z "${BUILD_OBJCOPY+x}" ]; then 46946 # The variable is not set by user, try to locate tool using the code snippet 46947 for ac_prog in objcopy 46948 do 46949 # Extract the first word of "$ac_prog", so it can be a program name with args. 46950 set dummy $ac_prog; ac_word=$2 46951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46952 $as_echo_n "checking for $ac_word... " >&6; } 46953 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46954 $as_echo_n "(cached) " >&6 46955 else 46956 case $BUILD_OBJCOPY in 46957 [\\/]* | ?:[\\/]*) 46958 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46959 ;; 46960 *) 46961 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46962 for as_dir in $PATH 46963 do 46964 IFS=$as_save_IFS 46965 test -z "$as_dir" && as_dir=. 46966 for ac_exec_ext in '' $ac_executable_extensions; do 46967 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46968 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46969 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46970 break 2 46971 fi 46972 done 46973 done 46974 IFS=$as_save_IFS 46975 46976 ;; 46977 esac 46978 fi 46979 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46980 if test -n "$BUILD_OBJCOPY"; then 46981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46982 $as_echo "$BUILD_OBJCOPY" >&6; } 46983 else 46984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46985 $as_echo "no" >&6; } 46986 fi 46987 46988 46989 test -n "$BUILD_OBJCOPY" && break 46990 done 46991 46992 else 46993 # The variable is set, but is it from the command line or the environment? 46994 46995 # Try to remove the string !BUILD_OBJCOPY! from our list. 46996 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_OBJCOPY!/} 46997 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46998 # If it failed, the variable was not from the command line. Ignore it, 46999 # but warn the user (except for BASH, which is always set by the calling BASH). 47000 if test "xBUILD_OBJCOPY" != xBASH; then 47001 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&5 47002 $as_echo "$as_me: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&2;} 47003 fi 47004 # Try to locate tool using the code snippet 47005 for ac_prog in objcopy 47006 do 47007 # Extract the first word of "$ac_prog", so it can be a program name with args. 47008 set dummy $ac_prog; ac_word=$2 47009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47010 $as_echo_n "checking for $ac_word... " >&6; } 47011 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 47012 $as_echo_n "(cached) " >&6 47013 else 47014 case $BUILD_OBJCOPY in 47015 [\\/]* | ?:[\\/]*) 47016 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 47017 ;; 47018 *) 47019 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47020 for as_dir in $PATH 47021 do 47022 IFS=$as_save_IFS 47023 test -z "$as_dir" && as_dir=. 47024 for ac_exec_ext in '' $ac_executable_extensions; do 47025 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47026 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 47027 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47028 break 2 47029 fi 47030 done 47031 done 47032 IFS=$as_save_IFS 47033 47034 ;; 47035 esac 47036 fi 47037 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 47038 if test -n "$BUILD_OBJCOPY"; then 47039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 47040 $as_echo "$BUILD_OBJCOPY" >&6; } 47041 else 47042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47043 $as_echo "no" >&6; } 47044 fi 47045 47046 47047 test -n "$BUILD_OBJCOPY" && break 47048 done 47049 47050 else 47051 # If it succeeded, then it was overridden by the user. We will use it 47052 # for the tool. 47053 47054 # First remove it from the list of overridden variables, so we can test 47055 # for unknown variables in the end. 47056 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 47057 47058 # Check if we try to supply an empty value 47059 if test "x$BUILD_OBJCOPY" = x; then 47060 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&5 47061 $as_echo "$as_me: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&6;} 47062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 47063 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 47064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 47065 $as_echo "disabled" >&6; } 47066 else 47067 # Check if the provided tool contains a complete path. 47068 tool_specified="$BUILD_OBJCOPY" 47069 tool_basename="${tool_specified##*/}" 47070 if test "x$tool_basename" = "x$tool_specified"; then 47071 # A command without a complete path is provided, search $PATH. 47072 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&5 47073 $as_echo "$as_me: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&6;} 47074 # Extract the first word of "$tool_basename", so it can be a program name with args. 47075 set dummy $tool_basename; ac_word=$2 47076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47077 $as_echo_n "checking for $ac_word... " >&6; } 47078 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 47079 $as_echo_n "(cached) " >&6 47080 else 47081 case $BUILD_OBJCOPY in 47082 [\\/]* | ?:[\\/]*) 47083 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 47084 ;; 47085 *) 47086 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47087 for as_dir in $PATH 47088 do 47089 IFS=$as_save_IFS 47090 test -z "$as_dir" && as_dir=. 47091 for ac_exec_ext in '' $ac_executable_extensions; do 47092 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47093 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 47094 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47095 break 2 47096 fi 47097 done 47098 done 47099 IFS=$as_save_IFS 47100 47101 ;; 47102 esac 47103 fi 47104 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 47105 if test -n "$BUILD_OBJCOPY"; then 47106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 47107 $as_echo "$BUILD_OBJCOPY" >&6; } 47108 else 47109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47110 $as_echo "no" >&6; } 47111 fi 47112 47113 47114 if test "x$BUILD_OBJCOPY" = x; then 47115 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 47116 fi 47117 else 47118 # Otherwise we believe it is a complete path. Use it as it is. 47119 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&5 47120 $as_echo "$as_me: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&6;} 47121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 47122 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 47123 if test ! -x "$tool_specified"; then 47124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 47125 $as_echo "not found" >&6; } 47126 as_fn_error $? "User supplied tool BUILD_OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 47127 fi 47128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 47129 $as_echo "$tool_specified" >&6; } 47130 fi 47131 fi 47132 fi 47133 47134 fi 47135 47136 47137 47138 # Only process if variable expands to non-empty 47139 47140 if test "x$BUILD_OBJCOPY" != x; then 47141 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47142 47143 # First separate the path from the arguments. This will split at the first 47144 # space. 47145 complete="$BUILD_OBJCOPY" 47146 path="${complete%% *}" 47147 tmp="$complete EOL" 47148 arguments="${tmp#* }" 47149 47150 # Input might be given as Windows format, start by converting to 47151 # unix format. 47152 new_path=`$CYGPATH -u "$path"` 47153 47154 # Now try to locate executable using which 47155 new_path=`$WHICH "$new_path" 2> /dev/null` 47156 # bat and cmd files are not always considered executable in cygwin causing which 47157 # to not find them 47158 if test "x$new_path" = x \ 47159 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47160 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47161 new_path=`$CYGPATH -u "$path"` 47162 fi 47163 if test "x$new_path" = x; then 47164 # Oops. Which didn't find the executable. 47165 # The splitting of arguments from the executable at a space might have been incorrect, 47166 # since paths with space are more likely in Windows. Give it another try with the whole 47167 # argument. 47168 path="$complete" 47169 arguments="EOL" 47170 new_path=`$CYGPATH -u "$path"` 47171 new_path=`$WHICH "$new_path" 2> /dev/null` 47172 # bat and cmd files are not always considered executable in cygwin causing which 47173 # to not find them 47174 if test "x$new_path" = x \ 47175 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47176 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47177 new_path=`$CYGPATH -u "$path"` 47178 fi 47179 if test "x$new_path" = x; then 47180 # It's still not found. Now this is an unrecoverable error. 47181 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 47182 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 47183 has_space=`$ECHO "$complete" | $GREP " "` 47184 if test "x$has_space" != x; then 47185 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47186 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47187 fi 47188 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 47189 fi 47190 fi 47191 47192 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 47193 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 47194 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 47195 # "foo.exe" is OK but "foo" is an error. 47196 # 47197 # This test is therefore slightly more accurate than "test -f" to check for file presence. 47198 # It is also a way to make sure we got the proper file name for the real test later on. 47199 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 47200 if test "x$test_shortpath" = x; then 47201 # Short path failed, file does not exist as specified. 47202 # Try adding .exe or .cmd 47203 if test -f "${new_path}.exe"; then 47204 input_to_shortpath="${new_path}.exe" 47205 elif test -f "${new_path}.cmd"; then 47206 input_to_shortpath="${new_path}.cmd" 47207 else 47208 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 47209 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 47210 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 47211 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 47212 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 47213 fi 47214 else 47215 input_to_shortpath="$new_path" 47216 fi 47217 47218 # Call helper function which possibly converts this using DOS-style short mode. 47219 # If so, the updated path is stored in $new_path. 47220 new_path="$input_to_shortpath" 47221 47222 input_path="$input_to_shortpath" 47223 # Check if we need to convert this using DOS-style short mode. If the path 47224 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47225 # take no chances and rewrite it. 47226 # Note: m4 eats our [], so we need to use [ and ] instead. 47227 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 47228 if test "x$has_forbidden_chars" != x; then 47229 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47230 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 47231 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 47232 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 47233 # Going to short mode and back again did indeed matter. Since short mode is 47234 # case insensitive, let's make it lowercase to improve readability. 47235 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47236 # Now convert it back to Unix-style (cygpath) 47237 input_path=`$CYGPATH -u "$shortmode_path"` 47238 new_path="$input_path" 47239 fi 47240 fi 47241 47242 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 47243 if test "x$test_cygdrive_prefix" = x; then 47244 # As a simple fix, exclude /usr/bin since it's not a real path. 47245 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 47246 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 47247 # a path prefixed by /cygdrive for fixpath to work. 47248 new_path="$CYGWIN_ROOT_PATH$input_path" 47249 fi 47250 fi 47251 47252 # remove trailing .exe if any 47253 new_path="${new_path/%.exe/}" 47254 47255 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47256 47257 # First separate the path from the arguments. This will split at the first 47258 # space. 47259 complete="$BUILD_OBJCOPY" 47260 path="${complete%% *}" 47261 tmp="$complete EOL" 47262 arguments="${tmp#* }" 47263 47264 # Input might be given as Windows format, start by converting to 47265 # unix format. 47266 new_path="$path" 47267 47268 windows_path="$new_path" 47269 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47270 unix_path=`$CYGPATH -u "$windows_path"` 47271 new_path="$unix_path" 47272 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47273 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47274 new_path="$unix_path" 47275 fi 47276 47277 47278 # Now try to locate executable using which 47279 new_path=`$WHICH "$new_path" 2> /dev/null` 47280 47281 if test "x$new_path" = x; then 47282 # Oops. Which didn't find the executable. 47283 # The splitting of arguments from the executable at a space might have been incorrect, 47284 # since paths with space are more likely in Windows. Give it another try with the whole 47285 # argument. 47286 path="$complete" 47287 arguments="EOL" 47288 new_path="$path" 47289 47290 windows_path="$new_path" 47291 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47292 unix_path=`$CYGPATH -u "$windows_path"` 47293 new_path="$unix_path" 47294 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47295 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47296 new_path="$unix_path" 47297 fi 47298 47299 47300 new_path=`$WHICH "$new_path" 2> /dev/null` 47301 # bat and cmd files are not always considered executable in MSYS causing which 47302 # to not find them 47303 if test "x$new_path" = x \ 47304 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47305 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47306 new_path="$path" 47307 47308 windows_path="$new_path" 47309 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47310 unix_path=`$CYGPATH -u "$windows_path"` 47311 new_path="$unix_path" 47312 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47313 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47314 new_path="$unix_path" 47315 fi 47316 47317 fi 47318 47319 if test "x$new_path" = x; then 47320 # It's still not found. Now this is an unrecoverable error. 47321 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 47322 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 47323 has_space=`$ECHO "$complete" | $GREP " "` 47324 if test "x$has_space" != x; then 47325 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47326 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47327 fi 47328 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 47329 fi 47330 fi 47331 47332 # Now new_path has a complete unix path to the binary 47333 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 47334 # Keep paths in /bin as-is, but remove trailing .exe if any 47335 new_path="${new_path/%.exe/}" 47336 # Do not save /bin paths to all_fixpath_prefixes! 47337 else 47338 # Not in mixed or Windows style, start by that. 47339 new_path=`cmd //c echo $new_path` 47340 47341 input_path="$new_path" 47342 # Check if we need to convert this using DOS-style short mode. If the path 47343 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47344 # take no chances and rewrite it. 47345 # Note: m4 eats our [], so we need to use [ and ] instead. 47346 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 47347 if test "x$has_forbidden_chars" != x; then 47348 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47349 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47350 fi 47351 47352 # Output is in $new_path 47353 47354 windows_path="$new_path" 47355 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47356 unix_path=`$CYGPATH -u "$windows_path"` 47357 new_path="$unix_path" 47358 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47359 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47360 new_path="$unix_path" 47361 fi 47362 47363 # remove trailing .exe if any 47364 new_path="${new_path/%.exe/}" 47365 47366 # Save the first 10 bytes of this path to the storage, so fixpath can work. 47367 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 47368 fi 47369 47370 else 47371 # We're on a unix platform. Hooray! :) 47372 # First separate the path from the arguments. This will split at the first 47373 # space. 47374 complete="$BUILD_OBJCOPY" 47375 path="${complete%% *}" 47376 tmp="$complete EOL" 47377 arguments="${tmp#* }" 47378 47379 # Cannot rely on the command "which" here since it doesn't always work. 47380 is_absolute_path=`$ECHO "$path" | $GREP ^/` 47381 if test -z "$is_absolute_path"; then 47382 # Path to executable is not absolute. Find it. 47383 IFS_save="$IFS" 47384 IFS=: 47385 for p in $PATH; do 47386 if test -f "$p/$path" && test -x "$p/$path"; then 47387 new_path="$p/$path" 47388 break 47389 fi 47390 done 47391 IFS="$IFS_save" 47392 else 47393 # This is an absolute path, we can use it without further modifications. 47394 new_path="$path" 47395 fi 47396 47397 if test "x$new_path" = x; then 47398 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 47399 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 47400 has_space=`$ECHO "$complete" | $GREP " "` 47401 if test "x$has_space" != x; then 47402 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 47403 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 47404 fi 47405 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 47406 fi 47407 fi 47408 47409 # Now join together the path and the arguments once again 47410 if test "x$arguments" != xEOL; then 47411 new_complete="$new_path ${arguments% *}" 47412 else 47413 new_complete="$new_path" 47414 fi 47415 47416 if test "x$complete" != "x$new_complete"; then 47417 BUILD_OBJCOPY="$new_complete" 47418 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&5 47419 $as_echo "$as_me: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&6;} 47420 fi 47421 fi 47422 47423 47424 47425 # Publish this variable in the help. 47426 47427 47428 if [ -z "${BUILD_STRIP+x}" ]; then 47429 # The variable is not set by user, try to locate tool using the code snippet 47430 for ac_prog in strip 47431 do 47432 # Extract the first word of "$ac_prog", so it can be a program name with args. 47433 set dummy $ac_prog; ac_word=$2 47434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47435 $as_echo_n "checking for $ac_word... " >&6; } 47436 if ${ac_cv_path_BUILD_STRIP+:} false; then : 47437 $as_echo_n "(cached) " >&6 47438 else 47439 case $BUILD_STRIP in 47440 [\\/]* | ?:[\\/]*) 47441 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 47442 ;; 47443 *) 47444 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47445 for as_dir in $PATH 47446 do 47447 IFS=$as_save_IFS 47448 test -z "$as_dir" && as_dir=. 47449 for ac_exec_ext in '' $ac_executable_extensions; do 47450 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47451 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 47452 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47453 break 2 47454 fi 47455 done 47456 done 47457 IFS=$as_save_IFS 47458 47459 ;; 47460 esac 47461 fi 47462 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 47463 if test -n "$BUILD_STRIP"; then 47464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 47465 $as_echo "$BUILD_STRIP" >&6; } 47466 else 47467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47468 $as_echo "no" >&6; } 47469 fi 47470 47471 47472 test -n "$BUILD_STRIP" && break 47473 done 47474 47475 else 47476 # The variable is set, but is it from the command line or the environment? 47477 47478 # Try to remove the string !BUILD_STRIP! from our list. 47479 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_STRIP!/} 47480 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 47481 # If it failed, the variable was not from the command line. Ignore it, 47482 # but warn the user (except for BASH, which is always set by the calling BASH). 47483 if test "xBUILD_STRIP" != xBASH; then 47484 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&5 47485 $as_echo "$as_me: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&2;} 47486 fi 47487 # Try to locate tool using the code snippet 47488 for ac_prog in strip 47489 do 47490 # Extract the first word of "$ac_prog", so it can be a program name with args. 47491 set dummy $ac_prog; ac_word=$2 47492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47493 $as_echo_n "checking for $ac_word... " >&6; } 47494 if ${ac_cv_path_BUILD_STRIP+:} false; then : 47495 $as_echo_n "(cached) " >&6 47496 else 47497 case $BUILD_STRIP in 47498 [\\/]* | ?:[\\/]*) 47499 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 47500 ;; 47501 *) 47502 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47503 for as_dir in $PATH 47504 do 47505 IFS=$as_save_IFS 47506 test -z "$as_dir" && as_dir=. 47507 for ac_exec_ext in '' $ac_executable_extensions; do 47508 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47509 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 47510 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47511 break 2 47512 fi 47513 done 47514 done 47515 IFS=$as_save_IFS 47516 47517 ;; 47518 esac 47519 fi 47520 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 47521 if test -n "$BUILD_STRIP"; then 47522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 47523 $as_echo "$BUILD_STRIP" >&6; } 47524 else 47525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47526 $as_echo "no" >&6; } 47527 fi 47528 47529 47530 test -n "$BUILD_STRIP" && break 47531 done 47532 47533 else 47534 # If it succeeded, then it was overridden by the user. We will use it 47535 # for the tool. 47536 47537 # First remove it from the list of overridden variables, so we can test 47538 # for unknown variables in the end. 47539 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 47540 47541 # Check if we try to supply an empty value 47542 if test "x$BUILD_STRIP" = x; then 47543 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_STRIP= (no value)" >&5 47544 $as_echo "$as_me: Setting user supplied tool BUILD_STRIP= (no value)" >&6;} 47545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 47546 $as_echo_n "checking for BUILD_STRIP... " >&6; } 47547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 47548 $as_echo "disabled" >&6; } 47549 else 47550 # Check if the provided tool contains a complete path. 47551 tool_specified="$BUILD_STRIP" 47552 tool_basename="${tool_specified##*/}" 47553 if test "x$tool_basename" = "x$tool_specified"; then 47554 # A command without a complete path is provided, search $PATH. 47555 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&5 47556 $as_echo "$as_me: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&6;} 47557 # Extract the first word of "$tool_basename", so it can be a program name with args. 47558 set dummy $tool_basename; ac_word=$2 47559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47560 $as_echo_n "checking for $ac_word... " >&6; } 47561 if ${ac_cv_path_BUILD_STRIP+:} false; then : 47562 $as_echo_n "(cached) " >&6 47563 else 47564 case $BUILD_STRIP in 47565 [\\/]* | ?:[\\/]*) 47566 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 47567 ;; 47568 *) 47569 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47570 for as_dir in $PATH 47571 do 47572 IFS=$as_save_IFS 47573 test -z "$as_dir" && as_dir=. 47574 for ac_exec_ext in '' $ac_executable_extensions; do 47575 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47576 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 47577 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47578 break 2 47579 fi 47580 done 47581 done 47582 IFS=$as_save_IFS 47583 47584 ;; 47585 esac 47586 fi 47587 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 47588 if test -n "$BUILD_STRIP"; then 47589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 47590 $as_echo "$BUILD_STRIP" >&6; } 47591 else 47592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47593 $as_echo "no" >&6; } 47594 fi 47595 47596 47597 if test "x$BUILD_STRIP" = x; then 47598 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 47599 fi 47600 else 47601 # Otherwise we believe it is a complete path. Use it as it is. 47602 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_STRIP=$tool_specified" >&5 47603 $as_echo "$as_me: Will use user supplied tool BUILD_STRIP=$tool_specified" >&6;} 47604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 47605 $as_echo_n "checking for BUILD_STRIP... " >&6; } 47606 if test ! -x "$tool_specified"; then 47607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 47608 $as_echo "not found" >&6; } 47609 as_fn_error $? "User supplied tool BUILD_STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 47610 fi 47611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 47612 $as_echo "$tool_specified" >&6; } 47613 fi 47614 fi 47615 fi 47616 47617 fi 47618 47619 47620 47621 # Only process if variable expands to non-empty 47622 47623 if test "x$BUILD_STRIP" != x; then 47624 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47625 47626 # First separate the path from the arguments. This will split at the first 47627 # space. 47628 complete="$BUILD_STRIP" 47629 path="${complete%% *}" 47630 tmp="$complete EOL" 47631 arguments="${tmp#* }" 47632 47633 # Input might be given as Windows format, start by converting to 47634 # unix format. 47635 new_path=`$CYGPATH -u "$path"` 47636 47637 # Now try to locate executable using which 47638 new_path=`$WHICH "$new_path" 2> /dev/null` 47639 # bat and cmd files are not always considered executable in cygwin causing which 47640 # to not find them 47641 if test "x$new_path" = x \ 47642 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47643 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47644 new_path=`$CYGPATH -u "$path"` 47645 fi 47646 if test "x$new_path" = x; then 47647 # Oops. Which didn't find the executable. 47648 # The splitting of arguments from the executable at a space might have been incorrect, 47649 # since paths with space are more likely in Windows. Give it another try with the whole 47650 # argument. 47651 path="$complete" 47652 arguments="EOL" 47653 new_path=`$CYGPATH -u "$path"` 47654 new_path=`$WHICH "$new_path" 2> /dev/null` 47655 # bat and cmd files are not always considered executable in cygwin causing which 47656 # to not find them 47657 if test "x$new_path" = x \ 47658 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47659 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47660 new_path=`$CYGPATH -u "$path"` 47661 fi 47662 if test "x$new_path" = x; then 47663 # It's still not found. Now this is an unrecoverable error. 47664 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 47665 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 47666 has_space=`$ECHO "$complete" | $GREP " "` 47667 if test "x$has_space" != x; then 47668 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47669 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47670 fi 47671 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47672 fi 47673 fi 47674 47675 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 47676 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 47677 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 47678 # "foo.exe" is OK but "foo" is an error. 47679 # 47680 # This test is therefore slightly more accurate than "test -f" to check for file presence. 47681 # It is also a way to make sure we got the proper file name for the real test later on. 47682 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 47683 if test "x$test_shortpath" = x; then 47684 # Short path failed, file does not exist as specified. 47685 # Try adding .exe or .cmd 47686 if test -f "${new_path}.exe"; then 47687 input_to_shortpath="${new_path}.exe" 47688 elif test -f "${new_path}.cmd"; then 47689 input_to_shortpath="${new_path}.cmd" 47690 else 47691 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&5 47692 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&6;} 47693 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 47694 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 47695 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47696 fi 47697 else 47698 input_to_shortpath="$new_path" 47699 fi 47700 47701 # Call helper function which possibly converts this using DOS-style short mode. 47702 # If so, the updated path is stored in $new_path. 47703 new_path="$input_to_shortpath" 47704 47705 input_path="$input_to_shortpath" 47706 # Check if we need to convert this using DOS-style short mode. If the path 47707 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47708 # take no chances and rewrite it. 47709 # Note: m4 eats our [], so we need to use [ and ] instead. 47710 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 47711 if test "x$has_forbidden_chars" != x; then 47712 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47713 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 47714 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 47715 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 47716 # Going to short mode and back again did indeed matter. Since short mode is 47717 # case insensitive, let's make it lowercase to improve readability. 47718 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47719 # Now convert it back to Unix-style (cygpath) 47720 input_path=`$CYGPATH -u "$shortmode_path"` 47721 new_path="$input_path" 47722 fi 47723 fi 47724 47725 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 47726 if test "x$test_cygdrive_prefix" = x; then 47727 # As a simple fix, exclude /usr/bin since it's not a real path. 47728 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 47729 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 47730 # a path prefixed by /cygdrive for fixpath to work. 47731 new_path="$CYGWIN_ROOT_PATH$input_path" 47732 fi 47733 fi 47734 47735 # remove trailing .exe if any 47736 new_path="${new_path/%.exe/}" 47737 47738 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47739 47740 # First separate the path from the arguments. This will split at the first 47741 # space. 47742 complete="$BUILD_STRIP" 47743 path="${complete%% *}" 47744 tmp="$complete EOL" 47745 arguments="${tmp#* }" 47746 47747 # Input might be given as Windows format, start by converting to 47748 # unix format. 47749 new_path="$path" 47750 47751 windows_path="$new_path" 47752 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47753 unix_path=`$CYGPATH -u "$windows_path"` 47754 new_path="$unix_path" 47755 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47756 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47757 new_path="$unix_path" 47758 fi 47759 47760 47761 # Now try to locate executable using which 47762 new_path=`$WHICH "$new_path" 2> /dev/null` 47763 47764 if test "x$new_path" = x; then 47765 # Oops. Which didn't find the executable. 47766 # The splitting of arguments from the executable at a space might have been incorrect, 47767 # since paths with space are more likely in Windows. Give it another try with the whole 47768 # argument. 47769 path="$complete" 47770 arguments="EOL" 47771 new_path="$path" 47772 47773 windows_path="$new_path" 47774 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47775 unix_path=`$CYGPATH -u "$windows_path"` 47776 new_path="$unix_path" 47777 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47778 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47779 new_path="$unix_path" 47780 fi 47781 47782 47783 new_path=`$WHICH "$new_path" 2> /dev/null` 47784 # bat and cmd files are not always considered executable in MSYS causing which 47785 # to not find them 47786 if test "x$new_path" = x \ 47787 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47788 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47789 new_path="$path" 47790 47791 windows_path="$new_path" 47792 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47793 unix_path=`$CYGPATH -u "$windows_path"` 47794 new_path="$unix_path" 47795 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47796 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47797 new_path="$unix_path" 47798 fi 47799 47800 fi 47801 47802 if test "x$new_path" = x; then 47803 # It's still not found. Now this is an unrecoverable error. 47804 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 47805 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 47806 has_space=`$ECHO "$complete" | $GREP " "` 47807 if test "x$has_space" != x; then 47808 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47809 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47810 fi 47811 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47812 fi 47813 fi 47814 47815 # Now new_path has a complete unix path to the binary 47816 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 47817 # Keep paths in /bin as-is, but remove trailing .exe if any 47818 new_path="${new_path/%.exe/}" 47819 # Do not save /bin paths to all_fixpath_prefixes! 47820 else 47821 # Not in mixed or Windows style, start by that. 47822 new_path=`cmd //c echo $new_path` 47823 47824 input_path="$new_path" 47825 # Check if we need to convert this using DOS-style short mode. If the path 47826 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47827 # take no chances and rewrite it. 47828 # Note: m4 eats our [], so we need to use [ and ] instead. 47829 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 47830 if test "x$has_forbidden_chars" != x; then 47831 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47832 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47833 fi 47834 47835 # Output is in $new_path 47836 47837 windows_path="$new_path" 47838 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47839 unix_path=`$CYGPATH -u "$windows_path"` 47840 new_path="$unix_path" 47841 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47842 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47843 new_path="$unix_path" 47844 fi 47845 47846 # remove trailing .exe if any 47847 new_path="${new_path/%.exe/}" 47848 47849 # Save the first 10 bytes of this path to the storage, so fixpath can work. 47850 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 47851 fi 47852 47853 else 47854 # We're on a unix platform. Hooray! :) 47855 # First separate the path from the arguments. This will split at the first 47856 # space. 47857 complete="$BUILD_STRIP" 47858 path="${complete%% *}" 47859 tmp="$complete EOL" 47860 arguments="${tmp#* }" 47861 47862 # Cannot rely on the command "which" here since it doesn't always work. 47863 is_absolute_path=`$ECHO "$path" | $GREP ^/` 47864 if test -z "$is_absolute_path"; then 47865 # Path to executable is not absolute. Find it. 47866 IFS_save="$IFS" 47867 IFS=: 47868 for p in $PATH; do 47869 if test -f "$p/$path" && test -x "$p/$path"; then 47870 new_path="$p/$path" 47871 break 47872 fi 47873 done 47874 IFS="$IFS_save" 47875 else 47876 # This is an absolute path, we can use it without further modifications. 47877 new_path="$path" 47878 fi 47879 47880 if test "x$new_path" = x; then 47881 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 47882 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 47883 has_space=`$ECHO "$complete" | $GREP " "` 47884 if test "x$has_space" != x; then 47885 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 47886 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 47887 fi 47888 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47889 fi 47890 fi 47891 47892 # Now join together the path and the arguments once again 47893 if test "x$arguments" != xEOL; then 47894 new_complete="$new_path ${arguments% *}" 47895 else 47896 new_complete="$new_path" 47897 fi 47898 47899 if test "x$complete" != "x$new_complete"; then 47900 BUILD_STRIP="$new_complete" 47901 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_STRIP to \"$new_complete\"" >&5 47902 $as_echo "$as_me: Rewriting BUILD_STRIP to \"$new_complete\"" >&6;} 47903 fi 47904 fi 47905 47906 # Assume the C compiler is the assembler 47907 BUILD_AS="$BUILD_CC -c" 47908 # Just like for the target compiler, use the compiler as linker 47909 BUILD_LD="$BUILD_CC" 47910 BUILD_LDCXX="$BUILD_CXX" 47911 47912 PATH="$OLDPATH" 47913 47914 47915 COMPILER=$BUILD_CC 47916 COMPILER_NAME=BuildC 47917 47918 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47919 # cc -V output typically looks like 47920 # cc: Sun C 5.12 Linux_i386 2011/11/16 47921 # or 47922 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 47923 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 47924 # Check that this is likely to be the Solaris Studio cc. 47925 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 47926 if test $? -ne 0; then 47927 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47928 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 47929 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47930 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47931 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47932 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47933 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47934 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47935 fi 47936 # Remove usage instructions (if present), and 47937 # collapse compiler output into a single line 47938 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47939 $SED -e 's/ *[Uu]sage:.*//'` 47940 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47941 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 47942 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 47943 # xlc -qversion output typically looks like 47944 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 47945 # Version: 11.01.0000.0015 47946 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 47947 # Check that this is likely to be the IBM XL C compiler. 47948 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 47949 if test $? -ne 0; then 47950 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47951 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 47952 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47953 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47954 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47955 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47956 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47957 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47958 fi 47959 # Collapse compiler output into a single line 47960 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47961 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47962 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 47963 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47964 # There is no specific version flag, but all output starts with a version string. 47965 # First line typically looks something like: 47966 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 47967 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47968 # Check that this is likely to be Microsoft CL.EXE. 47969 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 47970 if test $? -ne 0; then 47971 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 47972 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47973 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47974 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47975 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47976 fi 47977 # Collapse compiler output into a single line 47978 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47979 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47980 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 47981 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47982 # gcc --version output typically looks like 47983 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 47984 # Copyright (C) 2013 Free Software Foundation, Inc. 47985 # This is free software; see the source for copying conditions. There is NO 47986 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 47987 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47988 # Check that this is likely to be GCC. 47989 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 47990 if test $? -ne 0; then 47991 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 47992 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47993 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 47994 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 47995 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47996 fi 47997 # Remove Copyright and legalese from version string, and 47998 # collapse into a single line 47999 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48000 $SED -e 's/ *Copyright .*//'` 48001 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48002 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 48003 elif test "x$TOOLCHAIN_TYPE" = xclang; then 48004 # clang --version output typically looks like 48005 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 48006 # clang version 3.3 (tags/RELEASE_33/final) 48007 # or 48008 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 48009 # Target: x86_64-pc-linux-gnu 48010 # Thread model: posix 48011 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48012 # Check that this is likely to be clang 48013 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 48014 if test $? -ne 0; then 48015 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 48016 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48017 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48018 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48019 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48020 fi 48021 # Collapse compiler output into a single line 48022 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 48023 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48024 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 48025 else 48026 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 48027 fi 48028 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 48029 BUILD_CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 48030 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 48031 BUILD_CC_VERSION_STRING="$COMPILER_VERSION_STRING" 48032 48033 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 48034 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 48035 48036 48037 COMPILER=$BUILD_CXX 48038 COMPILER_NAME=BuildC++ 48039 48040 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 48041 # cc -V output typically looks like 48042 # cc: Sun C 5.12 Linux_i386 2011/11/16 48043 # or 48044 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 48045 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 48046 # Check that this is likely to be the Solaris Studio cc. 48047 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 48048 if test $? -ne 0; then 48049 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48050 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 48051 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48052 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48053 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48054 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 48055 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 48056 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48057 fi 48058 # Remove usage instructions (if present), and 48059 # collapse compiler output into a single line 48060 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48061 $SED -e 's/ *[Uu]sage:.*//'` 48062 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48063 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 48064 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 48065 # xlc -qversion output typically looks like 48066 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 48067 # Version: 11.01.0000.0015 48068 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 48069 # Check that this is likely to be the IBM XL C compiler. 48070 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 48071 if test $? -ne 0; then 48072 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48073 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 48074 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48075 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48076 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48077 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 48078 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 48079 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48080 fi 48081 # Collapse compiler output into a single line 48082 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 48083 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48084 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 48085 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48086 # There is no specific version flag, but all output starts with a version string. 48087 # First line typically looks something like: 48088 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 48089 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 48090 # Check that this is likely to be Microsoft CL.EXE. 48091 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 48092 if test $? -ne 0; then 48093 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 48094 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48095 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48096 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48097 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48098 fi 48099 # Collapse compiler output into a single line 48100 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 48101 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48102 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 48103 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 48104 # gcc --version output typically looks like 48105 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 48106 # Copyright (C) 2013 Free Software Foundation, Inc. 48107 # This is free software; see the source for copying conditions. There is NO 48108 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 48109 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48110 # Check that this is likely to be GCC. 48111 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 48112 if test $? -ne 0; then 48113 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 48114 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48115 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 48116 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 48117 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48118 fi 48119 # Remove Copyright and legalese from version string, and 48120 # collapse into a single line 48121 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48122 $SED -e 's/ *Copyright .*//'` 48123 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48124 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 48125 elif test "x$TOOLCHAIN_TYPE" = xclang; then 48126 # clang --version output typically looks like 48127 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 48128 # clang version 3.3 (tags/RELEASE_33/final) 48129 # or 48130 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 48131 # Target: x86_64-pc-linux-gnu 48132 # Thread model: posix 48133 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48134 # Check that this is likely to be clang 48135 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 48136 if test $? -ne 0; then 48137 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 48138 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48139 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48140 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48141 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48142 fi 48143 # Collapse compiler output into a single line 48144 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 48145 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48146 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 48147 else 48148 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 48149 fi 48150 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 48151 BUILD_CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 48152 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 48153 BUILD_CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 48154 48155 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 48156 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 48157 48158 48159 if test "x$BUILD_CC_VERSION_NUMBER" != "x$BUILD_CXX_VERSION_NUMBER"; then 48160 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $BUILD_CC_VERSION_NUMBER vs $BUILD_CXX_VERSION_NUMBER." >&5 48161 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $BUILD_CC_VERSION_NUMBER vs $BUILD_CXX_VERSION_NUMBER." >&2;} 48162 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 48163 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 48164 fi 48165 48166 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 48167 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 48168 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&5 48169 $as_echo "$as_me: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 48170 fi 48171 48172 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 48173 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has a part larger than 99999: $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&5 48174 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 48175 fi 48176 48177 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$BUILD_CC_VERSION_NUMBER"` 48178 48179 else 48180 # If we are not cross compiling, use the normal target compilers for 48181 # building the build platform executables. 48182 BUILD_CC="$CC" 48183 BUILD_CXX="$CXX" 48184 BUILD_LD="$LD" 48185 BUILD_LDCXX="$LDCXX" 48186 BUILD_NM="$NM" 48187 BUILD_AS="$AS" 48188 BUILD_OBJCOPY="$OBJCOPY" 48189 BUILD_STRIP="$STRIP" 48190 BUILD_SYSROOT_CFLAGS="$SYSROOT_CFLAGS" 48191 BUILD_SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS" 48192 BUILD_AR="$AR" 48193 48194 48195 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 48196 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 48197 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 48198 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 48199 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 48200 fi 48201 48202 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 48203 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 48204 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&5 48205 $as_echo "$as_me: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 48206 fi 48207 48208 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 48209 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&5 48210 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 48211 fi 48212 48213 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$CC_VERSION_NUMBER"` 48214 48215 fi 48216 48217 48218 48219 48220 48221 48222 48223 48224 48225 48226 48227 48228 48229 48230 # The package path is used only on macosx? 48231 # FIXME: clean this up, and/or move it elsewhere. 48232 PACKAGE_PATH=/opt/local 48233 48234 48235 # Check for extra potential brokenness. 48236 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48237 # On Windows, double-check that we got the right compiler. 48238 CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'` 48239 COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"` 48240 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 48241 if test "x$COMPILER_CPU_TEST" != "x80x86" -a "x$COMPILER_CPU_TEST" != "xx86"; then 48242 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\" or \"x86\"." "$LINENO" 5 48243 fi 48244 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 48245 if test "x$COMPILER_CPU_TEST" != "xx64"; then 48246 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 48247 fi 48248 fi 48249 fi 48250 48251 if test "x$TOOLCHAIN_TYPE" = xgcc; then 48252 # If this is a --hash-style=gnu system, use --hash-style=both, why? 48253 HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'` 48254 # This is later checked when setting flags. 48255 48256 # "-Og" suppported for GCC 4.8 and later 48257 CFLAG_OPTIMIZE_DEBUG_FLAG="-Og" 48258 48259 48260 48261 48262 48263 48264 48265 48266 48267 48268 48269 48270 48271 48272 48273 48274 48275 48276 48277 48278 48279 48280 48281 48282 48283 48284 48285 48286 48287 48288 48289 48290 48291 48292 48293 48294 48295 48296 48297 48298 48299 48300 48301 48302 48303 48304 48305 # Execute function body 48306 48307 48308 48309 48310 48311 48312 48313 48314 48315 48316 48317 48318 48319 48320 48321 48322 48323 48324 48325 48326 48327 48328 48329 48330 48331 48332 48333 48334 48335 48336 48337 48338 48339 48340 48341 48342 48343 48344 48345 48346 48347 48348 48349 48350 48351 48352 48353 48354 # Execute function body 48355 48356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 48357 $as_echo_n "checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 48358 supports=yes 48359 48360 saved_cflags="$CFLAGS" 48361 CFLAGS="$CFLAGS $CFLAG_OPTIMIZE_DEBUG_FLAG" 48362 ac_ext=c 48363 ac_cpp='$CPP $CPPFLAGS' 48364 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48365 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48366 ac_compiler_gnu=$ac_cv_c_compiler_gnu 48367 48368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48369 /* end confdefs.h. */ 48370 int i; 48371 _ACEOF 48372 if ac_fn_c_try_compile "$LINENO"; then : 48373 48374 else 48375 supports=no 48376 fi 48377 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48378 ac_ext=cpp 48379 ac_cpp='$CXXCPP $CPPFLAGS' 48380 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48381 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48382 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48383 48384 CFLAGS="$saved_cflags" 48385 48386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48387 $as_echo "$supports" >&6; } 48388 if test "x$supports" = "xyes" ; then 48389 : 48390 C_COMP_SUPPORTS="yes" 48391 else 48392 : 48393 C_COMP_SUPPORTS="no" 48394 fi 48395 48396 48397 48398 48399 48400 48401 48402 48403 48404 48405 48406 48407 48408 48409 48410 48411 48412 48413 48414 48415 48416 48417 48418 48419 48420 48421 48422 48423 48424 48425 48426 48427 48428 48429 48430 48431 48432 48433 48434 48435 48436 48437 48438 48439 48440 48441 48442 48443 48444 48445 48446 48447 48448 48449 48450 48451 48452 48453 48454 # Execute function body 48455 48456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 48457 $as_echo_n "checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 48458 supports=yes 48459 48460 saved_cxxflags="$CXXFLAGS" 48461 CXXFLAGS="$CXXFLAG $CFLAG_OPTIMIZE_DEBUG_FLAG" 48462 ac_ext=cpp 48463 ac_cpp='$CXXCPP $CPPFLAGS' 48464 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48465 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48466 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48467 48468 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48469 /* end confdefs.h. */ 48470 int i; 48471 _ACEOF 48472 if ac_fn_cxx_try_compile "$LINENO"; then : 48473 48474 else 48475 supports=no 48476 fi 48477 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48478 ac_ext=cpp 48479 ac_cpp='$CXXCPP $CPPFLAGS' 48480 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48481 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48482 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48483 48484 CXXFLAGS="$saved_cxxflags" 48485 48486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48487 $as_echo "$supports" >&6; } 48488 if test "x$supports" = "xyes" ; then 48489 : 48490 CXX_COMP_SUPPORTS="yes" 48491 else 48492 : 48493 CXX_COMP_SUPPORTS="no" 48494 fi 48495 48496 48497 48498 48499 48500 48501 48502 48503 48504 48505 48506 48507 48508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 48509 $as_echo_n "checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 48510 supports=no 48511 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 48512 48513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48514 $as_echo "$supports" >&6; } 48515 if test "x$supports" = "xyes" ; then 48516 : 48517 HAS_CFLAG_OPTIMIZE_DEBUG=true 48518 else 48519 : 48520 HAS_CFLAG_OPTIMIZE_DEBUG=false 48521 fi 48522 48523 48524 48525 48526 48527 48528 48529 # "-z relro" supported in GNU binutils 2.17 and later 48530 LINKER_RELRO_FLAG="-Wl,-z,relro" 48531 48532 48533 48534 48535 48536 48537 48538 48539 48540 48541 48542 48543 48544 48545 48546 48547 48548 48549 48550 48551 48552 48553 48554 48555 48556 48557 48558 48559 48560 48561 48562 48563 48564 48565 48566 48567 48568 48569 48570 48571 48572 48573 48574 48575 48576 48577 48578 # Execute function body 48579 48580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_RELRO_FLAG\"" >&5 48581 $as_echo_n "checking if linker supports \"$LINKER_RELRO_FLAG\"... " >&6; } 48582 supports=yes 48583 48584 saved_ldflags="$LDFLAGS" 48585 LDFLAGS="$LDFLAGS $LINKER_RELRO_FLAG" 48586 ac_ext=c 48587 ac_cpp='$CPP $CPPFLAGS' 48588 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48589 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48590 ac_compiler_gnu=$ac_cv_c_compiler_gnu 48591 48592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48593 /* end confdefs.h. */ 48594 48595 int 48596 main () 48597 { 48598 48599 ; 48600 return 0; 48601 } 48602 _ACEOF 48603 if ac_fn_c_try_link "$LINENO"; then : 48604 48605 else 48606 supports=no 48607 fi 48608 rm -f core conftest.err conftest.$ac_objext \ 48609 conftest$ac_exeext conftest.$ac_ext 48610 ac_ext=cpp 48611 ac_cpp='$CXXCPP $CPPFLAGS' 48612 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48613 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48614 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48615 48616 LDFLAGS="$saved_ldflags" 48617 48618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48619 $as_echo "$supports" >&6; } 48620 if test "x$supports" = "xyes" ; then 48621 : 48622 HAS_LINKER_RELRO=true 48623 else 48624 : 48625 HAS_LINKER_RELRO=false 48626 fi 48627 48628 48629 48630 48631 48632 48633 48634 48635 48636 48637 48638 48639 48640 # "-z now" supported in GNU binutils 2.11 and later 48641 LINKER_NOW_FLAG="-Wl,-z,now" 48642 48643 48644 48645 48646 48647 48648 48649 48650 48651 48652 48653 48654 48655 48656 48657 48658 48659 48660 48661 48662 48663 48664 48665 48666 48667 48668 48669 48670 48671 48672 48673 48674 48675 48676 48677 48678 48679 48680 48681 48682 48683 48684 48685 48686 48687 48688 48689 # Execute function body 48690 48691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_NOW_FLAG\"" >&5 48692 $as_echo_n "checking if linker supports \"$LINKER_NOW_FLAG\"... " >&6; } 48693 supports=yes 48694 48695 saved_ldflags="$LDFLAGS" 48696 LDFLAGS="$LDFLAGS $LINKER_NOW_FLAG" 48697 ac_ext=c 48698 ac_cpp='$CPP $CPPFLAGS' 48699 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48700 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48701 ac_compiler_gnu=$ac_cv_c_compiler_gnu 48702 48703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48704 /* end confdefs.h. */ 48705 48706 int 48707 main () 48708 { 48709 48710 ; 48711 return 0; 48712 } 48713 _ACEOF 48714 if ac_fn_c_try_link "$LINENO"; then : 48715 48716 else 48717 supports=no 48718 fi 48719 rm -f core conftest.err conftest.$ac_objext \ 48720 conftest$ac_exeext conftest.$ac_ext 48721 ac_ext=cpp 48722 ac_cpp='$CXXCPP $CPPFLAGS' 48723 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48724 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48725 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48726 48727 LDFLAGS="$saved_ldflags" 48728 48729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48730 $as_echo "$supports" >&6; } 48731 if test "x$supports" = "xyes" ; then 48732 : 48733 HAS_LINKER_NOW=true 48734 else 48735 : 48736 HAS_LINKER_NOW=false 48737 fi 48738 48739 48740 48741 48742 48743 48744 48745 48746 48747 48748 48749 48750 fi 48751 48752 # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed 48753 # in executable.' 48754 USING_BROKEN_SUSE_LD=no 48755 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then 48756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5 48757 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; } 48758 $ECHO "SUNWprivate_1.1 { local: *; };" > version-script.map 48759 $ECHO "int main() { }" > main.c 48760 if $CXX -Wl,-version-script=version-script.map main.c 2>&5 >&5; then 48761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48762 $as_echo "no" >&6; } 48763 USING_BROKEN_SUSE_LD=no 48764 else 48765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 48766 $as_echo "yes" >&6; } 48767 USING_BROKEN_SUSE_LD=yes 48768 fi 48769 $RM version-script.map main.c a.out 48770 fi 48771 48772 48773 # Setup hotspot lecagy names for toolchains 48774 HOTSPOT_TOOLCHAIN_TYPE=$TOOLCHAIN_TYPE 48775 if test "x$TOOLCHAIN_TYPE" = xclang; then 48776 HOTSPOT_TOOLCHAIN_TYPE=gcc 48777 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 48778 HOTSPOT_TOOLCHAIN_TYPE=sparcWorks 48779 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48780 HOTSPOT_TOOLCHAIN_TYPE=visCPP 48781 fi 48782 48783 48784 48785 # Setup the JTReg Regression Test Harness. 48786 48787 48788 # Check whether --with-jtreg was given. 48789 if test "${with_jtreg+set}" = set; then : 48790 withval=$with_jtreg; 48791 fi 48792 48793 48794 if test "x$with_jtreg" = xno; then 48795 # jtreg disabled 48796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 48797 $as_echo_n "checking for jtreg test harness... " >&6; } 48798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabled" >&5 48799 $as_echo "no, disabled" >&6; } 48800 elif test "x$with_jtreg" != xyes && test "x$with_jtreg" != x; then 48801 # An explicit path is specified, use it. 48802 JT_HOME="$with_jtreg" 48803 48804 # Only process if variable expands to non-empty 48805 48806 if test "x$JT_HOME" != x; then 48807 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48808 48809 # Input might be given as Windows format, start by converting to 48810 # unix format. 48811 path="$JT_HOME" 48812 new_path=`$CYGPATH -u "$path"` 48813 48814 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 48815 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 48816 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 48817 # "foo.exe" is OK but "foo" is an error. 48818 # 48819 # This test is therefore slightly more accurate than "test -f" to check for file precense. 48820 # It is also a way to make sure we got the proper file name for the real test later on. 48821 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 48822 if test "x$test_shortpath" = x; then 48823 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 48824 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 48825 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 48826 fi 48827 48828 # Call helper function which possibly converts this using DOS-style short mode. 48829 # If so, the updated path is stored in $new_path. 48830 48831 input_path="$new_path" 48832 # Check if we need to convert this using DOS-style short mode. If the path 48833 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48834 # take no chances and rewrite it. 48835 # Note: m4 eats our [], so we need to use [ and ] instead. 48836 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 48837 if test "x$has_forbidden_chars" != x; then 48838 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48839 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 48840 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 48841 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 48842 # Going to short mode and back again did indeed matter. Since short mode is 48843 # case insensitive, let's make it lowercase to improve readability. 48844 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48845 # Now convert it back to Unix-style (cygpath) 48846 input_path=`$CYGPATH -u "$shortmode_path"` 48847 new_path="$input_path" 48848 fi 48849 fi 48850 48851 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 48852 if test "x$test_cygdrive_prefix" = x; then 48853 # As a simple fix, exclude /usr/bin since it's not a real path. 48854 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 48855 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 48856 # a path prefixed by /cygdrive for fixpath to work. 48857 new_path="$CYGWIN_ROOT_PATH$input_path" 48858 fi 48859 fi 48860 48861 48862 if test "x$path" != "x$new_path"; then 48863 JT_HOME="$new_path" 48864 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 48865 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 48866 fi 48867 48868 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48869 48870 path="$JT_HOME" 48871 has_colon=`$ECHO $path | $GREP ^.:` 48872 new_path="$path" 48873 if test "x$has_colon" = x; then 48874 # Not in mixed or Windows style, start by that. 48875 new_path=`cmd //c echo $path` 48876 fi 48877 48878 48879 input_path="$new_path" 48880 # Check if we need to convert this using DOS-style short mode. If the path 48881 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48882 # take no chances and rewrite it. 48883 # Note: m4 eats our [], so we need to use [ and ] instead. 48884 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 48885 if test "x$has_forbidden_chars" != x; then 48886 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48887 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48888 fi 48889 48890 48891 windows_path="$new_path" 48892 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48893 unix_path=`$CYGPATH -u "$windows_path"` 48894 new_path="$unix_path" 48895 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48896 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48897 new_path="$unix_path" 48898 fi 48899 48900 if test "x$path" != "x$new_path"; then 48901 JT_HOME="$new_path" 48902 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 48903 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 48904 fi 48905 48906 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48907 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48908 48909 else 48910 # We're on a unix platform. Hooray! :) 48911 path="$JT_HOME" 48912 has_space=`$ECHO "$path" | $GREP " "` 48913 if test "x$has_space" != x; then 48914 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 48915 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 48916 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 48917 fi 48918 48919 # Use eval to expand a potential ~ 48920 eval path="$path" 48921 if test ! -f "$path" && test ! -d "$path"; then 48922 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 48923 fi 48924 48925 if test -d "$path"; then 48926 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 48927 else 48928 dir="`$DIRNAME "$path"`" 48929 base="`$BASENAME "$path"`" 48930 JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" 48931 fi 48932 fi 48933 fi 48934 48935 if test ! -d "$JT_HOME"; then 48936 as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg does not exist" "$LINENO" 5 48937 fi 48938 48939 if test ! -e "$JT_HOME/lib/jtreg.jar"; then 48940 as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg is not a valid jtreg home" "$LINENO" 5 48941 fi 48942 48943 JTREGEXE="$JT_HOME/bin/jtreg" 48944 if test ! -x "$JTREGEXE"; then 48945 as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg does not contain valid jtreg executable" "$LINENO" 5 48946 fi 48947 48948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 48949 $as_echo_n "checking for jtreg test harness... " >&6; } 48950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JT_HOME" >&5 48951 $as_echo "$JT_HOME" >&6; } 48952 else 48953 # Try to locate jtreg 48954 if test "x$JT_HOME" != x; then 48955 # JT_HOME set in environment, use it 48956 if test ! -d "$JT_HOME"; then 48957 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME pointing to invalid directory: $JT_HOME" >&5 48958 $as_echo "$as_me: WARNING: Ignoring JT_HOME pointing to invalid directory: $JT_HOME" >&2;} 48959 JT_HOME= 48960 else 48961 if test ! -e "$JT_HOME/lib/jtreg.jar"; then 48962 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME which is not a valid jtreg home: $JT_HOME" >&5 48963 $as_echo "$as_me: WARNING: Ignoring JT_HOME which is not a valid jtreg home: $JT_HOME" >&2;} 48964 JT_HOME= 48965 elif test ! -x "$JT_HOME/bin/jtreg"; then 48966 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME which does not contain valid jtreg executable: $JT_HOME" >&5 48967 $as_echo "$as_me: WARNING: Ignoring JT_HOME which does not contain valid jtreg executable: $JT_HOME" >&2;} 48968 JT_HOME= 48969 else 48970 JTREGEXE="$JT_HOME/bin/jtreg" 48971 { $as_echo "$as_me:${as_lineno-$LINENO}: Located jtreg using JT_HOME from environment" >&5 48972 $as_echo "$as_me: Located jtreg using JT_HOME from environment" >&6;} 48973 fi 48974 fi 48975 fi 48976 48977 if test "x$JT_HOME" = x; then 48978 # JT_HOME is not set in environment, or was deemed invalid. 48979 # Try to find jtreg on path 48980 48981 48982 # Publish this variable in the help. 48983 48984 48985 if [ -z "${JTREGEXE+x}" ]; then 48986 # The variable is not set by user, try to locate tool using the code snippet 48987 for ac_prog in jtreg 48988 do 48989 # Extract the first word of "$ac_prog", so it can be a program name with args. 48990 set dummy $ac_prog; ac_word=$2 48991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48992 $as_echo_n "checking for $ac_word... " >&6; } 48993 if ${ac_cv_path_JTREGEXE+:} false; then : 48994 $as_echo_n "(cached) " >&6 48995 else 48996 case $JTREGEXE in 48997 [\\/]* | ?:[\\/]*) 48998 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48999 ;; 49000 *) 49001 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 49002 for as_dir in $PATH 49003 do 49004 IFS=$as_save_IFS 49005 test -z "$as_dir" && as_dir=. 49006 for ac_exec_ext in '' $ac_executable_extensions; do 49007 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 49008 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 49009 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 49010 break 2 49011 fi 49012 done 49013 done 49014 IFS=$as_save_IFS 49015 49016 ;; 49017 esac 49018 fi 49019 JTREGEXE=$ac_cv_path_JTREGEXE 49020 if test -n "$JTREGEXE"; then 49021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 49022 $as_echo "$JTREGEXE" >&6; } 49023 else 49024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 49025 $as_echo "no" >&6; } 49026 fi 49027 49028 49029 test -n "$JTREGEXE" && break 49030 done 49031 49032 else 49033 # The variable is set, but is it from the command line or the environment? 49034 49035 # Try to remove the string !JTREGEXE! from our list. 49036 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/} 49037 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 49038 # If it failed, the variable was not from the command line. Ignore it, 49039 # but warn the user (except for BASH, which is always set by the calling BASH). 49040 if test "xJTREGEXE" != xBASH; then 49041 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5 49042 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;} 49043 fi 49044 # Try to locate tool using the code snippet 49045 for ac_prog in jtreg 49046 do 49047 # Extract the first word of "$ac_prog", so it can be a program name with args. 49048 set dummy $ac_prog; ac_word=$2 49049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 49050 $as_echo_n "checking for $ac_word... " >&6; } 49051 if ${ac_cv_path_JTREGEXE+:} false; then : 49052 $as_echo_n "(cached) " >&6 49053 else 49054 case $JTREGEXE in 49055 [\\/]* | ?:[\\/]*) 49056 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 49057 ;; 49058 *) 49059 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 49060 for as_dir in $PATH 49061 do 49062 IFS=$as_save_IFS 49063 test -z "$as_dir" && as_dir=. 49064 for ac_exec_ext in '' $ac_executable_extensions; do 49065 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 49066 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 49067 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 49068 break 2 49069 fi 49070 done 49071 done 49072 IFS=$as_save_IFS 49073 49074 ;; 49075 esac 49076 fi 49077 JTREGEXE=$ac_cv_path_JTREGEXE 49078 if test -n "$JTREGEXE"; then 49079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 49080 $as_echo "$JTREGEXE" >&6; } 49081 else 49082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 49083 $as_echo "no" >&6; } 49084 fi 49085 49086 49087 test -n "$JTREGEXE" && break 49088 done 49089 49090 else 49091 # If it succeeded, then it was overridden by the user. We will use it 49092 # for the tool. 49093 49094 # First remove it from the list of overridden variables, so we can test 49095 # for unknown variables in the end. 49096 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 49097 49098 # Check if we try to supply an empty value 49099 if test "x$JTREGEXE" = x; then 49100 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JTREGEXE= (no value)" >&5 49101 $as_echo "$as_me: Setting user supplied tool JTREGEXE= (no value)" >&6;} 49102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 49103 $as_echo_n "checking for JTREGEXE... " >&6; } 49104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 49105 $as_echo "disabled" >&6; } 49106 else 49107 # Check if the provided tool contains a complete path. 49108 tool_specified="$JTREGEXE" 49109 tool_basename="${tool_specified##*/}" 49110 if test "x$tool_basename" = "x$tool_specified"; then 49111 # A command without a complete path is provided, search $PATH. 49112 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5 49113 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;} 49114 # Extract the first word of "$tool_basename", so it can be a program name with args. 49115 set dummy $tool_basename; ac_word=$2 49116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 49117 $as_echo_n "checking for $ac_word... " >&6; } 49118 if ${ac_cv_path_JTREGEXE+:} false; then : 49119 $as_echo_n "(cached) " >&6 49120 else 49121 case $JTREGEXE in 49122 [\\/]* | ?:[\\/]*) 49123 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 49124 ;; 49125 *) 49126 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 49127 for as_dir in $PATH 49128 do 49129 IFS=$as_save_IFS 49130 test -z "$as_dir" && as_dir=. 49131 for ac_exec_ext in '' $ac_executable_extensions; do 49132 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 49133 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 49134 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 49135 break 2 49136 fi 49137 done 49138 done 49139 IFS=$as_save_IFS 49140 49141 ;; 49142 esac 49143 fi 49144 JTREGEXE=$ac_cv_path_JTREGEXE 49145 if test -n "$JTREGEXE"; then 49146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 49147 $as_echo "$JTREGEXE" >&6; } 49148 else 49149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 49150 $as_echo "no" >&6; } 49151 fi 49152 49153 49154 if test "x$JTREGEXE" = x; then 49155 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 49156 fi 49157 else 49158 # Otherwise we believe it is a complete path. Use it as it is. 49159 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5 49160 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;} 49161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 49162 $as_echo_n "checking for JTREGEXE... " >&6; } 49163 if test ! -x "$tool_specified"; then 49164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 49165 $as_echo "not found" >&6; } 49166 as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 49167 fi 49168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 49169 $as_echo "$tool_specified" >&6; } 49170 fi 49171 fi 49172 fi 49173 49174 fi 49175 49176 49177 if test "x$JTREGEXE" != x; then 49178 # That's good, now try to derive JT_HOME 49179 JT_HOME=`(cd $($DIRNAME $JTREGEXE)/.. && pwd)` 49180 if test ! -e "$JT_HOME/lib/jtreg.jar"; then 49181 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring jtreg from path since a valid jtreg home cannot be found" >&5 49182 $as_echo "$as_me: WARNING: Ignoring jtreg from path since a valid jtreg home cannot be found" >&2;} 49183 JT_HOME= 49184 JTREGEXE= 49185 else 49186 { $as_echo "$as_me:${as_lineno-$LINENO}: Located jtreg using jtreg executable in path" >&5 49187 $as_echo "$as_me: Located jtreg using jtreg executable in path" >&6;} 49188 fi 49189 fi 49190 fi 49191 49192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 49193 $as_echo_n "checking for jtreg test harness... " >&6; } 49194 if test "x$JT_HOME" != x; then 49195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JT_HOME" >&5 49196 $as_echo "$JT_HOME" >&6; } 49197 else 49198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found" >&5 49199 $as_echo "no, not found" >&6; } 49200 49201 if test "x$with_jtreg" = xyes; then 49202 as_fn_error $? "--with-jtreg was specified, but no jtreg found." "$LINENO" 5 49203 fi 49204 fi 49205 fi 49206 49207 49208 # Only process if variable expands to non-empty 49209 49210 if test "x$JTREGEXE" != x; then 49211 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49212 49213 # First separate the path from the arguments. This will split at the first 49214 # space. 49215 complete="$JTREGEXE" 49216 path="${complete%% *}" 49217 tmp="$complete EOL" 49218 arguments="${tmp#* }" 49219 49220 # Input might be given as Windows format, start by converting to 49221 # unix format. 49222 new_path=`$CYGPATH -u "$path"` 49223 49224 # Now try to locate executable using which 49225 new_path=`$WHICH "$new_path" 2> /dev/null` 49226 # bat and cmd files are not always considered executable in cygwin causing which 49227 # to not find them 49228 if test "x$new_path" = x \ 49229 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 49230 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 49231 new_path=`$CYGPATH -u "$path"` 49232 fi 49233 if test "x$new_path" = x; then 49234 # Oops. Which didn't find the executable. 49235 # The splitting of arguments from the executable at a space might have been incorrect, 49236 # since paths with space are more likely in Windows. Give it another try with the whole 49237 # argument. 49238 path="$complete" 49239 arguments="EOL" 49240 new_path=`$CYGPATH -u "$path"` 49241 new_path=`$WHICH "$new_path" 2> /dev/null` 49242 # bat and cmd files are not always considered executable in cygwin causing which 49243 # to not find them 49244 if test "x$new_path" = x \ 49245 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 49246 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 49247 new_path=`$CYGPATH -u "$path"` 49248 fi 49249 if test "x$new_path" = x; then 49250 # It's still not found. Now this is an unrecoverable error. 49251 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 49252 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} 49253 has_space=`$ECHO "$complete" | $GREP " "` 49254 if test "x$has_space" != x; then 49255 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 49256 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 49257 fi 49258 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 49259 fi 49260 fi 49261 49262 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 49263 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 49264 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 49265 # "foo.exe" is OK but "foo" is an error. 49266 # 49267 # This test is therefore slightly more accurate than "test -f" to check for file presence. 49268 # It is also a way to make sure we got the proper file name for the real test later on. 49269 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 49270 if test "x$test_shortpath" = x; then 49271 # Short path failed, file does not exist as specified. 49272 # Try adding .exe or .cmd 49273 if test -f "${new_path}.exe"; then 49274 input_to_shortpath="${new_path}.exe" 49275 elif test -f "${new_path}.cmd"; then 49276 input_to_shortpath="${new_path}.cmd" 49277 else 49278 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$new_path\", is invalid." >&5 49279 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$new_path\", is invalid." >&6;} 49280 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 49281 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 49282 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 49283 fi 49284 else 49285 input_to_shortpath="$new_path" 49286 fi 49287 49288 # Call helper function which possibly converts this using DOS-style short mode. 49289 # If so, the updated path is stored in $new_path. 49290 new_path="$input_to_shortpath" 49291 49292 input_path="$input_to_shortpath" 49293 # Check if we need to convert this using DOS-style short mode. If the path 49294 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49295 # take no chances and rewrite it. 49296 # Note: m4 eats our [], so we need to use [ and ] instead. 49297 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 49298 if test "x$has_forbidden_chars" != x; then 49299 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49300 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 49301 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 49302 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49303 # Going to short mode and back again did indeed matter. Since short mode is 49304 # case insensitive, let's make it lowercase to improve readability. 49305 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49306 # Now convert it back to Unix-style (cygpath) 49307 input_path=`$CYGPATH -u "$shortmode_path"` 49308 new_path="$input_path" 49309 fi 49310 fi 49311 49312 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49313 if test "x$test_cygdrive_prefix" = x; then 49314 # As a simple fix, exclude /usr/bin since it's not a real path. 49315 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 49316 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49317 # a path prefixed by /cygdrive for fixpath to work. 49318 new_path="$CYGWIN_ROOT_PATH$input_path" 49319 fi 49320 fi 49321 49322 # remove trailing .exe if any 49323 new_path="${new_path/%.exe/}" 49324 49325 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49326 49327 # First separate the path from the arguments. This will split at the first 49328 # space. 49329 complete="$JTREGEXE" 49330 path="${complete%% *}" 49331 tmp="$complete EOL" 49332 arguments="${tmp#* }" 49333 49334 # Input might be given as Windows format, start by converting to 49335 # unix format. 49336 new_path="$path" 49337 49338 windows_path="$new_path" 49339 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49340 unix_path=`$CYGPATH -u "$windows_path"` 49341 new_path="$unix_path" 49342 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49343 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49344 new_path="$unix_path" 49345 fi 49346 49347 49348 # Now try to locate executable using which 49349 new_path=`$WHICH "$new_path" 2> /dev/null` 49350 49351 if test "x$new_path" = x; then 49352 # Oops. Which didn't find the executable. 49353 # The splitting of arguments from the executable at a space might have been incorrect, 49354 # since paths with space are more likely in Windows. Give it another try with the whole 49355 # argument. 49356 path="$complete" 49357 arguments="EOL" 49358 new_path="$path" 49359 49360 windows_path="$new_path" 49361 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49362 unix_path=`$CYGPATH -u "$windows_path"` 49363 new_path="$unix_path" 49364 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49365 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49366 new_path="$unix_path" 49367 fi 49368 49369 49370 new_path=`$WHICH "$new_path" 2> /dev/null` 49371 # bat and cmd files are not always considered executable in MSYS causing which 49372 # to not find them 49373 if test "x$new_path" = x \ 49374 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 49375 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 49376 new_path="$path" 49377 49378 windows_path="$new_path" 49379 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49380 unix_path=`$CYGPATH -u "$windows_path"` 49381 new_path="$unix_path" 49382 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49383 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49384 new_path="$unix_path" 49385 fi 49386 49387 fi 49388 49389 if test "x$new_path" = x; then 49390 # It's still not found. Now this is an unrecoverable error. 49391 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 49392 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} 49393 has_space=`$ECHO "$complete" | $GREP " "` 49394 if test "x$has_space" != x; then 49395 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 49396 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 49397 fi 49398 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 49399 fi 49400 fi 49401 49402 # Now new_path has a complete unix path to the binary 49403 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 49404 # Keep paths in /bin as-is, but remove trailing .exe if any 49405 new_path="${new_path/%.exe/}" 49406 # Do not save /bin paths to all_fixpath_prefixes! 49407 else 49408 # Not in mixed or Windows style, start by that. 49409 new_path=`cmd //c echo $new_path` 49410 49411 input_path="$new_path" 49412 # Check if we need to convert this using DOS-style short mode. If the path 49413 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49414 # take no chances and rewrite it. 49415 # Note: m4 eats our [], so we need to use [ and ] instead. 49416 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 49417 if test "x$has_forbidden_chars" != x; then 49418 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49419 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49420 fi 49421 49422 # Output is in $new_path 49423 49424 windows_path="$new_path" 49425 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49426 unix_path=`$CYGPATH -u "$windows_path"` 49427 new_path="$unix_path" 49428 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49429 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49430 new_path="$unix_path" 49431 fi 49432 49433 # remove trailing .exe if any 49434 new_path="${new_path/%.exe/}" 49435 49436 # Save the first 10 bytes of this path to the storage, so fixpath can work. 49437 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 49438 fi 49439 49440 else 49441 # We're on a unix platform. Hooray! :) 49442 # First separate the path from the arguments. This will split at the first 49443 # space. 49444 complete="$JTREGEXE" 49445 path="${complete%% *}" 49446 tmp="$complete EOL" 49447 arguments="${tmp#* }" 49448 49449 # Cannot rely on the command "which" here since it doesn't always work. 49450 is_absolute_path=`$ECHO "$path" | $GREP ^/` 49451 if test -z "$is_absolute_path"; then 49452 # Path to executable is not absolute. Find it. 49453 IFS_save="$IFS" 49454 IFS=: 49455 for p in $PATH; do 49456 if test -f "$p/$path" && test -x "$p/$path"; then 49457 new_path="$p/$path" 49458 break 49459 fi 49460 done 49461 IFS="$IFS_save" 49462 else 49463 # This is an absolute path, we can use it without further modifications. 49464 new_path="$path" 49465 fi 49466 49467 if test "x$new_path" = x; then 49468 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 49469 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} 49470 has_space=`$ECHO "$complete" | $GREP " "` 49471 if test "x$has_space" != x; then 49472 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 49473 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 49474 fi 49475 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 49476 fi 49477 fi 49478 49479 # Now join together the path and the arguments once again 49480 if test "x$arguments" != xEOL; then 49481 new_complete="$new_path ${arguments% *}" 49482 else 49483 new_complete="$new_path" 49484 fi 49485 49486 if test "x$complete" != "x$new_complete"; then 49487 JTREGEXE="$new_complete" 49488 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JTREGEXE to \"$new_complete\"" >&5 49489 $as_echo "$as_me: Rewriting JTREGEXE to \"$new_complete\"" >&6;} 49490 fi 49491 fi 49492 49493 49494 # Only process if variable expands to non-empty 49495 49496 if test "x$JT_HOME" != x; then 49497 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49498 49499 # Input might be given as Windows format, start by converting to 49500 # unix format. 49501 path="$JT_HOME" 49502 new_path=`$CYGPATH -u "$path"` 49503 49504 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 49505 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 49506 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 49507 # "foo.exe" is OK but "foo" is an error. 49508 # 49509 # This test is therefore slightly more accurate than "test -f" to check for file precense. 49510 # It is also a way to make sure we got the proper file name for the real test later on. 49511 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 49512 if test "x$test_shortpath" = x; then 49513 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 49514 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 49515 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 49516 fi 49517 49518 # Call helper function which possibly converts this using DOS-style short mode. 49519 # If so, the updated path is stored in $new_path. 49520 49521 input_path="$new_path" 49522 # Check if we need to convert this using DOS-style short mode. If the path 49523 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49524 # take no chances and rewrite it. 49525 # Note: m4 eats our [], so we need to use [ and ] instead. 49526 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 49527 if test "x$has_forbidden_chars" != x; then 49528 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49529 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 49530 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 49531 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49532 # Going to short mode and back again did indeed matter. Since short mode is 49533 # case insensitive, let's make it lowercase to improve readability. 49534 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49535 # Now convert it back to Unix-style (cygpath) 49536 input_path=`$CYGPATH -u "$shortmode_path"` 49537 new_path="$input_path" 49538 fi 49539 fi 49540 49541 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49542 if test "x$test_cygdrive_prefix" = x; then 49543 # As a simple fix, exclude /usr/bin since it's not a real path. 49544 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 49545 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49546 # a path prefixed by /cygdrive for fixpath to work. 49547 new_path="$CYGWIN_ROOT_PATH$input_path" 49548 fi 49549 fi 49550 49551 49552 if test "x$path" != "x$new_path"; then 49553 JT_HOME="$new_path" 49554 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 49555 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 49556 fi 49557 49558 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49559 49560 path="$JT_HOME" 49561 has_colon=`$ECHO $path | $GREP ^.:` 49562 new_path="$path" 49563 if test "x$has_colon" = x; then 49564 # Not in mixed or Windows style, start by that. 49565 new_path=`cmd //c echo $path` 49566 fi 49567 49568 49569 input_path="$new_path" 49570 # Check if we need to convert this using DOS-style short mode. If the path 49571 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49572 # take no chances and rewrite it. 49573 # Note: m4 eats our [], so we need to use [ and ] instead. 49574 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 49575 if test "x$has_forbidden_chars" != x; then 49576 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49577 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49578 fi 49579 49580 49581 windows_path="$new_path" 49582 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49583 unix_path=`$CYGPATH -u "$windows_path"` 49584 new_path="$unix_path" 49585 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49586 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49587 new_path="$unix_path" 49588 fi 49589 49590 if test "x$path" != "x$new_path"; then 49591 JT_HOME="$new_path" 49592 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 49593 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 49594 fi 49595 49596 # Save the first 10 bytes of this path to the storage, so fixpath can work. 49597 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 49598 49599 else 49600 # We're on a unix platform. Hooray! :) 49601 path="$JT_HOME" 49602 has_space=`$ECHO "$path" | $GREP " "` 49603 if test "x$has_space" != x; then 49604 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 49605 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 49606 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 49607 fi 49608 49609 # Use eval to expand a potential ~ 49610 eval path="$path" 49611 if test ! -f "$path" && test ! -d "$path"; then 49612 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 49613 fi 49614 49615 if test -d "$path"; then 49616 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 49617 else 49618 dir="`$DIRNAME "$path"`" 49619 base="`$BASENAME "$path"`" 49620 JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" 49621 fi 49622 fi 49623 fi 49624 49625 49626 49627 49628 49629 # Setup Jib dependency tool 49630 49631 49632 # Check whether --with-jib was given. 49633 if test "${with_jib+set}" = set; then : 49634 withval=$with_jib; 49635 fi 49636 49637 49638 if test "x$with_jib" = xno || test "x$with_jib" = x; then 49639 # jib disabled 49640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jib" >&5 49641 $as_echo_n "checking for jib... " >&6; } 49642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 49643 $as_echo "no" >&6; } 49644 elif test "x$with_jib" = xyes; then 49645 as_fn_error $? "Must supply a value to --with-jib" "$LINENO" 5 49646 else 49647 JIB_HOME="${with_jib}" 49648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jib" >&5 49649 $as_echo_n "checking for jib... " >&6; } 49650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${JIB_HOME}" >&5 49651 $as_echo "${JIB_HOME}" >&6; } 49652 if test ! -d "${JIB_HOME}"; then 49653 as_fn_error $? "--with-jib must be a directory" "$LINENO" 5 49654 fi 49655 JIB_JAR=$(ls ${JIB_HOME}/lib/jib-*.jar) 49656 if test ! -f "${JIB_JAR}"; then 49657 as_fn_error $? "Could not find jib jar file in ${JIB_HOME}" "$LINENO" 5 49658 fi 49659 fi 49660 49661 49662 49663 49664 49665 # COMPILER_TARGET_BITS_FLAG : option for selecting 32- or 64-bit output 49666 # COMPILER_COMMAND_FILE_FLAG : option for passing a command file to the compiler 49667 # COMPILER_BINDCMD_FILE_FLAG : option for specifying a file which saves the binder 49668 # commands produced by the link step (currently AIX only) 49669 if test "x$TOOLCHAIN_TYPE" = xxlc; then 49670 COMPILER_TARGET_BITS_FLAG="-q" 49671 COMPILER_COMMAND_FILE_FLAG="-f" 49672 COMPILER_BINDCMD_FILE_FLAG="-bloadmap:" 49673 else 49674 COMPILER_TARGET_BITS_FLAG="-m" 49675 COMPILER_COMMAND_FILE_FLAG="@" 49676 COMPILER_BINDCMD_FILE_FLAG="" 49677 49678 # The solstudio linker does not support @-files. 49679 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49680 COMPILER_COMMAND_FILE_FLAG= 49681 fi 49682 49683 # Check if @file is supported by gcc 49684 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if @file is supported by gcc" >&5 49686 $as_echo_n "checking if @file is supported by gcc... " >&6; } 49687 # Extra emtpy "" to prevent ECHO from interpreting '--version' as argument 49688 $ECHO "" "--version" > command.file 49689 if $CXX @command.file 2>&5 >&5; then 49690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 49691 $as_echo "yes" >&6; } 49692 COMPILER_COMMAND_FILE_FLAG="@" 49693 else 49694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 49695 $as_echo "no" >&6; } 49696 COMPILER_COMMAND_FILE_FLAG= 49697 fi 49698 $RM command.file 49699 fi 49700 fi 49701 49702 49703 49704 49705 # FIXME: figure out if we should select AR flags depending on OS or toolchain. 49706 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49707 ARFLAGS="-r" 49708 elif test "x$OPENJDK_TARGET_OS" = xaix; then 49709 ARFLAGS="-X64" 49710 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 49711 # lib.exe is used as AR to create static libraries. 49712 ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT" 49713 else 49714 ARFLAGS="" 49715 fi 49716 49717 49718 ## Setup strip. 49719 # FIXME: should this really be per platform, or should it be per toolchain type? 49720 # strip is not provided by clang or solstudio; so guessing platform makes most sense. 49721 # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD. 49722 if test "x$OPENJDK_TARGET_OS" = xlinux; then 49723 STRIPFLAGS="-g" 49724 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 49725 STRIPFLAGS="-x" 49726 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 49727 STRIPFLAGS="-S" 49728 elif test "x$OPENJDK_TARGET_OS" = xaix; then 49729 STRIPFLAGS="-X32_64" 49730 fi 49731 49732 49733 49734 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49735 CC_OUT_OPTION=-Fo 49736 EXE_OUT_OPTION=-out: 49737 LD_OUT_OPTION=-out: 49738 AR_OUT_OPTION=-out: 49739 else 49740 # The option used to specify the target .o,.a or .so file. 49741 # When compiling, how to specify the to be created object file. 49742 CC_OUT_OPTION='-o$(SPACE)' 49743 # When linking, how to specify the to be created executable. 49744 EXE_OUT_OPTION='-o$(SPACE)' 49745 # When linking, how to specify the to be created dynamically linkable library. 49746 LD_OUT_OPTION='-o$(SPACE)' 49747 # When archiving, how to specify the to be create static archive for object files. 49748 AR_OUT_OPTION='rcs$(SPACE)' 49749 fi 49750 49751 49752 49753 49754 49755 # On Windows, we need to set RC flags. 49756 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49757 RC_FLAGS="-nologo -l0x409" 49758 JVM_RCFLAGS="-nologo" 49759 if test "x$DEBUG_LEVEL" = xrelease; then 49760 RC_FLAGS="$RC_FLAGS -DNDEBUG" 49761 JVM_RCFLAGS="$JVM_RCFLAGS -DNDEBUG" 49762 fi 49763 49764 # The version variables used to create RC_FLAGS may be overridden 49765 # in a custom configure script, or possibly the command line. 49766 # Let those variables be expanded at make time in spec.gmk. 49767 # The \$ are escaped to the shell, and the $(...) variables 49768 # are evaluated by make. 49769 RC_FLAGS="$RC_FLAGS \ 49770 -D\"JDK_VERSION_STRING=\$(VERSION_STRING)\" \ 49771 -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \ 49772 -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \ 49773 -D\"JDK_VER=\$(VERSION_NUMBER)\" \ 49774 -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \ 49775 -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(VERSION_MAJOR)\" \ 49776 -D\"JDK_FVER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\"" 49777 49778 JVM_RCFLAGS="$JVM_RCFLAGS \ 49779 -D\"HS_BUILD_ID=\$(VERSION_STRING)\" \ 49780 -D\"HS_COMPANY=\$(COMPANY_NAME)\" \ 49781 -D\"JDK_DOTVER=\$(VERSION_NUMBER_FOUR_POSITIONS)\" \ 49782 -D\"HS_COPYRIGHT=Copyright $COPYRIGHT_YEAR\" \ 49783 -D\"HS_NAME=\$(PRODUCT_NAME) \$(VERSION_SHORT)\" \ 49784 -D\"JDK_VER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\" \ 49785 -D\"HS_FNAME=jvm.dll\" \ 49786 -D\"HS_INTERNAL_NAME=jvm\"" 49787 fi 49788 49789 49790 49791 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49792 # silence copyright notice and other headers. 49793 COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo" 49794 fi 49795 49796 49797 # Now we can test some aspects on the target using configure macros. 49798 49799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 49800 $as_echo_n "checking for ANSI C header files... " >&6; } 49801 if ${ac_cv_header_stdc+:} false; then : 49802 $as_echo_n "(cached) " >&6 49803 else 49804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49805 /* end confdefs.h. */ 49806 #include <stdlib.h> 49807 #include <stdarg.h> 49808 #include <string.h> 49809 #include <float.h> 49810 49811 int 49812 main () 49813 { 49814 49815 ; 49816 return 0; 49817 } 49818 _ACEOF 49819 if ac_fn_cxx_try_compile "$LINENO"; then : 49820 ac_cv_header_stdc=yes 49821 else 49822 ac_cv_header_stdc=no 49823 fi 49824 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49825 49826 if test $ac_cv_header_stdc = yes; then 49827 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 49828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49829 /* end confdefs.h. */ 49830 #include <string.h> 49831 49832 _ACEOF 49833 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 49834 $EGREP "memchr" >/dev/null 2>&1; then : 49835 49836 else 49837 ac_cv_header_stdc=no 49838 fi 49839 rm -f conftest* 49840 49841 fi 49842 49843 if test $ac_cv_header_stdc = yes; then 49844 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 49845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49846 /* end confdefs.h. */ 49847 #include <stdlib.h> 49848 49849 _ACEOF 49850 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 49851 $EGREP "free" >/dev/null 2>&1; then : 49852 49853 else 49854 ac_cv_header_stdc=no 49855 fi 49856 rm -f conftest* 49857 49858 fi 49859 49860 if test $ac_cv_header_stdc = yes; then 49861 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 49862 if test "$cross_compiling" = yes; then : 49863 : 49864 else 49865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49866 /* end confdefs.h. */ 49867 #include <ctype.h> 49868 #include <stdlib.h> 49869 #if ((' ' & 0x0FF) == 0x020) 49870 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 49871 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 49872 #else 49873 # define ISLOWER(c) \ 49874 (('a' <= (c) && (c) <= 'i') \ 49875 || ('j' <= (c) && (c) <= 'r') \ 49876 || ('s' <= (c) && (c) <= 'z')) 49877 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 49878 #endif 49879 49880 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 49881 int 49882 main () 49883 { 49884 int i; 49885 for (i = 0; i < 256; i++) 49886 if (XOR (islower (i), ISLOWER (i)) 49887 || toupper (i) != TOUPPER (i)) 49888 return 2; 49889 return 0; 49890 } 49891 _ACEOF 49892 if ac_fn_cxx_try_run "$LINENO"; then : 49893 49894 else 49895 ac_cv_header_stdc=no 49896 fi 49897 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 49898 conftest.$ac_objext conftest.beam conftest.$ac_ext 49899 fi 49900 49901 fi 49902 fi 49903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 49904 $as_echo "$ac_cv_header_stdc" >&6; } 49905 if test $ac_cv_header_stdc = yes; then 49906 49907 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 49908 49909 fi 49910 49911 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 49912 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 49913 inttypes.h stdint.h unistd.h 49914 do : 49915 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 49916 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 49917 " 49918 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 49919 cat >>confdefs.h <<_ACEOF 49920 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 49921 _ACEOF 49922 49923 fi 49924 49925 done 49926 49927 49928 49929 ############################################################################### 49930 # 49931 # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code. 49932 # (The JVM can use 32 or 64 bit Java pointers but that decision 49933 # is made at runtime.) 49934 # 49935 49936 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then 49937 # Always specify -m flag on Solaris 49938 # And -q on AIX because otherwise the compiler produces 32-bit objects by default 49939 49940 # When we add flags to the "official" CFLAGS etc, we need to 49941 # keep track of these additions in ADDED_CFLAGS etc. These 49942 # will later be checked to make sure only controlled additions 49943 # have been made to CFLAGS etc. 49944 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49945 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49946 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49947 49948 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 49949 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 49950 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 49951 49952 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 49953 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 49954 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 49955 49956 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 49957 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 49958 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 49959 49960 elif test "x$COMPILE_TYPE" = xreduced; then 49961 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 49962 # Specify -m if running reduced on unix platforms 49963 49964 # When we add flags to the "official" CFLAGS etc, we need to 49965 # keep track of these additions in ADDED_CFLAGS etc. These 49966 # will later be checked to make sure only controlled additions 49967 # have been made to CFLAGS etc. 49968 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49969 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49970 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49971 49972 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 49973 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 49974 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 49975 49976 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 49977 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 49978 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 49979 49980 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 49981 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 49982 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 49983 49984 fi 49985 fi 49986 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49987 JVM_CFLAGS="$JVM_CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49988 JVM_LDFLAGS="$JVM_LDFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49989 JVM_ASFLAGS="$JVM_ASFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49990 fi 49991 49992 # Make compilation sanity check 49993 for ac_header in stdio.h 49994 do : 49995 ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default" 49996 if test "x$ac_cv_header_stdio_h" = xyes; then : 49997 cat >>confdefs.h <<_ACEOF 49998 #define HAVE_STDIO_H 1 49999 _ACEOF 50000 50001 else 50002 50003 { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5 50004 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;} 50005 if test "x$COMPILE_TYPE" = xreduced; then 50006 50007 # Print a helpful message on how to acquire the necessary build dependency. 50008 # reduced is the help tag: freetype, cups, alsa etc 50009 MISSING_DEPENDENCY=reduced 50010 50011 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50012 cygwin_help $MISSING_DEPENDENCY 50013 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50014 msys_help $MISSING_DEPENDENCY 50015 else 50016 PKGHANDLER_COMMAND= 50017 50018 case $PKGHANDLER in 50019 apt-get) 50020 apt_help $MISSING_DEPENDENCY ;; 50021 yum) 50022 yum_help $MISSING_DEPENDENCY ;; 50023 brew) 50024 brew_help $MISSING_DEPENDENCY ;; 50025 port) 50026 port_help $MISSING_DEPENDENCY ;; 50027 pkgutil) 50028 pkgutil_help $MISSING_DEPENDENCY ;; 50029 pkgadd) 50030 pkgadd_help $MISSING_DEPENDENCY ;; 50031 esac 50032 50033 if test "x$PKGHANDLER_COMMAND" != x; then 50034 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 50035 fi 50036 fi 50037 50038 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 50039 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 50040 elif test "x$COMPILE_TYPE" = xcross; then 50041 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 50042 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 50043 fi 50044 as_fn_error $? "Cannot continue." "$LINENO" 5 50045 50046 fi 50047 50048 done 50049 50050 50051 # The cast to long int works around a bug in the HP C Compiler 50052 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 50053 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 50054 # This bug is HP SR number 8606223364. 50055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 50056 $as_echo_n "checking size of int *... " >&6; } 50057 if ${ac_cv_sizeof_int_p+:} false; then : 50058 $as_echo_n "(cached) " >&6 50059 else 50060 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 50061 50062 else 50063 if test "$ac_cv_type_int_p" = yes; then 50064 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 50065 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 50066 as_fn_error 77 "cannot compute sizeof (int *) 50067 See \`config.log' for more details" "$LINENO" 5; } 50068 else 50069 ac_cv_sizeof_int_p=0 50070 fi 50071 fi 50072 50073 fi 50074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 50075 $as_echo "$ac_cv_sizeof_int_p" >&6; } 50076 50077 50078 50079 cat >>confdefs.h <<_ACEOF 50080 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 50081 _ACEOF 50082 50083 50084 50085 # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*' 50086 if test "x$ac_cv_sizeof_int_p" = x; then 50087 # The test failed, lets stick to the assumed value. 50088 { $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 50089 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;} 50090 else 50091 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 50092 50093 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 50094 # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects 50095 # Let's try to implicitely set the compilers target architecture and retry the test 50096 { $as_echo "$as_me:${as_lineno-$LINENO}: The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)." >&5 50097 $as_echo "$as_me: The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)." >&6;} 50098 { $as_echo "$as_me:${as_lineno-$LINENO}: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&5 50099 $as_echo "$as_me: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&6;} 50100 50101 # When we add flags to the "official" CFLAGS etc, we need to 50102 # keep track of these additions in ADDED_CFLAGS etc. These 50103 # will later be checked to make sure only controlled additions 50104 # have been made to CFLAGS etc. 50105 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50106 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50107 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50108 50109 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 50110 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 50111 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 50112 50113 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 50114 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 50115 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 50116 50117 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 50118 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 50119 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 50120 50121 50122 # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value! 50123 unset ac_cv_sizeof_int_p 50124 # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF 50125 cat >>confdefs.h <<_ACEOF 50126 #undef SIZEOF_INT_P 50127 _ACEOF 50128 50129 # The cast to long int works around a bug in the HP C Compiler 50130 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 50131 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 50132 # This bug is HP SR number 8606223364. 50133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 50134 $as_echo_n "checking size of int *... " >&6; } 50135 if ${ac_cv_sizeof_int_p+:} false; then : 50136 $as_echo_n "(cached) " >&6 50137 else 50138 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 50139 50140 else 50141 if test "$ac_cv_type_int_p" = yes; then 50142 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 50143 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 50144 as_fn_error 77 "cannot compute sizeof (int *) 50145 See \`config.log' for more details" "$LINENO" 5; } 50146 else 50147 ac_cv_sizeof_int_p=0 50148 fi 50149 fi 50150 50151 fi 50152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 50153 $as_echo "$ac_cv_sizeof_int_p" >&6; } 50154 50155 50156 50157 cat >>confdefs.h <<_ACEOF 50158 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 50159 _ACEOF 50160 50161 50162 50163 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 50164 50165 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 50166 { $as_echo "$as_me:${as_lineno-$LINENO}: The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)" >&5 50167 $as_echo "$as_me: The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)" >&6;} 50168 if test "x$COMPILE_TYPE" = xreduced; then 50169 50170 # Print a helpful message on how to acquire the necessary build dependency. 50171 # reduced is the help tag: freetype, cups, alsa etc 50172 MISSING_DEPENDENCY=reduced 50173 50174 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50175 cygwin_help $MISSING_DEPENDENCY 50176 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50177 msys_help $MISSING_DEPENDENCY 50178 else 50179 PKGHANDLER_COMMAND= 50180 50181 case $PKGHANDLER in 50182 apt-get) 50183 apt_help $MISSING_DEPENDENCY ;; 50184 yum) 50185 yum_help $MISSING_DEPENDENCY ;; 50186 brew) 50187 brew_help $MISSING_DEPENDENCY ;; 50188 port) 50189 port_help $MISSING_DEPENDENCY ;; 50190 pkgutil) 50191 pkgutil_help $MISSING_DEPENDENCY ;; 50192 pkgadd) 50193 pkgadd_help $MISSING_DEPENDENCY ;; 50194 esac 50195 50196 if test "x$PKGHANDLER_COMMAND" != x; then 50197 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 50198 fi 50199 fi 50200 50201 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 50202 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 50203 elif test "x$COMPILE_TYPE" = xcross; then 50204 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 50205 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 50206 fi 50207 as_fn_error $? "Cannot continue." "$LINENO" 5 50208 fi 50209 fi 50210 fi 50211 50212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5 50213 $as_echo_n "checking for target address size... " >&6; } 50214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5 50215 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; } 50216 50217 50218 ############################################################################### 50219 # 50220 # Is the target little of big endian? 50221 # 50222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 50223 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } 50224 if ${ac_cv_c_bigendian+:} false; then : 50225 $as_echo_n "(cached) " >&6 50226 else 50227 ac_cv_c_bigendian=unknown 50228 # See if we're dealing with a universal compiler. 50229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50230 /* end confdefs.h. */ 50231 #ifndef __APPLE_CC__ 50232 not a universal capable compiler 50233 #endif 50234 typedef int dummy; 50235 50236 _ACEOF 50237 if ac_fn_cxx_try_compile "$LINENO"; then : 50238 50239 # Check for potential -arch flags. It is not universal unless 50240 # there are at least two -arch flags with different values. 50241 ac_arch= 50242 ac_prev= 50243 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 50244 if test -n "$ac_prev"; then 50245 case $ac_word in 50246 i?86 | x86_64 | ppc | ppc64) 50247 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 50248 ac_arch=$ac_word 50249 else 50250 ac_cv_c_bigendian=universal 50251 break 50252 fi 50253 ;; 50254 esac 50255 ac_prev= 50256 elif test "x$ac_word" = "x-arch"; then 50257 ac_prev=arch 50258 fi 50259 done 50260 fi 50261 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50262 if test $ac_cv_c_bigendian = unknown; then 50263 # See if sys/param.h defines the BYTE_ORDER macro. 50264 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50265 /* end confdefs.h. */ 50266 #include <sys/types.h> 50267 #include <sys/param.h> 50268 50269 int 50270 main () 50271 { 50272 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 50273 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 50274 && LITTLE_ENDIAN) 50275 bogus endian macros 50276 #endif 50277 50278 ; 50279 return 0; 50280 } 50281 _ACEOF 50282 if ac_fn_cxx_try_compile "$LINENO"; then : 50283 # It does; now see whether it defined to BIG_ENDIAN or not. 50284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50285 /* end confdefs.h. */ 50286 #include <sys/types.h> 50287 #include <sys/param.h> 50288 50289 int 50290 main () 50291 { 50292 #if BYTE_ORDER != BIG_ENDIAN 50293 not big endian 50294 #endif 50295 50296 ; 50297 return 0; 50298 } 50299 _ACEOF 50300 if ac_fn_cxx_try_compile "$LINENO"; then : 50301 ac_cv_c_bigendian=yes 50302 else 50303 ac_cv_c_bigendian=no 50304 fi 50305 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50306 fi 50307 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50308 fi 50309 if test $ac_cv_c_bigendian = unknown; then 50310 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 50311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50312 /* end confdefs.h. */ 50313 #include <limits.h> 50314 50315 int 50316 main () 50317 { 50318 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 50319 bogus endian macros 50320 #endif 50321 50322 ; 50323 return 0; 50324 } 50325 _ACEOF 50326 if ac_fn_cxx_try_compile "$LINENO"; then : 50327 # It does; now see whether it defined to _BIG_ENDIAN or not. 50328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50329 /* end confdefs.h. */ 50330 #include <limits.h> 50331 50332 int 50333 main () 50334 { 50335 #ifndef _BIG_ENDIAN 50336 not big endian 50337 #endif 50338 50339 ; 50340 return 0; 50341 } 50342 _ACEOF 50343 if ac_fn_cxx_try_compile "$LINENO"; then : 50344 ac_cv_c_bigendian=yes 50345 else 50346 ac_cv_c_bigendian=no 50347 fi 50348 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50349 fi 50350 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50351 fi 50352 if test $ac_cv_c_bigendian = unknown; then 50353 # Compile a test program. 50354 if test "$cross_compiling" = yes; then : 50355 # Try to guess by grepping values from an object file. 50356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50357 /* end confdefs.h. */ 50358 short int ascii_mm[] = 50359 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 50360 short int ascii_ii[] = 50361 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 50362 int use_ascii (int i) { 50363 return ascii_mm[i] + ascii_ii[i]; 50364 } 50365 short int ebcdic_ii[] = 50366 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 50367 short int ebcdic_mm[] = 50368 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 50369 int use_ebcdic (int i) { 50370 return ebcdic_mm[i] + ebcdic_ii[i]; 50371 } 50372 extern int foo; 50373 50374 int 50375 main () 50376 { 50377 return use_ascii (foo) == use_ebcdic (foo); 50378 ; 50379 return 0; 50380 } 50381 _ACEOF 50382 if ac_fn_cxx_try_compile "$LINENO"; then : 50383 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 50384 ac_cv_c_bigendian=yes 50385 fi 50386 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 50387 if test "$ac_cv_c_bigendian" = unknown; then 50388 ac_cv_c_bigendian=no 50389 else 50390 # finding both strings is unlikely to happen, but who knows? 50391 ac_cv_c_bigendian=unknown 50392 fi 50393 fi 50394 fi 50395 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50396 else 50397 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50398 /* end confdefs.h. */ 50399 $ac_includes_default 50400 int 50401 main () 50402 { 50403 50404 /* Are we little or big endian? From Harbison&Steele. */ 50405 union 50406 { 50407 long int l; 50408 char c[sizeof (long int)]; 50409 } u; 50410 u.l = 1; 50411 return u.c[sizeof (long int) - 1] == 1; 50412 50413 ; 50414 return 0; 50415 } 50416 _ACEOF 50417 if ac_fn_cxx_try_run "$LINENO"; then : 50418 ac_cv_c_bigendian=no 50419 else 50420 ac_cv_c_bigendian=yes 50421 fi 50422 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 50423 conftest.$ac_objext conftest.beam conftest.$ac_ext 50424 fi 50425 50426 fi 50427 fi 50428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 50429 $as_echo "$ac_cv_c_bigendian" >&6; } 50430 case $ac_cv_c_bigendian in #( 50431 yes) 50432 ENDIAN="big";; #( 50433 no) 50434 ENDIAN="little" ;; #( 50435 universal) 50436 ENDIAN="universal_endianness" 50437 ;; #( 50438 *) 50439 ENDIAN="unknown" ;; 50440 esac 50441 50442 50443 if test "x$ENDIAN" = xuniversal_endianness; then 50444 as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5 50445 fi 50446 if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then 50447 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 50448 fi 50449 50450 50451 # Configure flags for the tools 50452 50453 ############################################################################### 50454 # 50455 # How to compile shared libraries. 50456 # 50457 50458 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50459 PICFLAG="-fPIC" 50460 C_FLAG_REORDER='' 50461 CXX_FLAG_REORDER='' 50462 50463 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50464 # Linking is different on MacOSX 50465 if test "x$STATIC_BUILD" = xtrue; then 50466 SHARED_LIBRARY_FLAGS ='-undefined dynamic_lookup' 50467 else 50468 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 50469 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 50470 fi 50471 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or $1,/.)' 50472 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 50473 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 50474 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 50475 else 50476 # Default works for linux, might work on other platforms as well. 50477 SHARED_LIBRARY_FLAGS='-shared' 50478 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$ORIGIN$1' 50479 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 50480 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 50481 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 50482 fi 50483 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50484 C_FLAG_REORDER='' 50485 CXX_FLAG_REORDER='' 50486 50487 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50488 # Linking is different on MacOSX 50489 PICFLAG='' 50490 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 50491 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or $1,/.)' 50492 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 50493 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 50494 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 50495 50496 if test "x$STATIC_BUILD" = xfalse; then 50497 JVM_CFLAGS="$JVM_CFLAGS -fPIC" 50498 fi 50499 else 50500 # Default works for linux, might work on other platforms as well. 50501 PICFLAG='-fPIC' 50502 SHARED_LIBRARY_FLAGS='-shared' 50503 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$ORIGIN$1' 50504 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 50505 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 50506 50507 # arm specific settings 50508 if test "x$OPENJDK_TARGET_CPU" = "xarm"; then 50509 # '-Wl,-z,origin' isn't used on arm. 50510 SET_SHARED_LIBRARY_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 50511 else 50512 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 50513 fi 50514 50515 fi 50516 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50517 if test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50518 PICFLAG="-xcode=pic32" 50519 else 50520 PICFLAG="-KPIC" 50521 fi 50522 C_FLAG_REORDER='-xF' 50523 CXX_FLAG_REORDER='-xF' 50524 SHARED_LIBRARY_FLAGS="-G" 50525 SET_EXECUTABLE_ORIGIN='-R\$$ORIGIN$1' 50526 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 50527 SET_SHARED_LIBRARY_NAME='-h $1' 50528 SET_SHARED_LIBRARY_MAPFILE='-M$1' 50529 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50530 # '-qpic' defaults to 'qpic=small'. This means that the compiler generates only 50531 # one instruction for accessing the TOC. If the TOC grows larger than 64K, the linker 50532 # will have to patch this single instruction with a call to some out-of-order code which 50533 # does the load from the TOC. This is of course slow. But in that case we also would have 50534 # to use '-bbigtoc' for linking anyway so we could also change the PICFLAG to 'qpic=large'. 50535 # With 'qpic=large' the compiler will by default generate a two-instruction sequence which 50536 # can be patched directly by the linker and does not require a jump to out-of-order code. 50537 # Another alternative instead of using 'qpic=large -bbigtoc' may be to use '-qminimaltoc' 50538 # instead. This creates a distinct TOC for every compilation unit (and thus requires two 50539 # loads for accessing a global variable). But there are rumors that this may be seen as a 50540 # 'performance feature' because of improved code locality of the symbols used in a 50541 # compilation unit. 50542 PICFLAG="-qpic" 50543 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 50544 C_FLAG_REORDER='' 50545 CXX_FLAG_REORDER='' 50546 SHARED_LIBRARY_FLAGS="-qmkshrobj -bM:SRE -bnoentry" 50547 SET_EXECUTABLE_ORIGIN="" 50548 SET_SHARED_LIBRARY_ORIGIN='' 50549 SET_SHARED_LIBRARY_NAME='' 50550 SET_SHARED_LIBRARY_MAPFILE='' 50551 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50552 PICFLAG="" 50553 C_FLAG_REORDER='' 50554 CXX_FLAG_REORDER='' 50555 SHARED_LIBRARY_FLAGS="-dll" 50556 SET_EXECUTABLE_ORIGIN='' 50557 SET_SHARED_LIBRARY_ORIGIN='' 50558 SET_SHARED_LIBRARY_NAME='' 50559 SET_SHARED_LIBRARY_MAPFILE='-def:$1' 50560 fi 50561 50562 50563 50564 50565 50566 50567 50568 50569 50570 # The (cross) compiler is now configured, we can now test capabilities 50571 # of the target platform. 50572 50573 50574 50575 ############################################################################### 50576 # 50577 # Setup the opt flags for different compilers 50578 # and different operating systems. 50579 # 50580 50581 # FIXME: this was indirectly the old default, but just inherited. 50582 # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50583 # C_FLAG_DEPS="-MMD -MF" 50584 # fi 50585 50586 # Generate make dependency files 50587 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50588 C_FLAG_DEPS="-MMD -MF" 50589 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50590 C_FLAG_DEPS="-MMD -MF" 50591 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50592 C_FLAG_DEPS="-xMMD -xMF" 50593 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50594 C_FLAG_DEPS="-qmakedep=gcc -MF" 50595 fi 50596 CXX_FLAG_DEPS="$C_FLAG_DEPS" 50597 50598 50599 50600 # Debug symbols 50601 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50602 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then 50603 # reduce from default "-g2" option to save space 50604 CFLAGS_DEBUG_SYMBOLS="-g1" 50605 CXXFLAGS_DEBUG_SYMBOLS="-g1" 50606 else 50607 CFLAGS_DEBUG_SYMBOLS="-g" 50608 CXXFLAGS_DEBUG_SYMBOLS="-g" 50609 fi 50610 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50611 CFLAGS_DEBUG_SYMBOLS="-g" 50612 CXXFLAGS_DEBUG_SYMBOLS="-g" 50613 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50614 CFLAGS_DEBUG_SYMBOLS="-g -xs" 50615 # -g0 enables debug symbols without disabling inlining. 50616 CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs" 50617 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50618 CFLAGS_DEBUG_SYMBOLS="-g" 50619 CXXFLAGS_DEBUG_SYMBOLS="-g" 50620 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50621 CFLAGS_DEBUG_SYMBOLS="-Zi" 50622 CXXFLAGS_DEBUG_SYMBOLS="-Zi" 50623 fi 50624 50625 50626 50627 # Debug symbols for JVM_CFLAGS 50628 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50629 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -xs" 50630 if test "x$DEBUG_LEVEL" = xslowdebug; then 50631 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 50632 else 50633 # -g0 does not disable inlining, which -g does. 50634 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g0" 50635 fi 50636 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50637 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -Z7 -d2Zi+" 50638 else 50639 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 50640 fi 50641 50642 50643 # bounds, memory and behavior checking options 50644 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50645 case $DEBUG_LEVEL in 50646 release ) 50647 # no adjustment 50648 ;; 50649 fastdebug ) 50650 # no adjustment 50651 ;; 50652 slowdebug ) 50653 # FIXME: By adding this to C(XX)FLAGS_DEBUG_OPTIONS/JVM_CFLAGS_SYMBOLS it 50654 # get's added conditionally on whether we produce debug symbols or not. 50655 # This is most likely not really correct. 50656 50657 # Add runtime stack smashing and undefined behavior checks. 50658 # Not all versions of gcc support -fstack-protector 50659 STACK_PROTECTOR_CFLAG="-fstack-protector-all" 50660 50661 50662 50663 50664 50665 50666 50667 50668 50669 50670 50671 50672 50673 50674 50675 50676 50677 50678 50679 50680 50681 50682 50683 50684 50685 50686 50687 50688 50689 50690 50691 50692 50693 50694 50695 50696 50697 50698 50699 50700 50701 50702 # Execute function body 50703 50704 50705 50706 50707 50708 50709 50710 50711 50712 50713 50714 50715 50716 50717 50718 50719 50720 50721 50722 50723 50724 50725 50726 50727 50728 50729 50730 50731 50732 50733 50734 50735 50736 50737 50738 50739 50740 50741 50742 50743 50744 50745 50746 50747 50748 50749 50750 50751 # Execute function body 50752 50753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 50754 $as_echo_n "checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 50755 supports=yes 50756 50757 saved_cflags="$CFLAGS" 50758 CFLAGS="$CFLAGS $STACK_PROTECTOR_CFLAG -Werror" 50759 ac_ext=c 50760 ac_cpp='$CPP $CPPFLAGS' 50761 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50762 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50763 ac_compiler_gnu=$ac_cv_c_compiler_gnu 50764 50765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50766 /* end confdefs.h. */ 50767 int i; 50768 _ACEOF 50769 if ac_fn_c_try_compile "$LINENO"; then : 50770 50771 else 50772 supports=no 50773 fi 50774 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50775 ac_ext=cpp 50776 ac_cpp='$CXXCPP $CPPFLAGS' 50777 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50778 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50779 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50780 50781 CFLAGS="$saved_cflags" 50782 50783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50784 $as_echo "$supports" >&6; } 50785 if test "x$supports" = "xyes" ; then 50786 : 50787 C_COMP_SUPPORTS="yes" 50788 else 50789 : 50790 C_COMP_SUPPORTS="no" 50791 fi 50792 50793 50794 50795 50796 50797 50798 50799 50800 50801 50802 50803 50804 50805 50806 50807 50808 50809 50810 50811 50812 50813 50814 50815 50816 50817 50818 50819 50820 50821 50822 50823 50824 50825 50826 50827 50828 50829 50830 50831 50832 50833 50834 50835 50836 50837 50838 50839 50840 50841 50842 50843 50844 50845 50846 50847 50848 50849 50850 50851 # Execute function body 50852 50853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 50854 $as_echo_n "checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 50855 supports=yes 50856 50857 saved_cxxflags="$CXXFLAGS" 50858 CXXFLAGS="$CXXFLAG $STACK_PROTECTOR_CFLAG -Werror" 50859 ac_ext=cpp 50860 ac_cpp='$CXXCPP $CPPFLAGS' 50861 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50862 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50863 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50864 50865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50866 /* end confdefs.h. */ 50867 int i; 50868 _ACEOF 50869 if ac_fn_cxx_try_compile "$LINENO"; then : 50870 50871 else 50872 supports=no 50873 fi 50874 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50875 ac_ext=cpp 50876 ac_cpp='$CXXCPP $CPPFLAGS' 50877 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50878 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50879 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50880 50881 CXXFLAGS="$saved_cxxflags" 50882 50883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50884 $as_echo "$supports" >&6; } 50885 if test "x$supports" = "xyes" ; then 50886 : 50887 CXX_COMP_SUPPORTS="yes" 50888 else 50889 : 50890 CXX_COMP_SUPPORTS="no" 50891 fi 50892 50893 50894 50895 50896 50897 50898 50899 50900 50901 50902 50903 50904 50905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 50906 $as_echo_n "checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 50907 supports=no 50908 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 50909 50910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50911 $as_echo "$supports" >&6; } 50912 if test "x$supports" = "xyes" ; then 50913 : 50914 50915 else 50916 : 50917 STACK_PROTECTOR_CFLAG="" 50918 fi 50919 50920 50921 50922 50923 50924 50925 50926 CFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 50927 CXXFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 50928 if test "x$STACK_PROTECTOR_CFLAG" != x; then 50929 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS $STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 50930 fi 50931 ;; 50932 esac 50933 fi 50934 50935 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50936 if test "x$DEBUG_LEVEL" != xrelease; then 50937 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 50938 JVM_CFLAGS="$JVM_CFLAGS -homeparams" 50939 fi 50940 fi 50941 fi 50942 50943 # Optimization levels 50944 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50945 CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xbuiltin=%all -xdepend -xrestrict -xlibmil" 50946 50947 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 50948 # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global? 50949 C_O_FLAG_HIGHEST_JVM="-xO4" 50950 C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xalias_level=basic -xregs=no%frameptr" 50951 C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr" 50952 C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr" 50953 C_O_FLAG_DEBUG="-xregs=no%frameptr" 50954 C_O_FLAG_DEBUG_JVM="" 50955 C_O_FLAG_NONE="-xregs=no%frameptr" 50956 CXX_O_FLAG_HIGHEST_JVM="-xO4" 50957 CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr" 50958 CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr" 50959 CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr" 50960 CXX_O_FLAG_DEBUG="-xregs=no%frameptr" 50961 CXX_O_FLAG_DEBUG_JVM="" 50962 CXX_O_FLAG_NONE="-xregs=no%frameptr" 50963 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 50964 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium" 50965 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium" 50966 fi 50967 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 50968 C_O_FLAG_HIGHEST_JVM="-xO4" 50969 C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xalias_level=basic -xprefetch=auto,explicit -xchip=ultra" 50970 C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0" 50971 C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0" 50972 C_O_FLAG_DEBUG="" 50973 C_O_FLAG_DEBUG_JVM="" 50974 C_O_FLAG_NONE="" 50975 CXX_O_FLAG_HIGHEST_JVM="-xO4" 50976 CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 50977 CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 50978 CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 50979 CXX_O_FLAG_DEBUG="" 50980 CXX_O_FLAG_DEBUG_JVM="" 50981 CXX_O_FLAG_NONE="" 50982 fi 50983 else 50984 # The remaining toolchains share opt flags between CC and CXX; 50985 # setup for C and duplicate afterwards. 50986 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50987 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50988 # On MacOSX we optimize for size, something 50989 # we should do for all platforms? 50990 C_O_FLAG_HIGHEST_JVM="-Os" 50991 C_O_FLAG_HIGHEST="-Os" 50992 C_O_FLAG_HI="-Os" 50993 C_O_FLAG_NORM="-Os" 50994 C_O_FLAG_SIZE="-Os" 50995 else 50996 C_O_FLAG_HIGHEST_JVM="-O3" 50997 C_O_FLAG_HIGHEST="-O3" 50998 C_O_FLAG_HI="-O3" 50999 C_O_FLAG_NORM="-O2" 51000 C_O_FLAG_SIZE="-Os" 51001 fi 51002 C_O_FLAG_DEBUG="-O0" 51003 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51004 C_O_FLAG_DEBUG_JVM="" 51005 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 51006 C_O_FLAG_DEBUG_JVM="-O0" 51007 fi 51008 C_O_FLAG_NONE="-O0" 51009 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51010 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51011 # On MacOSX we optimize for size, something 51012 # we should do for all platforms? 51013 C_O_FLAG_HIGHEST_JVM="-Os" 51014 C_O_FLAG_HIGHEST="-Os" 51015 C_O_FLAG_HI="-Os" 51016 C_O_FLAG_NORM="-Os" 51017 C_O_FLAG_SIZE="-Os" 51018 else 51019 C_O_FLAG_HIGHEST_JVM="-O3" 51020 C_O_FLAG_HIGHEST="-O3" 51021 C_O_FLAG_HI="-O3" 51022 C_O_FLAG_NORM="-O2" 51023 C_O_FLAG_SIZE="-Os" 51024 fi 51025 C_O_FLAG_DEBUG="-O0" 51026 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51027 C_O_FLAG_DEBUG_JVM="" 51028 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 51029 C_O_FLAG_DEBUG_JVM="-O0" 51030 fi 51031 C_O_FLAG_NONE="-O0" 51032 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51033 C_O_FLAG_HIGHEST_JVM="-O3 -qhot=level=1 -qinline -qinlglue" 51034 C_O_FLAG_HIGHEST="-O3 -qhot=level=1 -qinline -qinlglue" 51035 C_O_FLAG_HI="-O3 -qinline -qinlglue" 51036 C_O_FLAG_NORM="-O2" 51037 C_O_FLAG_DEBUG="-qnoopt" 51038 # FIXME: Value below not verified. 51039 C_O_FLAG_DEBUG_JVM="" 51040 C_O_FLAG_NONE="-qnoopt" 51041 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51042 C_O_FLAG_HIGHEST_JVM="-O2 -Oy-" 51043 C_O_FLAG_HIGHEST="-O2" 51044 C_O_FLAG_HI="-O1" 51045 C_O_FLAG_NORM="-O1" 51046 C_O_FLAG_DEBUG="-Od" 51047 C_O_FLAG_DEBUG_JVM="" 51048 C_O_FLAG_NONE="-Od" 51049 C_O_FLAG_SIZE="-Os" 51050 fi 51051 CXX_O_FLAG_HIGHEST_JVM="$C_O_FLAG_HIGHEST_JVM" 51052 CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST" 51053 CXX_O_FLAG_HI="$C_O_FLAG_HI" 51054 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 51055 CXX_O_FLAG_DEBUG="$C_O_FLAG_DEBUG" 51056 CXX_O_FLAG_DEBUG_JVM="$C_O_FLAG_DEBUG_JVM" 51057 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 51058 CXX_O_FLAG_SIZE="$C_O_FLAG_SIZE" 51059 fi 51060 51061 # Adjust optimization flags according to debug level. 51062 case $DEBUG_LEVEL in 51063 release ) 51064 # no adjustment 51065 ;; 51066 fastdebug ) 51067 # Not quite so much optimization 51068 C_O_FLAG_HI="$C_O_FLAG_NORM" 51069 CXX_O_FLAG_HI="$CXX_O_FLAG_NORM" 51070 ;; 51071 slowdebug ) 51072 # Disable optimization 51073 C_O_FLAG_HIGHEST_JVM="$C_O_FLAG_DEBUG_JVM" 51074 C_O_FLAG_HIGHEST="$C_O_FLAG_DEBUG" 51075 C_O_FLAG_HI="$C_O_FLAG_DEBUG" 51076 C_O_FLAG_NORM="$C_O_FLAG_DEBUG" 51077 C_O_FLAG_SIZE="$C_O_FLAG_DEBUG" 51078 CXX_O_FLAG_HIGHEST_JVM="$CXX_O_FLAG_DEBUG_JVM" 51079 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_DEBUG" 51080 CXX_O_FLAG_HI="$CXX_O_FLAG_DEBUG" 51081 CXX_O_FLAG_NORM="$CXX_O_FLAG_DEBUG" 51082 CXX_O_FLAG_SIZE="$CXX_O_FLAG_DEBUG" 51083 ;; 51084 esac 51085 51086 51087 51088 51089 51090 51091 51092 51093 51094 51095 51096 51097 51098 51099 51100 51101 51102 51103 51104 51105 # Check whether --with-abi-profile was given. 51106 if test "${with_abi_profile+set}" = set; then : 51107 withval=$with_abi_profile; 51108 fi 51109 51110 51111 if test "x$with_abi_profile" != x; then 51112 if test "x$OPENJDK_TARGET_CPU" != xarm && \ 51113 test "x$OPENJDK_TARGET_CPU" != xaarch64; then 51114 as_fn_error $? "--with-abi-profile only available on arm/aarch64" "$LINENO" 5 51115 fi 51116 51117 OPENJDK_TARGET_ABI_PROFILE=$with_abi_profile 51118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ABI profle" >&5 51119 $as_echo_n "checking for ABI profle... " >&6; } 51120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_ABI_PROFILE" >&5 51121 $as_echo "$OPENJDK_TARGET_ABI_PROFILE" >&6; } 51122 51123 if test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-vfp-sflt; then 51124 ARM_FLOAT_TYPE=vfp-sflt 51125 ARM_ARCH_TYPE_FLAGS='-march=armv7-a -mthumb' 51126 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-vfp-hflt; then 51127 ARM_FLOAT_TYPE=vfp-hflt 51128 ARM_ARCH_TYPE_FLAGS='-march=armv7-a -mthumb' 51129 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-sflt; then 51130 ARM_FLOAT_TYPE=sflt 51131 ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm' 51132 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarmv5-vfp-sflt; then 51133 ARM_FLOAT_TYPE=vfp-sflt 51134 ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm' 51135 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarmv6-vfp-hflt; then 51136 ARM_FLOAT_TYPE=vfp-hflt 51137 ARM_ARCH_TYPE_FLAGS='-march=armv6 -marm' 51138 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm64; then 51139 # No special flags, just need to trigger setting JDK_ARCH_ABI_PROP_NAME 51140 ARM_FLOAT_TYPE= 51141 ARM_ARCH_TYPE_FLAGS= 51142 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xaarch64; then 51143 # No special flags, just need to trigger setting JDK_ARCH_ABI_PROP_NAME 51144 ARM_FLOAT_TYPE= 51145 ARM_ARCH_TYPE_FLAGS= 51146 else 51147 as_fn_error $? "Invalid ABI profile: \"$OPENJDK_TARGET_ABI_PROFILE\"" "$LINENO" 5 51148 fi 51149 51150 if test "x$ARM_FLOAT_TYPE" = xvfp-sflt; then 51151 ARM_FLOAT_TYPE_FLAGS='-mfloat-abi=softfp -mfpu=vfp -DFLOAT_ARCH=-vfp-sflt' 51152 elif test "x$ARM_FLOAT_TYPE" = xvfp-hflt; then 51153 ARM_FLOAT_TYPE_FLAGS='-mfloat-abi=hard -mfpu=vfp -DFLOAT_ARCH=-vfp-hflt' 51154 elif test "x$ARM_FLOAT_TYPE" = xsflt; then 51155 ARM_FLOAT_TYPE_FLAGS='-msoft-float -mfpu=vfp' 51156 fi 51157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ARM_FLOAT_TYPE floating point flags" >&5 51158 $as_echo_n "checking for $ARM_FLOAT_TYPE floating point flags... " >&6; } 51159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ARM_FLOAT_TYPE_FLAGS" >&5 51160 $as_echo "$ARM_FLOAT_TYPE_FLAGS" >&6; } 51161 51162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for arch type flags" >&5 51163 $as_echo_n "checking for arch type flags... " >&6; } 51164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ARM_ARCH_TYPE_FLAGS" >&5 51165 $as_echo "$ARM_ARCH_TYPE_FLAGS" >&6; } 51166 51167 # Now set JDK_ARCH_ABI_PROP_NAME. This is equivalent to the last part of the 51168 # autoconf target triplet. 51169 JDK_ARCH_ABI_PROP_NAME=`$ECHO $OPENJDK_TARGET_AUTOCONF_NAME | $SED -e 's/.*-\([^-]*\)$/\1/'` 51170 # Sanity check that it is a known ABI. 51171 if test "x$JDK_ARCH_ABI_PROP_NAME" != xgnu && \ 51172 test "x$JDK_ARCH_ABI_PROP_NAME" != xgnueabi && \ 51173 test "x$JDK_ARCH_ABI_PROP_NAME" != xgnueabihf; then 51174 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unknown autoconf target triplet ABI: \"$JDK_ARCH_ABI_PROP_NAME\"" >&5 51175 $as_echo "$as_me: WARNING: Unknown autoconf target triplet ABI: \"$JDK_ARCH_ABI_PROP_NAME\"" >&2;} 51176 fi 51177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ABI property name" >&5 51178 $as_echo_n "checking for ABI property name... " >&6; } 51179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_ARCH_ABI_PROP_NAME" >&5 51180 $as_echo "$JDK_ARCH_ABI_PROP_NAME" >&6; } 51181 51182 51183 # Pass these on to the open part of configure as if they were set using 51184 # --with-extra-c[xx]flags. 51185 EXTRA_CFLAGS="$EXTRA_CFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 51186 EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 51187 # Get rid of annoying "note: the mangling of 'va_list' has changed in GCC 4.4" 51188 # FIXME: This should not really be set using extra_cflags. 51189 if test "x$OPENJDK_TARGET_CPU" = xarm; then 51190 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wno-psabi" 51191 EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -Wno-psabi" 51192 fi 51193 # Also add JDK_ARCH_ABI_PROP_NAME define, but only to CFLAGS. 51194 EXTRA_CFLAGS="$EXTRA_CFLAGS -DJDK_ARCH_ABI_PROP_NAME='\"\$(JDK_ARCH_ABI_PROP_NAME)\"'" 51195 # And pass the architecture flags to the linker as well 51196 EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 51197 fi 51198 51199 # When building with an abi profile, the name of that profile is appended on the 51200 # bundle platform, which is used in bundle names. 51201 if test "x$OPENJDK_TARGET_ABI_PROFILE" != x; then 51202 OPENJDK_TARGET_BUNDLE_PLATFORM="$OPENJDK_TARGET_OS_BUNDLE-$OPENJDK_TARGET_ABI_PROFILE" 51203 fi 51204 51205 51206 # Optional POSIX functionality needed by the JVM 51207 # 51208 # Check if clock_gettime is available and in which library. This indicates 51209 # availability of CLOCK_MONOTONIC for hotspot. But we don't need to link, so 51210 # don't let it update LIBS. 51211 save_LIBS="$LIBS" 51212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 51213 $as_echo_n "checking for library containing clock_gettime... " >&6; } 51214 if ${ac_cv_search_clock_gettime+:} false; then : 51215 $as_echo_n "(cached) " >&6 51216 else 51217 ac_func_search_save_LIBS=$LIBS 51218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51219 /* end confdefs.h. */ 51220 51221 /* Override any GCC internal prototype to avoid an error. 51222 Use char because int might match the return type of a GCC 51223 builtin and then its argument prototype would still apply. */ 51224 #ifdef __cplusplus 51225 extern "C" 51226 #endif 51227 char clock_gettime (); 51228 int 51229 main () 51230 { 51231 return clock_gettime (); 51232 ; 51233 return 0; 51234 } 51235 _ACEOF 51236 for ac_lib in '' rt; do 51237 if test -z "$ac_lib"; then 51238 ac_res="none required" 51239 else 51240 ac_res=-l$ac_lib 51241 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 51242 fi 51243 if ac_fn_cxx_try_link "$LINENO"; then : 51244 ac_cv_search_clock_gettime=$ac_res 51245 fi 51246 rm -f core conftest.err conftest.$ac_objext \ 51247 conftest$ac_exeext 51248 if ${ac_cv_search_clock_gettime+:} false; then : 51249 break 51250 fi 51251 done 51252 if ${ac_cv_search_clock_gettime+:} false; then : 51253 51254 else 51255 ac_cv_search_clock_gettime=no 51256 fi 51257 rm conftest.$ac_ext 51258 LIBS=$ac_func_search_save_LIBS 51259 fi 51260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5 51261 $as_echo "$ac_cv_search_clock_gettime" >&6; } 51262 ac_res=$ac_cv_search_clock_gettime 51263 if test "$ac_res" != no; then : 51264 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 51265 HAS_CLOCK_GETTIME=true 51266 fi 51267 51268 if test "x$LIBS" = "x-lrt "; then 51269 CLOCK_GETTIME_IN_LIBRT=true 51270 fi 51271 LIBS="$save_LIBS" 51272 51273 51274 # Special extras... 51275 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51276 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 51277 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 51278 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 51279 fi 51280 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 51281 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 51282 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51283 CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 51284 CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 51285 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51286 CXXSTD_CXXFLAG="-std=gnu++98" 51287 51288 51289 51290 51291 51292 51293 51294 51295 51296 51297 51298 51299 51300 51301 51302 51303 51304 51305 51306 51307 51308 51309 51310 51311 51312 51313 51314 51315 51316 51317 51318 51319 51320 51321 51322 51323 51324 51325 51326 51327 51328 51329 # Execute function body 51330 51331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"" >&5 51332 $as_echo_n "checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"... " >&6; } 51333 supports=yes 51334 51335 saved_cxxflags="$CXXFLAGS" 51336 CXXFLAGS="$CXXFLAG $CXXSTD_CXXFLAG -Werror" 51337 ac_ext=cpp 51338 ac_cpp='$CXXCPP $CPPFLAGS' 51339 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51340 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51341 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51342 51343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51344 /* end confdefs.h. */ 51345 int i; 51346 _ACEOF 51347 if ac_fn_cxx_try_compile "$LINENO"; then : 51348 51349 else 51350 supports=no 51351 fi 51352 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51353 ac_ext=cpp 51354 ac_cpp='$CXXCPP $CPPFLAGS' 51355 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51356 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51357 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51358 51359 CXXFLAGS="$saved_cxxflags" 51360 51361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51362 $as_echo "$supports" >&6; } 51363 if test "x$supports" = "xyes" ; then 51364 : 51365 51366 else 51367 : 51368 CXXSTD_CXXFLAG="" 51369 fi 51370 51371 51372 51373 51374 51375 51376 51377 51378 51379 51380 51381 51382 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${CXXSTD_CXXFLAG}" 51383 JVM_CFLAGS="${JVM_CFLAGS} ${CXXSTD_CXXFLAG}" 51384 51385 fi 51386 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 51387 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 51388 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 51389 fi 51390 51391 CFLAGS_JDK="${CFLAGS_JDK} ${EXTRA_CFLAGS}" 51392 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${EXTRA_CXXFLAGS}" 51393 LDFLAGS_JDK="${LDFLAGS_JDK} ${EXTRA_LDFLAGS}" 51394 51395 ############################################################################### 51396 # 51397 # Now setup the CFLAGS and LDFLAGS for the JDK build. 51398 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 51399 # 51400 51401 # Setup compiler/platform specific flags into 51402 # CFLAGS_JDK - C Compiler flags 51403 # CXXFLAGS_JDK - C++ Compiler flags 51404 # COMMON_CCXXFLAGS_JDK - common to C and C++ 51405 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51406 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 51407 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT" 51408 JVM_CFLAGS="$JVM_CFLAGS -fcheck-new" 51409 if test "x$OPENJDK_TARGET_CPU" = xx86; then 51410 # Force compatibility with i586 on 32 bit intel platforms. 51411 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 51412 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 51413 fi 51414 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 51415 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 51416 case $OPENJDK_TARGET_CPU_ARCH in 51417 arm ) 51418 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 51419 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51420 COMMON_CCXXFLAGS_JDK="${COMMON_CCXXFLAGS_JDK} -fsigned-char" 51421 ;; 51422 ppc ) 51423 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 51424 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51425 ;; 51426 s390 ) 51427 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer -mbackchain -march=z10" 51428 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51429 ;; 51430 * ) 51431 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 51432 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51433 ;; 51434 esac 51435 51436 51437 51438 51439 51440 51441 51442 51443 51444 51445 51446 51447 51448 51449 51450 51451 51452 51453 51454 51455 51456 51457 51458 51459 51460 51461 51462 51463 51464 51465 51466 51467 51468 51469 51470 51471 51472 51473 51474 51475 51476 51477 51478 51479 51480 51481 51482 51483 51484 51485 51486 51487 51488 51489 # Execute function body 51490 51491 # Need to assign to a variable since m4 is blocked from modifying parts in []. 51492 REFERENCE_VERSION=6 51493 51494 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 51495 as_fn_error $? "Internal error: Cannot compare to 6, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 51496 fi 51497 51498 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 51499 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 51500 fi 51501 51502 # Version comparison method inspired by http://stackoverflow.com/a/24067243 51503 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 51504 51505 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 51506 : 51507 51508 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 51509 # runs afoul of the more aggressive versions of these optimisations. 51510 # Notably, value range propagation now assumes that the this pointer of C++ 51511 # member functions is non-null. 51512 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 51513 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 51514 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 51515 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 51516 CFLAGS_JDK="$CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 51517 JVM_CFLAGS="$JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 51518 51519 else 51520 : 51521 51522 fi 51523 51524 51525 51526 51527 51528 51529 51530 51531 51532 51533 51534 51535 51536 51537 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51538 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 51539 51540 # Restrict the debug information created by Clang to avoid 51541 # too big object files and speed the build up a little bit 51542 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 51543 JVM_CFLAGS="$JVM_CFLAGS -flimit-debug-info" 51544 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51545 if test "x$OPENJDK_TARGET_CPU" = xx86; then 51546 # Force compatibility with i586 on 32 bit intel platforms. 51547 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 51548 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 51549 fi 51550 JVM_CFLAGS="$JVM_CFLAGS -Wno-sometimes-uninitialized" 51551 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 51552 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 51553 case $OPENJDK_TARGET_CPU_ARCH in 51554 ppc ) 51555 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 51556 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51557 ;; 51558 * ) 51559 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 51560 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51561 ;; 51562 esac 51563 fi 51564 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51565 JVM_CFLAGS="$JVM_CFLAGS -DSPARC_WORKS" 51566 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 51567 if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 51568 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 51569 fi 51570 51571 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 51572 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 51573 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51574 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT" 51575 CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 51576 CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 51577 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51578 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK \ 51579 -MD -Zc:wchar_t- -W3 -wd4800 \ 51580 -DWIN32_LEAN_AND_MEAN \ 51581 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 51582 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 51583 -DWIN32 -DIAL" 51584 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 51585 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 51586 else 51587 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 51588 fi 51589 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 51590 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 51591 # studio. 51592 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 51593 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 51594 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 51595 JVM_CFLAGS="$JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 51596 fi 51597 fi 51598 51599 ############################################################################### 51600 51601 # Adjust flags according to debug level. 51602 case $DEBUG_LEVEL in 51603 fastdebug | slowdebug ) 51604 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 51605 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 51606 ;; 51607 release ) 51608 ;; 51609 * ) 51610 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 51611 ;; 51612 esac 51613 51614 # Set some common defines. These works for all compilers, but assume 51615 # -D is universally accepted. 51616 51617 # Setup endianness 51618 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 51619 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 51620 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 51621 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 51622 # Note: -Dmacro is the same as #define macro 1 51623 # -Dmacro= is the same as #define macro 51624 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 51625 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 51626 else 51627 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 51628 fi 51629 else 51630 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 51631 # are defined in the system? 51632 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 51633 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 51634 else 51635 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 51636 fi 51637 fi 51638 51639 # Always enable optional macros for VM. 51640 JVM_CFLAGS="$JVM_CFLAGS -D__STDC_FORMAT_MACROS" 51641 JVM_CFLAGS="$JVM_CFLAGS -D__STDC_LIMIT_MACROS" 51642 JVM_CFLAGS="$JVM_CFLAGS -D__STDC_CONSTANT_MACROS" 51643 51644 # Setup target OS define. Use OS target name but in upper case. 51645 OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 51646 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE" 51647 51648 # Setup target CPU 51649 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 51650 $OPENJDK_TARGET_ADD_LP64 \ 51651 -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 51652 51653 # Setup debug/release defines 51654 if test "x$DEBUG_LEVEL" = xrelease; then 51655 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG" 51656 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 51657 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED" 51658 fi 51659 else 51660 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG" 51661 fi 51662 51663 # Optional POSIX functionality needed by the VM 51664 51665 if test "x$HAS_CLOCK_GETTIME" = "xtrue"; then 51666 JVM_CFLAGS="$JVM_CFLAGS -DSUPPORTS_CLOCK_MONOTONIC" 51667 if test "x$CLOCK_GETTIME_IN_LIBRT" = "xtrue"; then 51668 JVM_CFLAGS="$JVM_CFLAGS -DNEEDS_LIBRT" 51669 fi 51670 fi 51671 51672 51673 # Set some additional per-OS defines. 51674 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51675 JVM_CFLAGS="$JVM_CFLAGS -DLINUX" 51676 JVM_CFLAGS="$JVM_CFLAGS -pipe $PICFLAG -fno-rtti -fno-exceptions \ 51677 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 51678 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 51679 JVM_CFLAGS="$JVM_CFLAGS -DSOLARIS" 51680 JVM_CFLAGS="$JVM_CFLAGS -template=no%extdef -features=no%split_init \ 51681 -D_Crun_inline_placement -library=stlport4 $PICFLAG -mt -features=no%except" 51682 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 51683 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 51684 JVM_CFLAGS="$JVM_CFLAGS -D_ALLBSD_SOURCE" 51685 JVM_CFLAGS="$JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 51686 JVM_CFLAGS="$JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 51687 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 51688 -fno-omit-frame-pointer" 51689 elif test "x$OPENJDK_TARGET_OS" = xaix; then 51690 JVM_CFLAGS="$JVM_CFLAGS -DAIX" 51691 JVM_CFLAGS="$JVM_CFLAGS -qtune=balanced \ 51692 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 51693 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 51694 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 51695 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 51696 # so for slowdebug we build with '-qpic=large -bbigtoc'. 51697 if test "x$DEBUG_LEVEL" = xslowdebug; then 51698 JVM_CFLAGS="$JVM_CFLAGS -qpic=large" 51699 fi 51700 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 51701 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 51702 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 51703 JVM_CFLAGS="$JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 51704 JVM_CFLAGS="$JVM_CFLAGS -nologo -W3 -MD -MP" 51705 fi 51706 51707 # Set some additional per-CPU defines. 51708 if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xwindows-x86; then 51709 JVM_CFLAGS="$JVM_CFLAGS -arch:IA32" 51710 elif test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xsolaris-sparcv9; then 51711 JVM_CFLAGS="$JVM_CFLAGS -xarch=sparc" 51712 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 51713 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51714 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 51715 # fixes `relocation truncated to fit' error for gcc 4.1. 51716 JVM_CFLAGS="$JVM_CFLAGS -mminimal-toc" 51717 # Use ppc64 instructions, but schedule for power5 51718 JVM_CFLAGS="$JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 51719 elif test "x$OPENJDK_TARGET_OS" = xaix; then 51720 JVM_CFLAGS="$JVM_CFLAGS -qarch=ppc64" 51721 fi 51722 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 51723 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51724 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 51725 # Little endian machine uses ELFv2 ABI. 51726 JVM_CFLAGS="$JVM_CFLAGS -DABI_ELFv2" 51727 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 51728 JVM_CFLAGS="$JVM_CFLAGS -mcpu=power8 -mtune=power8" 51729 fi 51730 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 51731 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51732 JVM_CFLAGS="$JVM_CFLAGS -mbackchain -march=z10" 51733 fi 51734 fi 51735 51736 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 51737 JVM_CFLAGS="$JVM_CFLAGS -DVM_LITTLE_ENDIAN" 51738 fi 51739 51740 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 51741 if test "x$OPENJDK_TARGET_OS" != xsolaris && test "x$OPENJDK_TARGET_OS" != xaix; then 51742 # Solaris does not have _LP64=1 in the old build. 51743 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 51744 JVM_CFLAGS="$JVM_CFLAGS -D_LP64=1" 51745 fi 51746 fi 51747 51748 # Set JVM_CFLAGS warning handling 51749 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51750 JVM_CFLAGS="$JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 51751 -Wunused-value -Woverloaded-virtual" 51752 51753 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51754 51755 51756 51757 51758 51759 51760 51761 51762 51763 51764 51765 51766 51767 51768 51769 51770 51771 51772 51773 51774 51775 51776 51777 51778 51779 51780 51781 51782 51783 51784 51785 51786 51787 51788 51789 51790 51791 51792 51793 51794 51795 51796 51797 51798 51799 51800 51801 51802 51803 51804 51805 51806 51807 51808 # Execute function body 51809 51810 # Need to assign to a variable since m4 is blocked from modifying parts in []. 51811 REFERENCE_VERSION=4.8 51812 51813 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 51814 as_fn_error $? "Internal error: Cannot compare to 4.8, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 51815 fi 51816 51817 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 51818 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 51819 fi 51820 51821 # Version comparison method inspired by http://stackoverflow.com/a/24067243 51822 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 51823 51824 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 51825 : 51826 51827 # These flags either do not work or give spurious warnings prior to gcc 4.8. 51828 JVM_CFLAGS="$JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 51829 51830 51831 else 51832 : 51833 51834 fi 51835 51836 51837 51838 51839 51840 51841 51842 51843 51844 51845 51846 51847 51848 51849 fi 51850 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 51851 # Non-zero builds have stricter warnings 51852 JVM_CFLAGS="$JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 51853 else 51854 if test "x$TOOLCHAIN_TYPE" = xclang; then 51855 # Some versions of llvm do not like -Wundef 51856 JVM_CFLAGS="$JVM_CFLAGS -Wno-undef" 51857 fi 51858 fi 51859 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 51860 JVM_CFLAGS="$JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 51861 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 51862 fi 51863 51864 # Additional macosx handling 51865 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51866 # MACOSX_VERSION_MIN is the c++ and ld is -mmacosx-version-min argument. The expected 51867 # format is X.Y.Z. It's hard-coded to the minimum OSX version on which the 51868 # JDK can be built and makes the linked binaries compatible even if built on 51869 # a newer version of the OS. 51870 MACOSX_VERSION_MIN=10.7.0 51871 51872 51873 # Setting --with-macosx-version-max=<version> makes it an error to build or 51874 # link to macosx APIs that are newer than the given OS version. The expected 51875 # format for <version> is either nn.n.n or nn.nn.nn. See /usr/include/AvailabilityMacros.h. 51876 51877 # Check whether --with-macosx-version-max was given. 51878 if test "${with_macosx_version_max+set}" = set; then : 51879 withval=$with_macosx_version_max; 51880 if echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9]\.[0-9]\$"; then 51881 MACOSX_VERSION_MAX=$with_macosx_version_max 51882 elif echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9][0-9]\.[0-9][0-9]\$"; then 51883 MACOSX_VERSION_MAX=$with_macosx_version_max 51884 elif test "x$with_macosx_version_max" = "xno"; then 51885 # Use build system default 51886 MACOSX_VERSION_MAX= 51887 else 51888 as_fn_error $? "osx version format must be nn.n.n or nn.nn.nn" "$LINENO" 5 51889 fi 51890 51891 else 51892 MACOSX_VERSION_MAX= 51893 51894 fi 51895 51896 51897 51898 # Let the flags variables get resolved in make for easier override on make 51899 # command line. AvailabilityMacros.h versions have no dots, ex: 1070. 51900 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 51901 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 51902 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51903 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51904 JVM_CFLAGS="$JVM_CFLAGS \ 51905 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 51906 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51907 51908 if test -n "$MACOSX_VERSION_MAX"; then 51909 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 51910 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 51911 JVM_CFLAGS="$JVM_CFLAGS \ 51912 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 51913 fi 51914 fi 51915 51916 # Setup some hard coded includes 51917 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 51918 -I\$(SUPPORT_OUTPUTDIR)/modules_include/java.base \ 51919 -I${TOPDIR}/src/java.base/share/native/include \ 51920 -I${TOPDIR}/src/java.base/$OPENJDK_TARGET_OS/native/include \ 51921 -I${TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/include \ 51922 -I${TOPDIR}/src/java.base/share/native/libjava \ 51923 -I${TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/libjava" 51924 51925 # The shared libraries are compiled using the picflag. 51926 CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 51927 $CFLAGS_JDK $EXTRA_CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 51928 CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 51929 $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 51930 51931 # Executable flags 51932 CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $EXTRA_CFLAGS_JDK" 51933 CXXFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK" 51934 51935 51936 51937 51938 51939 51940 # Setup LDFLAGS et al. 51941 # 51942 51943 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51944 LDFLAGS_MICROSOFT="-nologo -opt:ref" 51945 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 51946 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 51947 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 51948 LDFLAGS_SAFESH="-safeseh" 51949 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SAFESH" 51950 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SAFESH" 51951 # NOTE: Old build added -machine. Probably not needed. 51952 JVM_LDFLAGS="$JVM_LDFLAGS -machine:I386" 51953 else 51954 JVM_LDFLAGS="$JVM_LDFLAGS -machine:AMD64" 51955 fi 51956 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51957 JVM_LDFLAGS="$JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 51958 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51959 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 51960 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51961 fi 51962 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51963 # If this is a --hash-style=gnu system, use --hash-style=both, why? 51964 # We have previously set HAS_GNU_HASH if this is the case 51965 if test -n "$HAS_GNU_HASH"; then 51966 LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 51967 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_HASH_STYLE" 51968 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_HASH_STYLE" 51969 fi 51970 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51971 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51972 fi 51973 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51974 # And since we now know that the linker is gnu, then add -z defs, to forbid 51975 # undefined symbols in object files. 51976 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 51977 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 51978 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 51979 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 51980 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 51981 if test "x$OPENJDK_TARGET_CPU" = xx86; then 51982 JVM_LDFLAGS="$JVM_LDFLAGS -march=i586" 51983 fi 51984 case $DEBUG_LEVEL in 51985 release ) 51986 # tell linker to optimize libraries. 51987 # Should this be supplied to the OSS linker as well? 51988 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 51989 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 51990 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 51991 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51992 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 51993 fi 51994 ;; 51995 slowdebug ) 51996 # Hotspot always let the linker optimize 51997 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 51998 if test "x$HAS_LINKER_NOW" = "xtrue"; then 51999 # do relocations at load 52000 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_NOW_FLAG" 52001 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 52002 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_NOW_FLAG" 52003 fi 52004 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 52005 # mark relocations read only 52006 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 52007 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 52008 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 52009 fi 52010 ;; 52011 fastdebug ) 52012 # Hotspot always let the linker optimize 52013 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 52014 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 52015 # mark relocations read only 52016 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 52017 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 52018 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 52019 fi 52020 ;; 52021 * ) 52022 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 52023 ;; 52024 esac 52025 fi 52026 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52027 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 52028 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 52029 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 52030 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 52031 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 52032 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 52033 JVM_LDFLAGS="$JVM_LDFLAGS -xarch=sparc" 52034 fi 52035 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 52036 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 52037 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC" 52038 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_XLC" 52039 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 52040 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 52041 # so for slowdebug we build with '-qpic=large -bbigtoc'. 52042 if test "x$DEBUG_LEVEL" = xslowdebug; then 52043 JVM_LDFLAGS="$JVM_LDFLAGS -bbigtoc" 52044 fi 52045 fi 52046 52047 # Customize LDFLAGS for executables 52048 52049 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 52050 52051 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52052 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 52053 LDFLAGS_STACK_SIZE=1048576 52054 else 52055 LDFLAGS_STACK_SIZE=327680 52056 fi 52057 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 52058 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 52059 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 52060 fi 52061 52062 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} ${EXTRA_LDFLAGS_JDK}" 52063 52064 # Customize LDFLAGS for libs 52065 LDFLAGS_JDKLIB="${LDFLAGS_JDK}" 52066 52067 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 52068 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${LDFLAGS_NO_EXEC_STACK}" 52069 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52070 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 52071 -libpath:${OUTPUTDIR}/support/modules_libs/java.base" 52072 JDKLIB_LIBS="" 52073 else 52074 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 52075 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base" 52076 52077 if test "xTARGET" = "xTARGET"; then 52078 # On some platforms (mac) the linker warns about non existing -L dirs. 52079 # For any of the variants server, client or minimal, the dir matches the 52080 # variant name. The "main" variant should be used for linking. For the 52081 # rest, the dir is just server. 52082 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] \ 52083 || [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 52084 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 52085 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/$JVM_VARIANT_MAIN" 52086 else 52087 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 52088 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 52089 fi 52090 elif test "xTARGET" = "xBUILD"; then 52091 # When building a buildjdk, it's always only the server variant 52092 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 52093 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 52094 fi 52095 52096 JDKLIB_LIBS="-ljava -ljvm" 52097 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52098 JDKLIB_LIBS="$JDKLIB_LIBS -lc" 52099 fi 52100 52101 fi 52102 52103 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${JAVA_BASE_LDFLAGS}" 52104 52105 # Set JVM_LIBS (per os) 52106 if test "x$OPENJDK_TARGET_OS" = xlinux; then 52107 JVM_LIBS="$JVM_LIBS -lm -ldl -lpthread" 52108 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 52109 # FIXME: This hard-coded path is not really proper. 52110 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 52111 SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 52112 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 52113 SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 52114 fi 52115 JVM_LIBS="$JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 52116 -lthread -ldoor -lc -ldemangle -lnsl -lrt" 52117 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 52118 JVM_LIBS="$JVM_LIBS -lm" 52119 elif test "x$OPENJDK_TARGET_OS" = xaix; then 52120 JVM_LIBS="$JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 52121 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 52122 JVM_LIBS="$JVM_LIBS -lm" 52123 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 52124 JVM_LIBS="$JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 52125 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 52126 wsock32.lib winmm.lib version.lib psapi.lib" 52127 fi 52128 52129 # Set JVM_ASFLAGS 52130 if test "x$OPENJDK_TARGET_OS" = xlinux; then 52131 if test "x$OPENJDK_TARGET_CPU" = xx86; then 52132 JVM_ASFLAGS="$JVM_ASFLAGS -march=i586" 52133 fi 52134 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 52135 JVM_ASFLAGS="$JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 52136 fi 52137 52138 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${EXTRA_LDFLAGS_JDK}" 52139 52140 52141 52142 52143 52144 52145 52146 52147 52148 52149 52150 52151 52152 52153 52154 52155 # Special extras... 52156 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52157 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 52158 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 52159 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 52160 fi 52161 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 52162 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 52163 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 52164 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 52165 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 52166 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 52167 OPENJDK_BUILD_CXXSTD_CXXFLAG="-std=gnu++98" 52168 52169 52170 52171 52172 52173 52174 52175 52176 52177 52178 52179 52180 52181 52182 52183 52184 52185 52186 52187 52188 52189 52190 52191 52192 52193 52194 52195 52196 52197 52198 52199 52200 52201 52202 52203 52204 52205 52206 52207 52208 52209 52210 # Execute function body 52211 52212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"" >&5 52213 $as_echo_n "checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"... " >&6; } 52214 supports=yes 52215 52216 saved_cxxflags="$CXXFLAGS" 52217 CXXFLAGS="$CXXFLAG $OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror" 52218 ac_ext=cpp 52219 ac_cpp='$CXXCPP $CPPFLAGS' 52220 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52221 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52222 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52223 52224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52225 /* end confdefs.h. */ 52226 int i; 52227 _ACEOF 52228 if ac_fn_cxx_try_compile "$LINENO"; then : 52229 52230 else 52231 supports=no 52232 fi 52233 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52234 ac_ext=cpp 52235 ac_cpp='$CXXCPP $CPPFLAGS' 52236 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52237 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52238 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52239 52240 CXXFLAGS="$saved_cxxflags" 52241 52242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52243 $as_echo "$supports" >&6; } 52244 if test "x$supports" = "xyes" ; then 52245 : 52246 52247 else 52248 : 52249 OPENJDK_BUILD_CXXSTD_CXXFLAG="" 52250 fi 52251 52252 52253 52254 52255 52256 52257 52258 52259 52260 52261 52262 52263 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 52264 OPENJDK_BUILD_JVM_CFLAGS="${OPENJDK_BUILD_JVM_CFLAGS} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 52265 52266 fi 52267 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 52268 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 52269 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 52270 fi 52271 52272 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CFLAGS}" 52273 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CXXFLAGS}" 52274 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_LDFLAGS}" 52275 52276 ############################################################################### 52277 # 52278 # Now setup the CFLAGS and LDFLAGS for the JDK build. 52279 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 52280 # 52281 52282 # Setup compiler/platform specific flags into 52283 # OPENJDK_BUILD_CFLAGS_JDK - C Compiler flags 52284 # OPENJDK_BUILD_CXXFLAGS_JDK - C++ Compiler flags 52285 # OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK - common to C and C++ 52286 if test "x$TOOLCHAIN_TYPE" = xgcc; then 52287 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 52288 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 52289 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fcheck-new" 52290 if test "x$OPENJDK_BUILD_CPU" = xx86; then 52291 # Force compatibility with i586 on 32 bit intel platforms. 52292 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 52293 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 52294 fi 52295 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 52296 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 52297 case $OPENJDK_BUILD_CPU_ARCH in 52298 arm ) 52299 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 52300 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52301 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="${OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK} -fsigned-char" 52302 ;; 52303 ppc ) 52304 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 52305 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52306 ;; 52307 s390 ) 52308 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer -mbackchain -march=z10" 52309 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52310 ;; 52311 * ) 52312 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 52313 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52314 ;; 52315 esac 52316 52317 52318 52319 52320 52321 52322 52323 52324 52325 52326 52327 52328 52329 52330 52331 52332 52333 52334 52335 52336 52337 52338 52339 52340 52341 52342 52343 52344 52345 52346 52347 52348 52349 52350 52351 52352 52353 52354 52355 52356 52357 52358 52359 52360 52361 52362 52363 52364 52365 52366 52367 52368 52369 52370 # Execute function body 52371 52372 # Need to assign to a variable since m4 is blocked from modifying parts in []. 52373 REFERENCE_VERSION=6 52374 52375 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 52376 as_fn_error $? "Internal error: Cannot compare to 6, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 52377 fi 52378 52379 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 52380 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 52381 fi 52382 52383 # Version comparison method inspired by http://stackoverflow.com/a/24067243 52384 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 52385 52386 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 52387 : 52388 52389 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 52390 # runs afoul of the more aggressive versions of these optimisations. 52391 # Notably, value range propagation now assumes that the this pointer of C++ 52392 # member functions is non-null. 52393 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 52394 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 52395 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 52396 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 52397 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 52398 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 52399 52400 else 52401 : 52402 52403 fi 52404 52405 52406 52407 52408 52409 52410 52411 52412 52413 52414 52415 52416 52417 52418 elif test "x$TOOLCHAIN_TYPE" = xclang; then 52419 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 52420 52421 # Restrict the debug information created by Clang to avoid 52422 # too big object files and speed the build up a little bit 52423 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 52424 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -flimit-debug-info" 52425 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52426 if test "x$OPENJDK_BUILD_CPU" = xx86; then 52427 # Force compatibility with i586 on 32 bit intel platforms. 52428 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 52429 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 52430 fi 52431 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-sometimes-uninitialized" 52432 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 52433 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 52434 case $OPENJDK_BUILD_CPU_ARCH in 52435 ppc ) 52436 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 52437 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52438 ;; 52439 * ) 52440 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 52441 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52442 ;; 52443 esac 52444 fi 52445 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52446 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSPARC_WORKS" 52447 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 52448 if test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 52449 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_BUILD_CPU_LEGACY_LIB" 52450 fi 52451 52452 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 52453 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 52454 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 52455 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 52456 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 52457 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 52458 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52459 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52460 -MD -Zc:wchar_t- -W3 -wd4800 \ 52461 -DWIN32_LEAN_AND_MEAN \ 52462 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 52463 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 52464 -DWIN32 -DIAL" 52465 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 52466 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 52467 else 52468 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 52469 fi 52470 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 52471 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 52472 # studio. 52473 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 52474 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 52475 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 52476 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 52477 fi 52478 fi 52479 52480 ############################################################################### 52481 52482 # Adjust flags according to debug level. 52483 case $DEBUG_LEVEL in 52484 fastdebug | slowdebug ) 52485 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 52486 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 52487 ;; 52488 release ) 52489 ;; 52490 * ) 52491 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 52492 ;; 52493 esac 52494 52495 # Set some common defines. These works for all compilers, but assume 52496 # -D is universally accepted. 52497 52498 # Setup endianness 52499 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 52500 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 52501 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 52502 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 52503 # Note: -Dmacro is the same as #define macro 1 52504 # -Dmacro= is the same as #define macro 52505 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 52506 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 52507 else 52508 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 52509 fi 52510 else 52511 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 52512 # are defined in the system? 52513 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 52514 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 52515 else 52516 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 52517 fi 52518 fi 52519 52520 # Always enable optional macros for VM. 52521 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D__STDC_FORMAT_MACROS" 52522 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D__STDC_LIMIT_MACROS" 52523 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D__STDC_CONSTANT_MACROS" 52524 52525 # Setup target OS define. Use OS target name but in upper case. 52526 OPENJDK_BUILD_OS_UPPERCASE=`$ECHO $OPENJDK_BUILD_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 52527 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D$OPENJDK_BUILD_OS_UPPERCASE" 52528 52529 # Setup target CPU 52530 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52531 $OPENJDK_BUILD_ADD_LP64 \ 52532 -DARCH='\"$OPENJDK_BUILD_CPU_LEGACY\"' -D$OPENJDK_BUILD_CPU_LEGACY" 52533 52534 # Setup debug/release defines 52535 if test "x$DEBUG_LEVEL" = xrelease; then 52536 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DNDEBUG" 52537 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 52538 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRIMMED" 52539 fi 52540 else 52541 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DDEBUG" 52542 fi 52543 52544 # Optional POSIX functionality needed by the VM 52545 52546 if test "x$HAS_CLOCK_GETTIME" = "xtrue"; then 52547 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSUPPORTS_CLOCK_MONOTONIC" 52548 if test "x$CLOCK_GETTIME_IN_LIBRT" = "xtrue"; then 52549 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DNEEDS_LIBRT" 52550 fi 52551 fi 52552 52553 52554 # Set some additional per-OS defines. 52555 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52556 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DLINUX" 52557 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -pipe $PICFLAG -fno-rtti -fno-exceptions \ 52558 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 52559 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 52560 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSOLARIS" 52561 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -template=no%extdef -features=no%split_init \ 52562 -D_Crun_inline_placement -library=stlport4 $PICFLAG -mt -features=no%except" 52563 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 52564 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 52565 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_ALLBSD_SOURCE" 52566 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 52567 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 52568 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 52569 -fno-omit-frame-pointer" 52570 elif test "x$OPENJDK_BUILD_OS" = xaix; then 52571 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DAIX" 52572 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qtune=balanced \ 52573 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 52574 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 52575 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 52576 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 52577 # so for slowdebug we build with '-qpic=large -bbigtoc'. 52578 if test "x$DEBUG_LEVEL" = xslowdebug; then 52579 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qpic=large" 52580 fi 52581 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 52582 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 52583 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 52584 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 52585 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -nologo -W3 -MD -MP" 52586 fi 52587 52588 # Set some additional per-CPU defines. 52589 if test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xwindows-x86; then 52590 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -arch:IA32" 52591 elif test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xsolaris-sparcv9; then 52592 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -xarch=sparc" 52593 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 52594 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52595 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 52596 # fixes `relocation truncated to fit' error for gcc 4.1. 52597 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mminimal-toc" 52598 # Use ppc64 instructions, but schedule for power5 52599 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 52600 elif test "x$OPENJDK_BUILD_OS" = xaix; then 52601 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qarch=ppc64" 52602 fi 52603 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 52604 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52605 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 52606 # Little endian machine uses ELFv2 ABI. 52607 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DABI_ELFv2" 52608 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 52609 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=power8 -mtune=power8" 52610 fi 52611 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 52612 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52613 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mbackchain -march=z10" 52614 fi 52615 fi 52616 52617 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 52618 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DVM_LITTLE_ENDIAN" 52619 fi 52620 52621 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 52622 if test "x$OPENJDK_BUILD_OS" != xsolaris && test "x$OPENJDK_BUILD_OS" != xaix; then 52623 # Solaris does not have _LP64=1 in the old build. 52624 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 52625 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_LP64=1" 52626 fi 52627 fi 52628 52629 # Set OPENJDK_BUILD_JVM_CFLAGS warning handling 52630 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52631 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 52632 -Wunused-value -Woverloaded-virtual" 52633 52634 if test "x$TOOLCHAIN_TYPE" = xgcc; then 52635 52636 52637 52638 52639 52640 52641 52642 52643 52644 52645 52646 52647 52648 52649 52650 52651 52652 52653 52654 52655 52656 52657 52658 52659 52660 52661 52662 52663 52664 52665 52666 52667 52668 52669 52670 52671 52672 52673 52674 52675 52676 52677 52678 52679 52680 52681 52682 52683 52684 52685 52686 52687 52688 52689 # Execute function body 52690 52691 # Need to assign to a variable since m4 is blocked from modifying parts in []. 52692 REFERENCE_VERSION=4.8 52693 52694 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 52695 as_fn_error $? "Internal error: Cannot compare to 4.8, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 52696 fi 52697 52698 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 52699 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 52700 fi 52701 52702 # Version comparison method inspired by http://stackoverflow.com/a/24067243 52703 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 52704 52705 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 52706 : 52707 52708 # These flags either do not work or give spurious warnings prior to gcc 4.8. 52709 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 52710 52711 52712 else 52713 : 52714 52715 fi 52716 52717 52718 52719 52720 52721 52722 52723 52724 52725 52726 52727 52728 52729 52730 fi 52731 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 52732 # Non-zero builds have stricter warnings 52733 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 52734 else 52735 if test "x$TOOLCHAIN_TYPE" = xclang; then 52736 # Some versions of llvm do not like -Wundef 52737 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-undef" 52738 fi 52739 fi 52740 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 52741 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 52742 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 52743 fi 52744 52745 # Additional macosx handling 52746 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 52747 # MACOSX_VERSION_MIN is the c++ and ld is -mmacosx-version-min argument. The expected 52748 # format is X.Y.Z. It's hard-coded to the minimum OSX version on which the 52749 # JDK can be built and makes the linked binaries compatible even if built on 52750 # a newer version of the OS. 52751 MACOSX_VERSION_MIN=10.7.0 52752 52753 52754 # Setting --with-macosx-version-max=<version> makes it an error to build or 52755 # link to macosx APIs that are newer than the given OS version. The expected 52756 # format for <version> is either nn.n.n or nn.nn.nn. See /usr/include/AvailabilityMacros.h. 52757 52758 # Check whether --with-macosx-version-max was given. 52759 if test "${with_macosx_version_max+set}" = set; then : 52760 withval=$with_macosx_version_max; 52761 if echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9]\.[0-9]\$"; then 52762 MACOSX_VERSION_MAX=$with_macosx_version_max 52763 elif echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9][0-9]\.[0-9][0-9]\$"; then 52764 MACOSX_VERSION_MAX=$with_macosx_version_max 52765 elif test "x$with_macosx_version_max" = "xno"; then 52766 # Use build system default 52767 MACOSX_VERSION_MAX= 52768 else 52769 as_fn_error $? "osx version format must be nn.n.n or nn.nn.nn" "$LINENO" 5 52770 fi 52771 52772 else 52773 MACOSX_VERSION_MAX= 52774 52775 fi 52776 52777 52778 52779 # Let the flags variables get resolved in make for easier override on make 52780 # command line. AvailabilityMacros.h versions have no dots, ex: 1070. 52781 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52782 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 52783 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 52784 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 52785 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS \ 52786 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 52787 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 52788 52789 if test -n "$MACOSX_VERSION_MAX"; then 52790 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52791 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 52792 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS \ 52793 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 52794 fi 52795 fi 52796 52797 # Setup some hard coded includes 52798 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52799 -I\$(SUPPORT_OUTPUTDIR)/modules_include/java.base \ 52800 -I${TOPDIR}/src/java.base/share/native/include \ 52801 -I${TOPDIR}/src/java.base/$OPENJDK_BUILD_OS/native/include \ 52802 -I${TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/include \ 52803 -I${TOPDIR}/src/java.base/share/native/libjava \ 52804 -I${TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/libjava" 52805 52806 # The shared libraries are compiled using the picflag. 52807 OPENJDK_BUILD_CFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52808 $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA" 52809 OPENJDK_BUILD_CXXFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52810 $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA" 52811 52812 # Executable flags 52813 OPENJDK_BUILD_CFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK" 52814 OPENJDK_BUILD_CXXFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK" 52815 52816 52817 52818 52819 52820 52821 # Setup LDFLAGS et al. 52822 # 52823 52824 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52825 LDFLAGS_MICROSOFT="-nologo -opt:ref" 52826 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 52827 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 52828 if test "x$OPENJDK_BUILD_CPU_BITS" = "x32"; then 52829 LDFLAGS_SAFESH="-safeseh" 52830 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SAFESH" 52831 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SAFESH" 52832 # NOTE: Old build added -machine. Probably not needed. 52833 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:I386" 52834 else 52835 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:AMD64" 52836 fi 52837 elif test "x$TOOLCHAIN_TYPE" = xclang; then 52838 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 52839 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 52840 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 52841 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 52842 fi 52843 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 52844 # If this is a --hash-style=gnu system, use --hash-style=both, why? 52845 # We have previously set HAS_GNU_HASH if this is the case 52846 if test -n "$HAS_GNU_HASH"; then 52847 OPENJDK_BUILD_LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 52848 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 52849 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 52850 fi 52851 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 52852 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 52853 fi 52854 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52855 # And since we now know that the linker is gnu, then add -z defs, to forbid 52856 # undefined symbols in object files. 52857 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 52858 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 52859 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 52860 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 52861 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 52862 if test "x$OPENJDK_BUILD_CPU" = xx86; then 52863 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -march=i586" 52864 fi 52865 case $DEBUG_LEVEL in 52866 release ) 52867 # tell linker to optimize libraries. 52868 # Should this be supplied to the OSS linker as well? 52869 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 52870 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 52871 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 52872 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 52873 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 52874 fi 52875 ;; 52876 slowdebug ) 52877 # Hotspot always let the linker optimize 52878 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 52879 if test "x$HAS_LINKER_NOW" = "xtrue"; then 52880 # do relocations at load 52881 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_NOW_FLAG" 52882 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 52883 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_NOW_FLAG" 52884 fi 52885 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 52886 # mark relocations read only 52887 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 52888 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 52889 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 52890 fi 52891 ;; 52892 fastdebug ) 52893 # Hotspot always let the linker optimize 52894 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 52895 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 52896 # mark relocations read only 52897 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 52898 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 52899 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 52900 fi 52901 ;; 52902 * ) 52903 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 52904 ;; 52905 esac 52906 fi 52907 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52908 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 52909 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 52910 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 52911 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 52912 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 52913 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 52914 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -xarch=sparc" 52915 fi 52916 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 52917 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 52918 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_XLC" 52919 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_XLC" 52920 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 52921 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 52922 # so for slowdebug we build with '-qpic=large -bbigtoc'. 52923 if test "x$DEBUG_LEVEL" = xslowdebug; then 52924 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -bbigtoc" 52925 fi 52926 fi 52927 52928 # Customize LDFLAGS for executables 52929 52930 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDK}" 52931 52932 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52933 if test "x$OPENJDK_BUILD_CPU_BITS" = "x64"; then 52934 LDFLAGS_STACK_SIZE=1048576 52935 else 52936 LDFLAGS_STACK_SIZE=327680 52937 fi 52938 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 52939 elif test "x$OPENJDK_BUILD_OS" = xlinux; then 52940 OPENJDK_BUILD_LDFLAGS_JDKEXE="$OPENJDK_BUILD_LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 52941 fi 52942 52943 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 52944 52945 # Customize LDFLAGS for libs 52946 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDK}" 52947 52948 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 52949 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${LDFLAGS_NO_EXEC_STACK}" 52950 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52951 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 52952 -libpath:${OUTPUTDIR}/support/modules_libs/java.base" 52953 OPENJDK_BUILD_JDKLIB_LIBS="" 52954 else 52955 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 52956 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base" 52957 52958 if test "xBUILD" = "xTARGET"; then 52959 # On some platforms (mac) the linker warns about non existing -L dirs. 52960 # For any of the variants server, client or minimal, the dir matches the 52961 # variant name. The "main" variant should be used for linking. For the 52962 # rest, the dir is just server. 52963 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] \ 52964 || [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 52965 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 52966 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/$JVM_VARIANT_MAIN" 52967 else 52968 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 52969 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 52970 fi 52971 elif test "xBUILD" = "xBUILD"; then 52972 # When building a buildjdk, it's always only the server variant 52973 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 52974 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 52975 fi 52976 52977 OPENJDK_BUILD_JDKLIB_LIBS="-ljava -ljvm" 52978 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52979 OPENJDK_BUILD_JDKLIB_LIBS="$OPENJDK_BUILD_JDKLIB_LIBS -lc" 52980 fi 52981 52982 fi 52983 52984 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_JAVA_BASE_LDFLAGS}" 52985 52986 # Set OPENJDK_BUILD_JVM_LIBS (per os) 52987 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52988 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm -ldl -lpthread" 52989 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 52990 # FIXME: This hard-coded path is not really proper. 52991 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 52992 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 52993 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 52994 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 52995 fi 52996 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 52997 -lthread -ldoor -lc -ldemangle -lnsl -lrt" 52998 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 52999 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 53000 elif test "x$OPENJDK_BUILD_OS" = xaix; then 53001 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 53002 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 53003 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 53004 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 53005 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 53006 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 53007 wsock32.lib winmm.lib version.lib psapi.lib" 53008 fi 53009 53010 # Set OPENJDK_BUILD_JVM_ASFLAGS 53011 if test "x$OPENJDK_BUILD_OS" = xlinux; then 53012 if test "x$OPENJDK_BUILD_CPU" = xx86; then 53013 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -march=i586" 53014 fi 53015 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 53016 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 53017 fi 53018 53019 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 53020 53021 53022 53023 53024 53025 53026 53027 53028 53029 53030 53031 53032 53033 53034 53035 53036 # Tests are only ever compiled for TARGET 53037 # Flags for compiling test libraries 53038 CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 53039 CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 53040 53041 # Flags for compiling test executables 53042 CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK" 53043 CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK" 53044 53045 53046 53047 53048 53049 53050 LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB" 53051 LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE $JAVA_BASE_LDFLAGS" 53052 53053 53054 53055 53056 53057 53058 # Check that the compiler supports -mX (or -qX on AIX) flags 53059 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 53060 53061 53062 53063 53064 53065 53066 53067 53068 53069 53070 53071 53072 53073 53074 53075 53076 53077 53078 53079 53080 53081 53082 53083 53084 53085 53086 53087 53088 53089 53090 53091 53092 53093 53094 53095 53096 53097 53098 53099 53100 53101 53102 53103 53104 53105 53106 53107 # Execute function body 53108 53109 53110 53111 53112 53113 53114 53115 53116 53117 53118 53119 53120 53121 53122 53123 53124 53125 53126 53127 53128 53129 53130 53131 53132 53133 53134 53135 53136 53137 53138 53139 53140 53141 53142 53143 53144 53145 53146 53147 53148 53149 53150 53151 53152 53153 53154 53155 53156 # Execute function body 53157 53158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 53159 $as_echo_n "checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 53160 supports=yes 53161 53162 saved_cflags="$CFLAGS" 53163 CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 53164 ac_ext=c 53165 ac_cpp='$CPP $CPPFLAGS' 53166 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53167 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53168 ac_compiler_gnu=$ac_cv_c_compiler_gnu 53169 53170 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53171 /* end confdefs.h. */ 53172 int i; 53173 _ACEOF 53174 if ac_fn_c_try_compile "$LINENO"; then : 53175 53176 else 53177 supports=no 53178 fi 53179 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53180 ac_ext=cpp 53181 ac_cpp='$CXXCPP $CPPFLAGS' 53182 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53183 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53184 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53185 53186 CFLAGS="$saved_cflags" 53187 53188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53189 $as_echo "$supports" >&6; } 53190 if test "x$supports" = "xyes" ; then 53191 : 53192 C_COMP_SUPPORTS="yes" 53193 else 53194 : 53195 C_COMP_SUPPORTS="no" 53196 fi 53197 53198 53199 53200 53201 53202 53203 53204 53205 53206 53207 53208 53209 53210 53211 53212 53213 53214 53215 53216 53217 53218 53219 53220 53221 53222 53223 53224 53225 53226 53227 53228 53229 53230 53231 53232 53233 53234 53235 53236 53237 53238 53239 53240 53241 53242 53243 53244 53245 53246 53247 53248 53249 53250 53251 53252 53253 53254 53255 53256 # Execute function body 53257 53258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 53259 $as_echo_n "checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 53260 supports=yes 53261 53262 saved_cxxflags="$CXXFLAGS" 53263 CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 53264 ac_ext=cpp 53265 ac_cpp='$CXXCPP $CPPFLAGS' 53266 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53267 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53268 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53269 53270 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53271 /* end confdefs.h. */ 53272 int i; 53273 _ACEOF 53274 if ac_fn_cxx_try_compile "$LINENO"; then : 53275 53276 else 53277 supports=no 53278 fi 53279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53280 ac_ext=cpp 53281 ac_cpp='$CXXCPP $CPPFLAGS' 53282 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53283 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53284 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53285 53286 CXXFLAGS="$saved_cxxflags" 53287 53288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53289 $as_echo "$supports" >&6; } 53290 if test "x$supports" = "xyes" ; then 53291 : 53292 CXX_COMP_SUPPORTS="yes" 53293 else 53294 : 53295 CXX_COMP_SUPPORTS="no" 53296 fi 53297 53298 53299 53300 53301 53302 53303 53304 53305 53306 53307 53308 53309 53310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 53311 $as_echo_n "checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 53312 supports=no 53313 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 53314 53315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53316 $as_echo "$supports" >&6; } 53317 if test "x$supports" = "xyes" ; then 53318 : 53319 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 53320 else 53321 : 53322 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 53323 fi 53324 53325 53326 53327 53328 53329 53330 53331 53332 # Check whether --enable-warnings-as-errors was given. 53333 if test "${enable_warnings_as_errors+set}" = set; then : 53334 enableval=$enable_warnings_as_errors; 53335 fi 53336 53337 53338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native warnings are errors" >&5 53339 $as_echo_n "checking if native warnings are errors... " >&6; } 53340 if test "x$enable_warnings_as_errors" = "xyes"; then 53341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (explicitly set)" >&5 53342 $as_echo "yes (explicitly set)" >&6; } 53343 WARNINGS_AS_ERRORS=true 53344 elif test "x$enable_warnings_as_errors" = "xno"; then 53345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53346 $as_echo "no" >&6; } 53347 WARNINGS_AS_ERRORS=false 53348 elif test "x$enable_warnings_as_errors" = "x"; then 53349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 53350 $as_echo "yes (default)" >&6; } 53351 WARNINGS_AS_ERRORS=true 53352 else 53353 as_fn_error $? "--enable-warnings-as-errors accepts no argument" "$LINENO" 5 53354 fi 53355 53356 53357 53358 case "${TOOLCHAIN_TYPE}" in 53359 microsoft) 53360 DISABLE_WARNING_PREFIX="-wd" 53361 CFLAGS_WARNINGS_ARE_ERRORS="-WX" 53362 ;; 53363 solstudio) 53364 DISABLE_WARNING_PREFIX="-erroff=" 53365 CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all" 53366 ;; 53367 gcc) 53368 # Prior to gcc 4.4, a -Wno-X where X is unknown for that version of gcc will cause an error 53369 53370 53371 53372 53373 53374 53375 53376 53377 53378 53379 53380 53381 53382 53383 53384 53385 53386 53387 53388 53389 53390 53391 53392 53393 53394 53395 53396 53397 53398 53399 53400 53401 53402 53403 53404 53405 53406 53407 53408 53409 53410 53411 53412 53413 53414 53415 53416 # Execute function body 53417 53418 53419 53420 53421 53422 53423 53424 53425 53426 53427 53428 53429 53430 53431 53432 53433 53434 53435 53436 53437 53438 53439 53440 53441 53442 53443 53444 53445 53446 53447 53448 53449 53450 53451 53452 53453 53454 53455 53456 53457 53458 53459 53460 53461 53462 53463 53464 53465 # Execute function body 53466 53467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53468 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53469 supports=yes 53470 53471 saved_cflags="$CFLAGS" 53472 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 53473 ac_ext=c 53474 ac_cpp='$CPP $CPPFLAGS' 53475 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53476 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53477 ac_compiler_gnu=$ac_cv_c_compiler_gnu 53478 53479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53480 /* end confdefs.h. */ 53481 int i; 53482 _ACEOF 53483 if ac_fn_c_try_compile "$LINENO"; then : 53484 53485 else 53486 supports=no 53487 fi 53488 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53489 ac_ext=cpp 53490 ac_cpp='$CXXCPP $CPPFLAGS' 53491 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53492 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53493 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53494 53495 CFLAGS="$saved_cflags" 53496 53497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53498 $as_echo "$supports" >&6; } 53499 if test "x$supports" = "xyes" ; then 53500 : 53501 C_COMP_SUPPORTS="yes" 53502 else 53503 : 53504 C_COMP_SUPPORTS="no" 53505 fi 53506 53507 53508 53509 53510 53511 53512 53513 53514 53515 53516 53517 53518 53519 53520 53521 53522 53523 53524 53525 53526 53527 53528 53529 53530 53531 53532 53533 53534 53535 53536 53537 53538 53539 53540 53541 53542 53543 53544 53545 53546 53547 53548 53549 53550 53551 53552 53553 53554 53555 53556 53557 53558 53559 53560 53561 53562 53563 53564 53565 # Execute function body 53566 53567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53568 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53569 supports=yes 53570 53571 saved_cxxflags="$CXXFLAGS" 53572 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 53573 ac_ext=cpp 53574 ac_cpp='$CXXCPP $CPPFLAGS' 53575 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53576 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53577 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53578 53579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53580 /* end confdefs.h. */ 53581 int i; 53582 _ACEOF 53583 if ac_fn_cxx_try_compile "$LINENO"; then : 53584 53585 else 53586 supports=no 53587 fi 53588 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53589 ac_ext=cpp 53590 ac_cpp='$CXXCPP $CPPFLAGS' 53591 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53592 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53593 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53594 53595 CXXFLAGS="$saved_cxxflags" 53596 53597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53598 $as_echo "$supports" >&6; } 53599 if test "x$supports" = "xyes" ; then 53600 : 53601 CXX_COMP_SUPPORTS="yes" 53602 else 53603 : 53604 CXX_COMP_SUPPORTS="no" 53605 fi 53606 53607 53608 53609 53610 53611 53612 53613 53614 53615 53616 53617 53618 53619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53620 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53621 supports=no 53622 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 53623 53624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53625 $as_echo "$supports" >&6; } 53626 if test "x$supports" = "xyes" ; then 53627 : 53628 GCC_CAN_DISABLE_WARNINGS=true 53629 else 53630 : 53631 GCC_CAN_DISABLE_WARNINGS=false 53632 53633 fi 53634 53635 53636 53637 53638 53639 53640 if test "x$GCC_CAN_DISABLE_WARNINGS" = "xtrue"; then 53641 DISABLE_WARNING_PREFIX="-Wno-" 53642 else 53643 DISABLE_WARNING_PREFIX= 53644 fi 53645 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 53646 # Repeate the check for the BUILD_CC and BUILD_CXX. Need to also reset 53647 # CFLAGS since any target specific flags will likely not work with the 53648 # build compiler 53649 CC_OLD="$CC" 53650 CXX_OLD="$CXX" 53651 CC="$BUILD_CC" 53652 CXX="$BUILD_CXX" 53653 CFLAGS_OLD="$CFLAGS" 53654 CFLAGS="" 53655 53656 53657 53658 53659 53660 53661 53662 53663 53664 53665 53666 53667 53668 53669 53670 53671 53672 53673 53674 53675 53676 53677 53678 53679 53680 53681 53682 53683 53684 53685 53686 53687 53688 53689 53690 53691 53692 53693 53694 53695 53696 53697 53698 53699 53700 53701 53702 # Execute function body 53703 53704 53705 53706 53707 53708 53709 53710 53711 53712 53713 53714 53715 53716 53717 53718 53719 53720 53721 53722 53723 53724 53725 53726 53727 53728 53729 53730 53731 53732 53733 53734 53735 53736 53737 53738 53739 53740 53741 53742 53743 53744 53745 53746 53747 53748 53749 53750 53751 # Execute function body 53752 53753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53754 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53755 supports=yes 53756 53757 saved_cflags="$CFLAGS" 53758 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 53759 ac_ext=c 53760 ac_cpp='$CPP $CPPFLAGS' 53761 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53762 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53763 ac_compiler_gnu=$ac_cv_c_compiler_gnu 53764 53765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53766 /* end confdefs.h. */ 53767 int i; 53768 _ACEOF 53769 if ac_fn_c_try_compile "$LINENO"; then : 53770 53771 else 53772 supports=no 53773 fi 53774 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53775 ac_ext=cpp 53776 ac_cpp='$CXXCPP $CPPFLAGS' 53777 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53778 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53779 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53780 53781 CFLAGS="$saved_cflags" 53782 53783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53784 $as_echo "$supports" >&6; } 53785 if test "x$supports" = "xyes" ; then 53786 : 53787 C_COMP_SUPPORTS="yes" 53788 else 53789 : 53790 C_COMP_SUPPORTS="no" 53791 fi 53792 53793 53794 53795 53796 53797 53798 53799 53800 53801 53802 53803 53804 53805 53806 53807 53808 53809 53810 53811 53812 53813 53814 53815 53816 53817 53818 53819 53820 53821 53822 53823 53824 53825 53826 53827 53828 53829 53830 53831 53832 53833 53834 53835 53836 53837 53838 53839 53840 53841 53842 53843 53844 53845 53846 53847 53848 53849 53850 53851 # Execute function body 53852 53853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53854 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53855 supports=yes 53856 53857 saved_cxxflags="$CXXFLAGS" 53858 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 53859 ac_ext=cpp 53860 ac_cpp='$CXXCPP $CPPFLAGS' 53861 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53862 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53863 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53864 53865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53866 /* end confdefs.h. */ 53867 int i; 53868 _ACEOF 53869 if ac_fn_cxx_try_compile "$LINENO"; then : 53870 53871 else 53872 supports=no 53873 fi 53874 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53875 ac_ext=cpp 53876 ac_cpp='$CXXCPP $CPPFLAGS' 53877 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53878 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53879 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53880 53881 CXXFLAGS="$saved_cxxflags" 53882 53883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53884 $as_echo "$supports" >&6; } 53885 if test "x$supports" = "xyes" ; then 53886 : 53887 CXX_COMP_SUPPORTS="yes" 53888 else 53889 : 53890 CXX_COMP_SUPPORTS="no" 53891 fi 53892 53893 53894 53895 53896 53897 53898 53899 53900 53901 53902 53903 53904 53905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53906 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53907 supports=no 53908 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 53909 53910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53911 $as_echo "$supports" >&6; } 53912 if test "x$supports" = "xyes" ; then 53913 : 53914 BUILD_CC_CAN_DISABLE_WARNINGS=true 53915 else 53916 : 53917 BUILD_CC_CAN_DISABLE_WARNINGS=false 53918 53919 fi 53920 53921 53922 53923 53924 53925 53926 if test "x$BUILD_CC_CAN_DISABLE_WARNINGS" = "xtrue"; then 53927 BUILD_CC_DISABLE_WARNING_PREFIX="-Wno-" 53928 else 53929 BUILD_CC_DISABLE_WARNING_PREFIX= 53930 fi 53931 CC="$CC_OLD" 53932 CXX="$CXX_OLD" 53933 CFLAGS="$CFLAGS_OLD" 53934 ;; 53935 clang) 53936 DISABLE_WARNING_PREFIX="-Wno-" 53937 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 53938 ;; 53939 xlc) 53940 DISABLE_WARNING_PREFIX="-qsuppress=" 53941 CFLAGS_WARNINGS_ARE_ERRORS="-qhalt=w" 53942 ;; 53943 esac 53944 53945 53946 53947 53948 53949 # Setup debug symbols (need objcopy from the toolchain for that) 53950 53951 # 53952 # NATIVE_DEBUG_SYMBOLS 53953 # This must be done after the toolchain is setup, since we're looking at objcopy. 53954 # 53955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of native debug symbols to use" >&5 53956 $as_echo_n "checking what type of native debug symbols to use... " >&6; } 53957 53958 # Check whether --with-native-debug-symbols was given. 53959 if test "${with_native_debug_symbols+set}" = set; then : 53960 withval=$with_native_debug_symbols; 53961 if test "x$OPENJDK_TARGET_OS" = xaix; then 53962 if test "x$withval" = xexternal || test "x$withval" = xzipped; then 53963 as_fn_error $? "AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols" "$LINENO" 5 53964 fi 53965 fi 53966 53967 else 53968 53969 if test "x$OPENJDK_TARGET_OS" = xaix; then 53970 # AIX doesn't support 'zipped' so use 'internal' as default 53971 with_native_debug_symbols="internal" 53972 else 53973 if test "x$STATIC_BUILD" = xtrue; then 53974 with_native_debug_symbols="none" 53975 else 53976 with_native_debug_symbols="zipped" 53977 fi 53978 fi 53979 53980 fi 53981 53982 NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols 53983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE_DEBUG_SYMBOLS" >&5 53984 $as_echo "$NATIVE_DEBUG_SYMBOLS" >&6; } 53985 53986 if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then 53987 53988 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 53989 if test "x$OBJCOPY" = x; then 53990 # enabling of enable-debug-symbols and can't find objcopy 53991 # this is an error 53992 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 53993 fi 53994 fi 53995 53996 COMPILE_WITH_DEBUG_SYMBOLS=true 53997 COPY_DEBUG_SYMBOLS=true 53998 ZIP_EXTERNAL_DEBUG_SYMBOLS=true 53999 elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then 54000 COMPILE_WITH_DEBUG_SYMBOLS=false 54001 COPY_DEBUG_SYMBOLS=false 54002 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 54003 elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then 54004 COMPILE_WITH_DEBUG_SYMBOLS=true 54005 COPY_DEBUG_SYMBOLS=false 54006 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 54007 elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then 54008 54009 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 54010 if test "x$OBJCOPY" = x; then 54011 # enabling of enable-debug-symbols and can't find objcopy 54012 # this is an error 54013 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 54014 fi 54015 fi 54016 54017 COMPILE_WITH_DEBUG_SYMBOLS=true 54018 COPY_DEBUG_SYMBOLS=true 54019 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 54020 else 54021 as_fn_error $? "Allowed native debug symbols are: none, internal, external, zipped" "$LINENO" 5 54022 fi 54023 54024 # --enable-debug-symbols is deprecated. 54025 # Please use --with-native-debug-symbols=[internal,external,zipped] . 54026 54027 # Check whether --enable-debug-symbols was given. 54028 if test "${enable_debug_symbols+set}" = set; then : 54029 enableval=$enable_debug_symbols; 54030 fi 54031 54032 if test "x$enable_debug_symbols" != x; then 54033 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&5 54034 $as_echo "$as_me: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&2;} 54035 54036 if test "xPlease use --with-native-debug-symbols=[internal,external,zipped] ." != x; then 54037 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&5 54038 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&2;} 54039 fi 54040 54041 fi 54042 54043 54044 # --enable-zip-debug-info is deprecated. 54045 # Please use --with-native-debug-symbols=zipped . 54046 54047 # Check whether --enable-zip-debug-info was given. 54048 if test "${enable_zip_debug_info+set}" = set; then : 54049 enableval=$enable_zip_debug_info; 54050 fi 54051 54052 if test "x$enable_zip_debug_info" != x; then 54053 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&5 54054 $as_echo "$as_me: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&2;} 54055 54056 if test "xPlease use --with-native-debug-symbols=zipped ." != x; then 54057 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=zipped ." >&5 54058 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=zipped ." >&2;} 54059 fi 54060 54061 fi 54062 54063 54064 54065 54066 54067 54068 54069 # Check whether --enable-native-coverage was given. 54070 if test "${enable_native_coverage+set}" = set; then : 54071 enableval=$enable_native_coverage; 54072 fi 54073 54074 GCOV_ENABLED="false" 54075 if test "x$enable_native_coverage" = "xyes"; then 54076 if test "x$TOOLCHAIN_TYPE" = "xgcc"; then 54077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 54078 $as_echo_n "checking if native coverage is enabled... " >&6; } 54079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 54080 $as_echo "yes" >&6; } 54081 GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline" 54082 GCOV_LDFLAGS="-fprofile-arcs" 54083 JVM_CFLAGS="$JVM_CFLAGS $GCOV_CFLAGS" 54084 JVM_LDFLAGS="$JVM_LDFLAGS $GCOV_LDFLAGS" 54085 CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS" 54086 CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS" 54087 CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS" 54088 CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS" 54089 LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS" 54090 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS" 54091 GCOV_ENABLED="true" 54092 else 54093 as_fn_error $? "--enable-native-coverage only works with toolchain type gcc" "$LINENO" 5 54094 fi 54095 elif test "x$enable_native_coverage" = "xno"; then 54096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 54097 $as_echo_n "checking if native coverage is enabled... " >&6; } 54098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54099 $as_echo "no" >&6; } 54100 elif test "x$enable_native_coverage" != "x"; then 54101 as_fn_error $? "--enable-native-coverage can only be assigned \"yes\" or \"no\"" "$LINENO" 5 54102 fi 54103 54104 54105 54106 54107 # Need toolchain to setup dtrace 54108 54109 # Test for dtrace dependencies 54110 # Check whether --enable-dtrace was given. 54111 if test "${enable_dtrace+set}" = set; then : 54112 enableval=$enable_dtrace; 54113 fi 54114 54115 54116 DTRACE_DEP_MISSING=false 54117 54118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dtrace tool" >&5 54119 $as_echo_n "checking for dtrace tool... " >&6; } 54120 if test "x$DTRACE" != "x" && test -x "$DTRACE"; then 54121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 54122 $as_echo "$DTRACE" >&6; } 54123 else 54124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found, cannot build dtrace" >&5 54125 $as_echo "not found, cannot build dtrace" >&6; } 54126 DTRACE_DEP_MISSING=true 54127 fi 54128 54129 for ac_header in sys/sdt.h 54130 do : 54131 ac_fn_cxx_check_header_mongrel "$LINENO" "sys/sdt.h" "ac_cv_header_sys_sdt_h" "$ac_includes_default" 54132 if test "x$ac_cv_header_sys_sdt_h" = xyes; then : 54133 cat >>confdefs.h <<_ACEOF 54134 #define HAVE_SYS_SDT_H 1 54135 _ACEOF 54136 DTRACE_HEADERS_OK=yes 54137 else 54138 DTRACE_HEADERS_OK=no 54139 fi 54140 54141 done 54142 54143 if test "x$DTRACE_HEADERS_OK" != "xyes"; then 54144 DTRACE_DEP_MISSING=true 54145 fi 54146 54147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dtrace should be built" >&5 54148 $as_echo_n "checking if dtrace should be built... " >&6; } 54149 if test "x$enable_dtrace" = "xyes"; then 54150 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 54151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 54152 $as_echo "no, missing dependencies" >&6; } 54153 54154 # Print a helpful message on how to acquire the necessary build dependency. 54155 # dtrace is the help tag: freetype, cups, alsa etc 54156 MISSING_DEPENDENCY=dtrace 54157 54158 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54159 cygwin_help $MISSING_DEPENDENCY 54160 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54161 msys_help $MISSING_DEPENDENCY 54162 else 54163 PKGHANDLER_COMMAND= 54164 54165 case $PKGHANDLER in 54166 apt-get) 54167 apt_help $MISSING_DEPENDENCY ;; 54168 yum) 54169 yum_help $MISSING_DEPENDENCY ;; 54170 brew) 54171 brew_help $MISSING_DEPENDENCY ;; 54172 port) 54173 port_help $MISSING_DEPENDENCY ;; 54174 pkgutil) 54175 pkgutil_help $MISSING_DEPENDENCY ;; 54176 pkgadd) 54177 pkgadd_help $MISSING_DEPENDENCY ;; 54178 esac 54179 54180 if test "x$PKGHANDLER_COMMAND" != x; then 54181 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 54182 fi 54183 fi 54184 54185 as_fn_error $? "Cannot enable dtrace with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 54186 else 54187 INCLUDE_DTRACE=true 54188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 54189 $as_echo "yes, forced" >&6; } 54190 fi 54191 elif test "x$enable_dtrace" = "xno"; then 54192 INCLUDE_DTRACE=false 54193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 54194 $as_echo "no, forced" >&6; } 54195 elif test "x$enable_dtrace" = "xauto" || test "x$enable_dtrace" = "x"; then 54196 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 54197 INCLUDE_DTRACE=false 54198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 54199 $as_echo "no, missing dependencies" >&6; } 54200 else 54201 INCLUDE_DTRACE=true 54202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 54203 $as_echo "yes, dependencies present" >&6; } 54204 fi 54205 else 54206 as_fn_error $? "Invalid value for --enable-dtrace: $enable_dtrace" "$LINENO" 5 54207 fi 54208 54209 54210 # Check whether --enable-aot was given. 54211 if test "${enable_aot+set}" = set; then : 54212 enableval=$enable_aot; 54213 fi 54214 54215 54216 if test "x$enable_aot" = "x" || test "x$enable_aot" = "xauto"; then 54217 ENABLE_AOT="true" 54218 elif test "x$enable_aot" = "xyes"; then 54219 ENABLE_AOT="true" 54220 elif test "x$enable_aot" = "xno"; then 54221 ENABLE_AOT="false" 54222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aot should be enabled" >&5 54223 $as_echo_n "checking if aot should be enabled... " >&6; } 54224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 54225 $as_echo "no, forced" >&6; } 54226 else 54227 as_fn_error $? "Invalid value for --enable-aot: $enable_aot" "$LINENO" 5 54228 fi 54229 54230 if test "x$ENABLE_AOT" = "xtrue"; then 54231 # Only enable AOT on X64 platforms. 54232 if test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 54233 if test -e "${TOPDIR}/src/jdk.aot"; then 54234 if test -e "${TOPDIR}/src/jdk.internal.vm.compiler"; then 54235 ENABLE_AOT="true" 54236 else 54237 ENABLE_AOT="false" 54238 if test "x$enable_aot" = "xyes"; then 54239 as_fn_error $? "Cannot build AOT without src/jdk.internal.vm.compiler sources. Remove --enable-aot." "$LINENO" 5 54240 fi 54241 fi 54242 else 54243 ENABLE_AOT="false" 54244 if test "x$enable_aot" = "xyes"; then 54245 as_fn_error $? "Cannot build AOT without src/jdk.aot sources. Remove --enable-aot." "$LINENO" 5 54246 fi 54247 fi 54248 else 54249 ENABLE_AOT="false" 54250 if test "x$enable_aot" = "xyes"; then 54251 as_fn_error $? "AOT is currently only supported on x86_64. Remove --enable-aot." "$LINENO" 5 54252 fi 54253 fi 54254 fi 54255 54256 54257 54258 54259 # Check whether --enable-cds was given. 54260 if test "${enable_cds+set}" = set; then : 54261 enableval=$enable_cds; 54262 fi 54263 54264 54265 if test "x$enable_cds" = "x" || test "x$enable_cds" = "xyes"; then 54266 ENABLE_CDS="true" 54267 elif test "x$enable_cds" = "xno"; then 54268 ENABLE_CDS="false" 54269 else 54270 as_fn_error $? "Invalid value for --enable-cds: $enable_cds" "$LINENO" 5 54271 fi 54272 54273 54274 54275 54276 # Check whether --enable-hotspot-gtest was given. 54277 if test "${enable_hotspot_gtest+set}" = set; then : 54278 enableval=$enable_hotspot_gtest; 54279 fi 54280 54281 54282 if test -e "${TOPDIR}/test/hotspot/gtest"; then 54283 GTEST_DIR_EXISTS="true" 54284 else 54285 GTEST_DIR_EXISTS="false" 54286 fi 54287 54288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Hotspot gtest unit tests should be built" >&5 54289 $as_echo_n "checking if Hotspot gtest unit tests should be built... " >&6; } 54290 if test "x$enable_hotspot_gtest" = "xyes"; then 54291 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 54292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 54293 $as_echo "yes, forced" >&6; } 54294 BUILD_GTEST="true" 54295 else 54296 as_fn_error $? "Cannot build gtest without the test source" "$LINENO" 5 54297 fi 54298 elif test "x$enable_hotspot_gtest" = "xno"; then 54299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 54300 $as_echo "no, forced" >&6; } 54301 BUILD_GTEST="false" 54302 elif test "x$enable_hotspot_gtest" = "x"; then 54303 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 54304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 54305 $as_echo "yes" >&6; } 54306 BUILD_GTEST="true" 54307 else 54308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54309 $as_echo "no" >&6; } 54310 BUILD_GTEST="false" 54311 fi 54312 else 54313 as_fn_error $? "--enable-gtest must be either yes or no" "$LINENO" 5 54314 fi 54315 54316 54317 54318 54319 ############################################################################### 54320 # 54321 # Check dependencies for external and internal libraries. 54322 # 54323 ############################################################################### 54324 54325 # After we have toolchain, we can compile fixpath. It's needed by the lib checks. 54326 54327 # When using cygwin or msys, we need a wrapper binary that renames 54328 # /cygdrive/c/ arguments into c:/ arguments and peeks into 54329 # @files and rewrites these too! This wrapper binary is 54330 # called fixpath. 54331 FIXPATH= 54332 if test "x$OPENJDK_BUILD_OS" = xwindows; then 54333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 54334 $as_echo_n "checking if fixpath can be created... " >&6; } 54335 FIXPATH_SRC="$TOPDIR/make/src/native/fixpath.c" 54336 FIXPATH_BIN="$CONFIGURESUPPORT_OUTPUTDIR/bin/fixpath.exe" 54337 FIXPATH_DIR="$CONFIGURESUPPORT_OUTPUTDIR/fixpath" 54338 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 54339 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 54340 FIXPATH="$FIXPATH_BIN -c" 54341 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 54342 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 54343 # @ was chosen as separator to minimize risk of other tools messing around with it 54344 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" \ 54345 | tr ' ' '\n' | $GREP '^/./' | $SORT | $UNIQ` 54346 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 54347 FIXPATH="$FIXPATH_BIN -m$fixpath_argument_list" 54348 fi 54349 FIXPATH_SRC_W="$FIXPATH_SRC" 54350 FIXPATH_BIN_W="$FIXPATH_BIN" 54351 54352 unix_path="$FIXPATH_SRC_W" 54353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54354 windows_path=`$CYGPATH -m "$unix_path"` 54355 FIXPATH_SRC_W="$windows_path" 54356 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54357 windows_path=`cmd //c echo $unix_path` 54358 FIXPATH_SRC_W="$windows_path" 54359 fi 54360 54361 54362 unix_path="$FIXPATH_BIN_W" 54363 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54364 windows_path=`$CYGPATH -m "$unix_path"` 54365 FIXPATH_BIN_W="$windows_path" 54366 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54367 windows_path=`cmd //c echo $unix_path` 54368 FIXPATH_BIN_W="$windows_path" 54369 fi 54370 54371 $RM -rf $FIXPATH_BIN $FIXPATH_DIR 54372 $MKDIR -p $FIXPATH_DIR $CONFIGURESUPPORT_OUTPUTDIR/bin 54373 cd $FIXPATH_DIR 54374 $CC $FIXPATH_SRC_W -Fe$FIXPATH_BIN_W > $FIXPATH_DIR/fixpath1.log 2>&1 54375 cd $CURDIR 54376 54377 if test ! -x $FIXPATH_BIN; then 54378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54379 $as_echo "no" >&6; } 54380 cat $FIXPATH_DIR/fixpath1.log 54381 as_fn_error $? "Could not create $FIXPATH_BIN" "$LINENO" 5 54382 fi 54383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 54384 $as_echo "yes" >&6; } 54385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 54386 $as_echo_n "checking if fixpath.exe works... " >&6; } 54387 cd $FIXPATH_DIR 54388 $FIXPATH $CC $FIXPATH_SRC -Fe$FIXPATH_DIR/fixpath2.exe \ 54389 > $FIXPATH_DIR/fixpath2.log 2>&1 54390 cd $CURDIR 54391 if test ! -x $FIXPATH_DIR/fixpath2.exe; then 54392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54393 $as_echo "no" >&6; } 54394 cat $FIXPATH_DIR/fixpath2.log 54395 as_fn_error $? "fixpath did not work!" "$LINENO" 5 54396 fi 54397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 54398 $as_echo "yes" >&6; } 54399 54400 FIXPATH_DETACH_FLAG="--detach" 54401 fi 54402 54403 54404 54405 54406 54407 54408 # Check if X11 is needed 54409 if test "x$OPENJDK_TARGET_OS" = xwindows || test "x$OPENJDK_TARGET_OS" = xmacosx; then 54410 # No X11 support on windows or macosx 54411 NEEDS_LIB_X11=false 54412 else 54413 # All other instances need X11, even if building headless only, libawt still 54414 # needs X11 headers. 54415 NEEDS_LIB_X11=true 54416 fi 54417 54418 # Check if cups is needed 54419 if test "x$OPENJDK_TARGET_OS" = xwindows; then 54420 # Windows have a separate print system 54421 NEEDS_LIB_CUPS=false 54422 else 54423 NEEDS_LIB_CUPS=true 54424 fi 54425 54426 # A custom hook may have set this already 54427 if test "x$NEEDS_LIB_FREETYPE" = "x"; then 54428 NEEDS_LIB_FREETYPE=true 54429 fi 54430 54431 # Check if alsa is needed 54432 if test "x$OPENJDK_TARGET_OS" = xlinux; then 54433 NEEDS_LIB_ALSA=true 54434 else 54435 NEEDS_LIB_ALSA=false 54436 fi 54437 54438 # Check if ffi is needed 54439 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 54440 NEEDS_LIB_FFI=true 54441 else 54442 NEEDS_LIB_FFI=false 54443 fi 54444 54445 54446 # statically link libstdc++ before C++ ABI is stablized on Linux unless 54447 # dynamic build is configured on command line. 54448 54449 # Check whether --with-stdc++lib was given. 54450 if test "${with_stdc__lib+set}" = set; then : 54451 withval=$with_stdc__lib; 54452 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 54453 && test "x$with_stdc__lib" != xdefault; then 54454 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 54455 fi 54456 54457 else 54458 with_stdc__lib=default 54459 54460 fi 54461 54462 54463 if test "x$OPENJDK_TARGET_OS" = xlinux; then 54464 # Test if stdc++ can be linked statically. 54465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 54466 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 54467 STATIC_STDCXX_FLAGS="-static-libstdc++ -static-libgcc" 54468 ac_ext=cpp 54469 ac_cpp='$CXXCPP $CPPFLAGS' 54470 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54471 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54472 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54473 54474 OLD_LIBS="$LIBS" 54475 LIBS="$STATIC_STDCXX_FLAGS" 54476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 54477 /* end confdefs.h. */ 54478 54479 int 54480 main () 54481 { 54482 return 0; 54483 ; 54484 return 0; 54485 } 54486 _ACEOF 54487 if ac_fn_cxx_try_link "$LINENO"; then : 54488 has_static_libstdcxx=yes 54489 else 54490 has_static_libstdcxx=no 54491 fi 54492 rm -f core conftest.err conftest.$ac_objext \ 54493 conftest$ac_exeext conftest.$ac_ext 54494 LIBS="$OLD_LIBS" 54495 ac_ext=cpp 54496 ac_cpp='$CXXCPP $CPPFLAGS' 54497 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54498 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54499 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54500 54501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 54502 $as_echo "$has_static_libstdcxx" >&6; } 54503 54504 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 54505 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 54506 fi 54507 54508 # If dynamic was requested, it's available since it would fail above otherwise. 54509 # If dynamic wasn't requested, go with static unless it isn't available. 54510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 54511 $as_echo_n "checking how to link with libstdc++... " >&6; } 54512 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno \ 54513 || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 54514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 54515 $as_echo "dynamic" >&6; } 54516 else 54517 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 54518 JVM_LDFLAGS="$JVM_LDFLAGS $STATIC_STDCXX_FLAGS" 54519 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 54520 # just use the same setting as for the TARGET toolchain. 54521 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $STATIC_STDCXX_FLAGS" 54522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 54523 $as_echo "static" >&6; } 54524 fi 54525 fi 54526 54527 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 54528 if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then 54529 LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 54530 fi 54531 54532 54533 54534 # Setup Windows runtime dlls 54535 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 54536 54537 54538 # Check whether --with-msvcr-dll was given. 54539 if test "${with_msvcr_dll+set}" = set; then : 54540 withval=$with_msvcr_dll; 54541 fi 54542 54543 54544 if test "x$with_msvcr_dll" != x; then 54545 # If given explicitly by user, do not probe. If not present, fail directly. 54546 54547 DLL_NAME="$MSVCR_NAME" 54548 POSSIBLE_MSVC_DLL="$with_msvcr_dll" 54549 METHOD="--with-msvcr-dll" 54550 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54551 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54552 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54553 54554 # Need to check if the found msvcr is correct architecture 54555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54556 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54557 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54558 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54559 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54560 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54561 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54562 CORRECT_MSVCR_ARCH="PE32 executable" 54563 else 54564 CORRECT_MSVCR_ARCH="PE32+ executable" 54565 fi 54566 else 54567 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54568 CORRECT_MSVCR_ARCH=386 54569 else 54570 CORRECT_MSVCR_ARCH=x86-64 54571 fi 54572 fi 54573 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54575 $as_echo "ok" >&6; } 54576 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54577 54578 # Only process if variable expands to non-empty 54579 54580 if test "x$MSVC_DLL" != x; then 54581 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54582 54583 # Input might be given as Windows format, start by converting to 54584 # unix format. 54585 path="$MSVC_DLL" 54586 new_path=`$CYGPATH -u "$path"` 54587 54588 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54589 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54590 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54591 # "foo.exe" is OK but "foo" is an error. 54592 # 54593 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54594 # It is also a way to make sure we got the proper file name for the real test later on. 54595 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54596 if test "x$test_shortpath" = x; then 54597 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54598 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54599 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54600 fi 54601 54602 # Call helper function which possibly converts this using DOS-style short mode. 54603 # If so, the updated path is stored in $new_path. 54604 54605 input_path="$new_path" 54606 # Check if we need to convert this using DOS-style short mode. If the path 54607 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54608 # take no chances and rewrite it. 54609 # Note: m4 eats our [], so we need to use [ and ] instead. 54610 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54611 if test "x$has_forbidden_chars" != x; then 54612 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54613 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54614 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54615 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54616 # Going to short mode and back again did indeed matter. Since short mode is 54617 # case insensitive, let's make it lowercase to improve readability. 54618 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54619 # Now convert it back to Unix-style (cygpath) 54620 input_path=`$CYGPATH -u "$shortmode_path"` 54621 new_path="$input_path" 54622 fi 54623 fi 54624 54625 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54626 if test "x$test_cygdrive_prefix" = x; then 54627 # As a simple fix, exclude /usr/bin since it's not a real path. 54628 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54629 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54630 # a path prefixed by /cygdrive for fixpath to work. 54631 new_path="$CYGWIN_ROOT_PATH$input_path" 54632 fi 54633 fi 54634 54635 54636 if test "x$path" != "x$new_path"; then 54637 MSVC_DLL="$new_path" 54638 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54639 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54640 fi 54641 54642 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54643 54644 path="$MSVC_DLL" 54645 has_colon=`$ECHO $path | $GREP ^.:` 54646 new_path="$path" 54647 if test "x$has_colon" = x; then 54648 # Not in mixed or Windows style, start by that. 54649 new_path=`cmd //c echo $path` 54650 fi 54651 54652 54653 input_path="$new_path" 54654 # Check if we need to convert this using DOS-style short mode. If the path 54655 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54656 # take no chances and rewrite it. 54657 # Note: m4 eats our [], so we need to use [ and ] instead. 54658 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54659 if test "x$has_forbidden_chars" != x; then 54660 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54661 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54662 fi 54663 54664 54665 windows_path="$new_path" 54666 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54667 unix_path=`$CYGPATH -u "$windows_path"` 54668 new_path="$unix_path" 54669 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54670 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54671 new_path="$unix_path" 54672 fi 54673 54674 if test "x$path" != "x$new_path"; then 54675 MSVC_DLL="$new_path" 54676 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54677 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54678 fi 54679 54680 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54681 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54682 54683 else 54684 # We're on a unix platform. Hooray! :) 54685 path="$MSVC_DLL" 54686 has_space=`$ECHO "$path" | $GREP " "` 54687 if test "x$has_space" != x; then 54688 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54689 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54690 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54691 fi 54692 54693 # Use eval to expand a potential ~ 54694 eval path="$path" 54695 if test ! -f "$path" && test ! -d "$path"; then 54696 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54697 fi 54698 54699 if test -d "$path"; then 54700 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54701 else 54702 dir="`$DIRNAME "$path"`" 54703 base="`$BASENAME "$path"`" 54704 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54705 fi 54706 fi 54707 fi 54708 54709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54710 $as_echo_n "checking for $DLL_NAME... " >&6; } 54711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54712 $as_echo "$MSVC_DLL" >&6; } 54713 else 54714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54715 $as_echo "incorrect, ignoring" >&6; } 54716 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54717 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54718 fi 54719 fi 54720 54721 if test "x$MSVC_DLL" = x; then 54722 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by --with-msvcr-dll" "$LINENO" 5 54723 fi 54724 MSVCR_DLL="$MSVC_DLL" 54725 elif test "x$DEVKIT_MSVCR_DLL" != x; then 54726 54727 DLL_NAME="$MSVCR_NAME" 54728 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCR_DLL" 54729 METHOD="devkit" 54730 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54731 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54732 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54733 54734 # Need to check if the found msvcr is correct architecture 54735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54736 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54737 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54738 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54739 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54740 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54741 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54742 CORRECT_MSVCR_ARCH="PE32 executable" 54743 else 54744 CORRECT_MSVCR_ARCH="PE32+ executable" 54745 fi 54746 else 54747 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54748 CORRECT_MSVCR_ARCH=386 54749 else 54750 CORRECT_MSVCR_ARCH=x86-64 54751 fi 54752 fi 54753 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54755 $as_echo "ok" >&6; } 54756 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54757 54758 # Only process if variable expands to non-empty 54759 54760 if test "x$MSVC_DLL" != x; then 54761 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54762 54763 # Input might be given as Windows format, start by converting to 54764 # unix format. 54765 path="$MSVC_DLL" 54766 new_path=`$CYGPATH -u "$path"` 54767 54768 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54769 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54770 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54771 # "foo.exe" is OK but "foo" is an error. 54772 # 54773 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54774 # It is also a way to make sure we got the proper file name for the real test later on. 54775 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54776 if test "x$test_shortpath" = x; then 54777 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54778 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54779 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54780 fi 54781 54782 # Call helper function which possibly converts this using DOS-style short mode. 54783 # If so, the updated path is stored in $new_path. 54784 54785 input_path="$new_path" 54786 # Check if we need to convert this using DOS-style short mode. If the path 54787 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54788 # take no chances and rewrite it. 54789 # Note: m4 eats our [], so we need to use [ and ] instead. 54790 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54791 if test "x$has_forbidden_chars" != x; then 54792 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54793 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54794 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54795 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54796 # Going to short mode and back again did indeed matter. Since short mode is 54797 # case insensitive, let's make it lowercase to improve readability. 54798 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54799 # Now convert it back to Unix-style (cygpath) 54800 input_path=`$CYGPATH -u "$shortmode_path"` 54801 new_path="$input_path" 54802 fi 54803 fi 54804 54805 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54806 if test "x$test_cygdrive_prefix" = x; then 54807 # As a simple fix, exclude /usr/bin since it's not a real path. 54808 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54809 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54810 # a path prefixed by /cygdrive for fixpath to work. 54811 new_path="$CYGWIN_ROOT_PATH$input_path" 54812 fi 54813 fi 54814 54815 54816 if test "x$path" != "x$new_path"; then 54817 MSVC_DLL="$new_path" 54818 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54819 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54820 fi 54821 54822 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54823 54824 path="$MSVC_DLL" 54825 has_colon=`$ECHO $path | $GREP ^.:` 54826 new_path="$path" 54827 if test "x$has_colon" = x; then 54828 # Not in mixed or Windows style, start by that. 54829 new_path=`cmd //c echo $path` 54830 fi 54831 54832 54833 input_path="$new_path" 54834 # Check if we need to convert this using DOS-style short mode. If the path 54835 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54836 # take no chances and rewrite it. 54837 # Note: m4 eats our [], so we need to use [ and ] instead. 54838 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54839 if test "x$has_forbidden_chars" != x; then 54840 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54841 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54842 fi 54843 54844 54845 windows_path="$new_path" 54846 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54847 unix_path=`$CYGPATH -u "$windows_path"` 54848 new_path="$unix_path" 54849 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54850 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54851 new_path="$unix_path" 54852 fi 54853 54854 if test "x$path" != "x$new_path"; then 54855 MSVC_DLL="$new_path" 54856 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54857 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54858 fi 54859 54860 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54861 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54862 54863 else 54864 # We're on a unix platform. Hooray! :) 54865 path="$MSVC_DLL" 54866 has_space=`$ECHO "$path" | $GREP " "` 54867 if test "x$has_space" != x; then 54868 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54869 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54870 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54871 fi 54872 54873 # Use eval to expand a potential ~ 54874 eval path="$path" 54875 if test ! -f "$path" && test ! -d "$path"; then 54876 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54877 fi 54878 54879 if test -d "$path"; then 54880 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54881 else 54882 dir="`$DIRNAME "$path"`" 54883 base="`$BASENAME "$path"`" 54884 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54885 fi 54886 fi 54887 fi 54888 54889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54890 $as_echo_n "checking for $DLL_NAME... " >&6; } 54891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54892 $as_echo "$MSVC_DLL" >&6; } 54893 else 54894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54895 $as_echo "incorrect, ignoring" >&6; } 54896 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54897 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54898 fi 54899 fi 54900 54901 if test "x$MSVC_DLL" = x; then 54902 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by devkit" "$LINENO" 5 54903 fi 54904 MSVCR_DLL="$MSVC_DLL" 54905 else 54906 54907 DLL_NAME="${MSVCR_NAME}" 54908 MSVC_DLL= 54909 54910 if test "x$MSVC_DLL" = x; then 54911 # Probe: Using well-known location from Visual Studio 10.0 54912 if test "x$VCINSTALLDIR" != x; then 54913 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 54914 54915 windows_path="$CYGWIN_VC_INSTALL_DIR" 54916 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54917 unix_path=`$CYGPATH -u "$windows_path"` 54918 CYGWIN_VC_INSTALL_DIR="$unix_path" 54919 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54920 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54921 CYGWIN_VC_INSTALL_DIR="$unix_path" 54922 fi 54923 54924 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54925 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 54926 else 54927 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 54928 fi 54929 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 54930 54931 DLL_NAME="$DLL_NAME" 54932 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54933 METHOD="well-known location in VCINSTALLDIR" 54934 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54935 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54936 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54937 54938 # Need to check if the found msvcr is correct architecture 54939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54940 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54941 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54942 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54943 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54944 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54945 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54946 CORRECT_MSVCR_ARCH="PE32 executable" 54947 else 54948 CORRECT_MSVCR_ARCH="PE32+ executable" 54949 fi 54950 else 54951 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54952 CORRECT_MSVCR_ARCH=386 54953 else 54954 CORRECT_MSVCR_ARCH=x86-64 54955 fi 54956 fi 54957 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54959 $as_echo "ok" >&6; } 54960 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54961 54962 # Only process if variable expands to non-empty 54963 54964 if test "x$MSVC_DLL" != x; then 54965 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54966 54967 # Input might be given as Windows format, start by converting to 54968 # unix format. 54969 path="$MSVC_DLL" 54970 new_path=`$CYGPATH -u "$path"` 54971 54972 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54973 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54974 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54975 # "foo.exe" is OK but "foo" is an error. 54976 # 54977 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54978 # It is also a way to make sure we got the proper file name for the real test later on. 54979 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54980 if test "x$test_shortpath" = x; then 54981 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54982 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54983 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54984 fi 54985 54986 # Call helper function which possibly converts this using DOS-style short mode. 54987 # If so, the updated path is stored in $new_path. 54988 54989 input_path="$new_path" 54990 # Check if we need to convert this using DOS-style short mode. If the path 54991 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54992 # take no chances and rewrite it. 54993 # Note: m4 eats our [], so we need to use [ and ] instead. 54994 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54995 if test "x$has_forbidden_chars" != x; then 54996 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54997 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54998 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54999 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55000 # Going to short mode and back again did indeed matter. Since short mode is 55001 # case insensitive, let's make it lowercase to improve readability. 55002 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55003 # Now convert it back to Unix-style (cygpath) 55004 input_path=`$CYGPATH -u "$shortmode_path"` 55005 new_path="$input_path" 55006 fi 55007 fi 55008 55009 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55010 if test "x$test_cygdrive_prefix" = x; then 55011 # As a simple fix, exclude /usr/bin since it's not a real path. 55012 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55013 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55014 # a path prefixed by /cygdrive for fixpath to work. 55015 new_path="$CYGWIN_ROOT_PATH$input_path" 55016 fi 55017 fi 55018 55019 55020 if test "x$path" != "x$new_path"; then 55021 MSVC_DLL="$new_path" 55022 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55023 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55024 fi 55025 55026 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55027 55028 path="$MSVC_DLL" 55029 has_colon=`$ECHO $path | $GREP ^.:` 55030 new_path="$path" 55031 if test "x$has_colon" = x; then 55032 # Not in mixed or Windows style, start by that. 55033 new_path=`cmd //c echo $path` 55034 fi 55035 55036 55037 input_path="$new_path" 55038 # Check if we need to convert this using DOS-style short mode. If the path 55039 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55040 # take no chances and rewrite it. 55041 # Note: m4 eats our [], so we need to use [ and ] instead. 55042 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55043 if test "x$has_forbidden_chars" != x; then 55044 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55045 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55046 fi 55047 55048 55049 windows_path="$new_path" 55050 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55051 unix_path=`$CYGPATH -u "$windows_path"` 55052 new_path="$unix_path" 55053 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55054 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55055 new_path="$unix_path" 55056 fi 55057 55058 if test "x$path" != "x$new_path"; then 55059 MSVC_DLL="$new_path" 55060 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55061 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55062 fi 55063 55064 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55065 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55066 55067 else 55068 # We're on a unix platform. Hooray! :) 55069 path="$MSVC_DLL" 55070 has_space=`$ECHO "$path" | $GREP " "` 55071 if test "x$has_space" != x; then 55072 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55073 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55074 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55075 fi 55076 55077 # Use eval to expand a potential ~ 55078 eval path="$path" 55079 if test ! -f "$path" && test ! -d "$path"; then 55080 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55081 fi 55082 55083 if test -d "$path"; then 55084 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55085 else 55086 dir="`$DIRNAME "$path"`" 55087 base="`$BASENAME "$path"`" 55088 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55089 fi 55090 fi 55091 fi 55092 55093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55094 $as_echo_n "checking for $DLL_NAME... " >&6; } 55095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55096 $as_echo "$MSVC_DLL" >&6; } 55097 else 55098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55099 $as_echo "incorrect, ignoring" >&6; } 55100 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55101 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55102 fi 55103 fi 55104 55105 fi 55106 fi 55107 55108 if test "x$MSVC_DLL" = x; then 55109 # Probe: Check in the Boot JDK directory. 55110 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 55111 55112 DLL_NAME="$DLL_NAME" 55113 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55114 METHOD="well-known location in Boot JDK" 55115 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55116 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55117 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55118 55119 # Need to check if the found msvcr is correct architecture 55120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55121 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55122 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55123 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55124 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55125 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55126 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55127 CORRECT_MSVCR_ARCH="PE32 executable" 55128 else 55129 CORRECT_MSVCR_ARCH="PE32+ executable" 55130 fi 55131 else 55132 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55133 CORRECT_MSVCR_ARCH=386 55134 else 55135 CORRECT_MSVCR_ARCH=x86-64 55136 fi 55137 fi 55138 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55140 $as_echo "ok" >&6; } 55141 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55142 55143 # Only process if variable expands to non-empty 55144 55145 if test "x$MSVC_DLL" != x; then 55146 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55147 55148 # Input might be given as Windows format, start by converting to 55149 # unix format. 55150 path="$MSVC_DLL" 55151 new_path=`$CYGPATH -u "$path"` 55152 55153 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55154 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55155 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55156 # "foo.exe" is OK but "foo" is an error. 55157 # 55158 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55159 # It is also a way to make sure we got the proper file name for the real test later on. 55160 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55161 if test "x$test_shortpath" = x; then 55162 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55163 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55164 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55165 fi 55166 55167 # Call helper function which possibly converts this using DOS-style short mode. 55168 # If so, the updated path is stored in $new_path. 55169 55170 input_path="$new_path" 55171 # Check if we need to convert this using DOS-style short mode. If the path 55172 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55173 # take no chances and rewrite it. 55174 # Note: m4 eats our [], so we need to use [ and ] instead. 55175 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55176 if test "x$has_forbidden_chars" != x; then 55177 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55178 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55179 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55180 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55181 # Going to short mode and back again did indeed matter. Since short mode is 55182 # case insensitive, let's make it lowercase to improve readability. 55183 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55184 # Now convert it back to Unix-style (cygpath) 55185 input_path=`$CYGPATH -u "$shortmode_path"` 55186 new_path="$input_path" 55187 fi 55188 fi 55189 55190 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55191 if test "x$test_cygdrive_prefix" = x; then 55192 # As a simple fix, exclude /usr/bin since it's not a real path. 55193 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55194 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55195 # a path prefixed by /cygdrive for fixpath to work. 55196 new_path="$CYGWIN_ROOT_PATH$input_path" 55197 fi 55198 fi 55199 55200 55201 if test "x$path" != "x$new_path"; then 55202 MSVC_DLL="$new_path" 55203 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55204 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55205 fi 55206 55207 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55208 55209 path="$MSVC_DLL" 55210 has_colon=`$ECHO $path | $GREP ^.:` 55211 new_path="$path" 55212 if test "x$has_colon" = x; then 55213 # Not in mixed or Windows style, start by that. 55214 new_path=`cmd //c echo $path` 55215 fi 55216 55217 55218 input_path="$new_path" 55219 # Check if we need to convert this using DOS-style short mode. If the path 55220 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55221 # take no chances and rewrite it. 55222 # Note: m4 eats our [], so we need to use [ and ] instead. 55223 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55224 if test "x$has_forbidden_chars" != x; then 55225 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55226 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55227 fi 55228 55229 55230 windows_path="$new_path" 55231 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55232 unix_path=`$CYGPATH -u "$windows_path"` 55233 new_path="$unix_path" 55234 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55235 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55236 new_path="$unix_path" 55237 fi 55238 55239 if test "x$path" != "x$new_path"; then 55240 MSVC_DLL="$new_path" 55241 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55242 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55243 fi 55244 55245 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55246 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55247 55248 else 55249 # We're on a unix platform. Hooray! :) 55250 path="$MSVC_DLL" 55251 has_space=`$ECHO "$path" | $GREP " "` 55252 if test "x$has_space" != x; then 55253 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55254 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55255 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55256 fi 55257 55258 # Use eval to expand a potential ~ 55259 eval path="$path" 55260 if test ! -f "$path" && test ! -d "$path"; then 55261 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55262 fi 55263 55264 if test -d "$path"; then 55265 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55266 else 55267 dir="`$DIRNAME "$path"`" 55268 base="`$BASENAME "$path"`" 55269 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55270 fi 55271 fi 55272 fi 55273 55274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55275 $as_echo_n "checking for $DLL_NAME... " >&6; } 55276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55277 $as_echo "$MSVC_DLL" >&6; } 55278 else 55279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55280 $as_echo "incorrect, ignoring" >&6; } 55281 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55282 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55283 fi 55284 fi 55285 55286 fi 55287 55288 if test "x$MSVC_DLL" = x; then 55289 # Probe: Look in the Windows system32 directory 55290 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 55291 55292 windows_path="$CYGWIN_SYSTEMROOT" 55293 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55294 unix_path=`$CYGPATH -u "$windows_path"` 55295 CYGWIN_SYSTEMROOT="$unix_path" 55296 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55297 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55298 CYGWIN_SYSTEMROOT="$unix_path" 55299 fi 55300 55301 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 55302 55303 DLL_NAME="$DLL_NAME" 55304 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55305 METHOD="well-known location in SYSTEMROOT" 55306 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55307 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55308 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55309 55310 # Need to check if the found msvcr is correct architecture 55311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55312 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55313 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55315 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55316 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55317 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55318 CORRECT_MSVCR_ARCH="PE32 executable" 55319 else 55320 CORRECT_MSVCR_ARCH="PE32+ executable" 55321 fi 55322 else 55323 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55324 CORRECT_MSVCR_ARCH=386 55325 else 55326 CORRECT_MSVCR_ARCH=x86-64 55327 fi 55328 fi 55329 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55331 $as_echo "ok" >&6; } 55332 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55333 55334 # Only process if variable expands to non-empty 55335 55336 if test "x$MSVC_DLL" != x; then 55337 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55338 55339 # Input might be given as Windows format, start by converting to 55340 # unix format. 55341 path="$MSVC_DLL" 55342 new_path=`$CYGPATH -u "$path"` 55343 55344 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55345 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55346 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55347 # "foo.exe" is OK but "foo" is an error. 55348 # 55349 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55350 # It is also a way to make sure we got the proper file name for the real test later on. 55351 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55352 if test "x$test_shortpath" = x; then 55353 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55354 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55355 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55356 fi 55357 55358 # Call helper function which possibly converts this using DOS-style short mode. 55359 # If so, the updated path is stored in $new_path. 55360 55361 input_path="$new_path" 55362 # Check if we need to convert this using DOS-style short mode. If the path 55363 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55364 # take no chances and rewrite it. 55365 # Note: m4 eats our [], so we need to use [ and ] instead. 55366 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55367 if test "x$has_forbidden_chars" != x; then 55368 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55369 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55370 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55371 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55372 # Going to short mode and back again did indeed matter. Since short mode is 55373 # case insensitive, let's make it lowercase to improve readability. 55374 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55375 # Now convert it back to Unix-style (cygpath) 55376 input_path=`$CYGPATH -u "$shortmode_path"` 55377 new_path="$input_path" 55378 fi 55379 fi 55380 55381 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55382 if test "x$test_cygdrive_prefix" = x; then 55383 # As a simple fix, exclude /usr/bin since it's not a real path. 55384 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55385 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55386 # a path prefixed by /cygdrive for fixpath to work. 55387 new_path="$CYGWIN_ROOT_PATH$input_path" 55388 fi 55389 fi 55390 55391 55392 if test "x$path" != "x$new_path"; then 55393 MSVC_DLL="$new_path" 55394 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55395 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55396 fi 55397 55398 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55399 55400 path="$MSVC_DLL" 55401 has_colon=`$ECHO $path | $GREP ^.:` 55402 new_path="$path" 55403 if test "x$has_colon" = x; then 55404 # Not in mixed or Windows style, start by that. 55405 new_path=`cmd //c echo $path` 55406 fi 55407 55408 55409 input_path="$new_path" 55410 # Check if we need to convert this using DOS-style short mode. If the path 55411 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55412 # take no chances and rewrite it. 55413 # Note: m4 eats our [], so we need to use [ and ] instead. 55414 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55415 if test "x$has_forbidden_chars" != x; then 55416 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55417 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55418 fi 55419 55420 55421 windows_path="$new_path" 55422 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55423 unix_path=`$CYGPATH -u "$windows_path"` 55424 new_path="$unix_path" 55425 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55426 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55427 new_path="$unix_path" 55428 fi 55429 55430 if test "x$path" != "x$new_path"; then 55431 MSVC_DLL="$new_path" 55432 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55433 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55434 fi 55435 55436 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55437 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55438 55439 else 55440 # We're on a unix platform. Hooray! :) 55441 path="$MSVC_DLL" 55442 has_space=`$ECHO "$path" | $GREP " "` 55443 if test "x$has_space" != x; then 55444 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55445 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55446 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55447 fi 55448 55449 # Use eval to expand a potential ~ 55450 eval path="$path" 55451 if test ! -f "$path" && test ! -d "$path"; then 55452 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55453 fi 55454 55455 if test -d "$path"; then 55456 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55457 else 55458 dir="`$DIRNAME "$path"`" 55459 base="`$BASENAME "$path"`" 55460 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55461 fi 55462 fi 55463 fi 55464 55465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55466 $as_echo_n "checking for $DLL_NAME... " >&6; } 55467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55468 $as_echo "$MSVC_DLL" >&6; } 55469 else 55470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55471 $as_echo "incorrect, ignoring" >&6; } 55472 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55473 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55474 fi 55475 fi 55476 55477 fi 55478 55479 if test "x$MSVC_DLL" = x; then 55480 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 55481 if test "x$VS100COMNTOOLS" != x; then 55482 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 55483 55484 windows_path="$CYGWIN_VS_TOOLS_DIR" 55485 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55486 unix_path=`$CYGPATH -u "$windows_path"` 55487 CYGWIN_VS_TOOLS_DIR="$unix_path" 55488 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55489 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55490 CYGWIN_VS_TOOLS_DIR="$unix_path" 55491 fi 55492 55493 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55494 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55495 | $GREP -i /x64/ | $HEAD --lines 1` 55496 else 55497 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55498 | $GREP -i /x86/ | $HEAD --lines 1` 55499 fi 55500 55501 DLL_NAME="$DLL_NAME" 55502 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55503 METHOD="search of VS100COMNTOOLS" 55504 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55505 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55506 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55507 55508 # Need to check if the found msvcr is correct architecture 55509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55510 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55511 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55512 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55513 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55514 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55515 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55516 CORRECT_MSVCR_ARCH="PE32 executable" 55517 else 55518 CORRECT_MSVCR_ARCH="PE32+ executable" 55519 fi 55520 else 55521 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55522 CORRECT_MSVCR_ARCH=386 55523 else 55524 CORRECT_MSVCR_ARCH=x86-64 55525 fi 55526 fi 55527 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55529 $as_echo "ok" >&6; } 55530 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55531 55532 # Only process if variable expands to non-empty 55533 55534 if test "x$MSVC_DLL" != x; then 55535 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55536 55537 # Input might be given as Windows format, start by converting to 55538 # unix format. 55539 path="$MSVC_DLL" 55540 new_path=`$CYGPATH -u "$path"` 55541 55542 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55543 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55544 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55545 # "foo.exe" is OK but "foo" is an error. 55546 # 55547 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55548 # It is also a way to make sure we got the proper file name for the real test later on. 55549 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55550 if test "x$test_shortpath" = x; then 55551 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55552 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55553 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55554 fi 55555 55556 # Call helper function which possibly converts this using DOS-style short mode. 55557 # If so, the updated path is stored in $new_path. 55558 55559 input_path="$new_path" 55560 # Check if we need to convert this using DOS-style short mode. If the path 55561 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55562 # take no chances and rewrite it. 55563 # Note: m4 eats our [], so we need to use [ and ] instead. 55564 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55565 if test "x$has_forbidden_chars" != x; then 55566 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55567 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55568 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55569 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55570 # Going to short mode and back again did indeed matter. Since short mode is 55571 # case insensitive, let's make it lowercase to improve readability. 55572 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55573 # Now convert it back to Unix-style (cygpath) 55574 input_path=`$CYGPATH -u "$shortmode_path"` 55575 new_path="$input_path" 55576 fi 55577 fi 55578 55579 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55580 if test "x$test_cygdrive_prefix" = x; then 55581 # As a simple fix, exclude /usr/bin since it's not a real path. 55582 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55583 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55584 # a path prefixed by /cygdrive for fixpath to work. 55585 new_path="$CYGWIN_ROOT_PATH$input_path" 55586 fi 55587 fi 55588 55589 55590 if test "x$path" != "x$new_path"; then 55591 MSVC_DLL="$new_path" 55592 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55593 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55594 fi 55595 55596 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55597 55598 path="$MSVC_DLL" 55599 has_colon=`$ECHO $path | $GREP ^.:` 55600 new_path="$path" 55601 if test "x$has_colon" = x; then 55602 # Not in mixed or Windows style, start by that. 55603 new_path=`cmd //c echo $path` 55604 fi 55605 55606 55607 input_path="$new_path" 55608 # Check if we need to convert this using DOS-style short mode. If the path 55609 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55610 # take no chances and rewrite it. 55611 # Note: m4 eats our [], so we need to use [ and ] instead. 55612 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55613 if test "x$has_forbidden_chars" != x; then 55614 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55615 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55616 fi 55617 55618 55619 windows_path="$new_path" 55620 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55621 unix_path=`$CYGPATH -u "$windows_path"` 55622 new_path="$unix_path" 55623 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55624 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55625 new_path="$unix_path" 55626 fi 55627 55628 if test "x$path" != "x$new_path"; then 55629 MSVC_DLL="$new_path" 55630 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55631 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55632 fi 55633 55634 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55635 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55636 55637 else 55638 # We're on a unix platform. Hooray! :) 55639 path="$MSVC_DLL" 55640 has_space=`$ECHO "$path" | $GREP " "` 55641 if test "x$has_space" != x; then 55642 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55643 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55644 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55645 fi 55646 55647 # Use eval to expand a potential ~ 55648 eval path="$path" 55649 if test ! -f "$path" && test ! -d "$path"; then 55650 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55651 fi 55652 55653 if test -d "$path"; then 55654 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55655 else 55656 dir="`$DIRNAME "$path"`" 55657 base="`$BASENAME "$path"`" 55658 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55659 fi 55660 fi 55661 fi 55662 55663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55664 $as_echo_n "checking for $DLL_NAME... " >&6; } 55665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55666 $as_echo "$MSVC_DLL" >&6; } 55667 else 55668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55669 $as_echo "incorrect, ignoring" >&6; } 55670 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55671 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55672 fi 55673 fi 55674 55675 fi 55676 fi 55677 55678 if test "x$MSVC_DLL" = x; then 55679 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 55680 # (This was the original behaviour; kept since it might turn something up) 55681 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 55682 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55683 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55684 | $GREP x64 | $HEAD --lines 1` 55685 else 55686 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55687 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 55688 if test "x$POSSIBLE_MSVC_DLL" = x; then 55689 # We're grasping at straws now... 55690 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55691 | $HEAD --lines 1` 55692 fi 55693 fi 55694 55695 55696 DLL_NAME="$DLL_NAME" 55697 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55698 METHOD="search of VCINSTALLDIR" 55699 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55700 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55701 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55702 55703 # Need to check if the found msvcr is correct architecture 55704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55705 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55706 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55707 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55708 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55709 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55710 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55711 CORRECT_MSVCR_ARCH="PE32 executable" 55712 else 55713 CORRECT_MSVCR_ARCH="PE32+ executable" 55714 fi 55715 else 55716 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55717 CORRECT_MSVCR_ARCH=386 55718 else 55719 CORRECT_MSVCR_ARCH=x86-64 55720 fi 55721 fi 55722 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55724 $as_echo "ok" >&6; } 55725 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55726 55727 # Only process if variable expands to non-empty 55728 55729 if test "x$MSVC_DLL" != x; then 55730 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55731 55732 # Input might be given as Windows format, start by converting to 55733 # unix format. 55734 path="$MSVC_DLL" 55735 new_path=`$CYGPATH -u "$path"` 55736 55737 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55738 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55739 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55740 # "foo.exe" is OK but "foo" is an error. 55741 # 55742 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55743 # It is also a way to make sure we got the proper file name for the real test later on. 55744 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55745 if test "x$test_shortpath" = x; then 55746 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55747 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55748 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55749 fi 55750 55751 # Call helper function which possibly converts this using DOS-style short mode. 55752 # If so, the updated path is stored in $new_path. 55753 55754 input_path="$new_path" 55755 # Check if we need to convert this using DOS-style short mode. If the path 55756 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55757 # take no chances and rewrite it. 55758 # Note: m4 eats our [], so we need to use [ and ] instead. 55759 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55760 if test "x$has_forbidden_chars" != x; then 55761 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55762 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55763 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55764 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55765 # Going to short mode and back again did indeed matter. Since short mode is 55766 # case insensitive, let's make it lowercase to improve readability. 55767 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55768 # Now convert it back to Unix-style (cygpath) 55769 input_path=`$CYGPATH -u "$shortmode_path"` 55770 new_path="$input_path" 55771 fi 55772 fi 55773 55774 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55775 if test "x$test_cygdrive_prefix" = x; then 55776 # As a simple fix, exclude /usr/bin since it's not a real path. 55777 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55778 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55779 # a path prefixed by /cygdrive for fixpath to work. 55780 new_path="$CYGWIN_ROOT_PATH$input_path" 55781 fi 55782 fi 55783 55784 55785 if test "x$path" != "x$new_path"; then 55786 MSVC_DLL="$new_path" 55787 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55788 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55789 fi 55790 55791 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55792 55793 path="$MSVC_DLL" 55794 has_colon=`$ECHO $path | $GREP ^.:` 55795 new_path="$path" 55796 if test "x$has_colon" = x; then 55797 # Not in mixed or Windows style, start by that. 55798 new_path=`cmd //c echo $path` 55799 fi 55800 55801 55802 input_path="$new_path" 55803 # Check if we need to convert this using DOS-style short mode. If the path 55804 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55805 # take no chances and rewrite it. 55806 # Note: m4 eats our [], so we need to use [ and ] instead. 55807 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55808 if test "x$has_forbidden_chars" != x; then 55809 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55810 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55811 fi 55812 55813 55814 windows_path="$new_path" 55815 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55816 unix_path=`$CYGPATH -u "$windows_path"` 55817 new_path="$unix_path" 55818 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55819 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55820 new_path="$unix_path" 55821 fi 55822 55823 if test "x$path" != "x$new_path"; then 55824 MSVC_DLL="$new_path" 55825 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55826 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55827 fi 55828 55829 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55830 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55831 55832 else 55833 # We're on a unix platform. Hooray! :) 55834 path="$MSVC_DLL" 55835 has_space=`$ECHO "$path" | $GREP " "` 55836 if test "x$has_space" != x; then 55837 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55838 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55839 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55840 fi 55841 55842 # Use eval to expand a potential ~ 55843 eval path="$path" 55844 if test ! -f "$path" && test ! -d "$path"; then 55845 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55846 fi 55847 55848 if test -d "$path"; then 55849 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55850 else 55851 dir="`$DIRNAME "$path"`" 55852 base="`$BASENAME "$path"`" 55853 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55854 fi 55855 fi 55856 fi 55857 55858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55859 $as_echo_n "checking for $DLL_NAME... " >&6; } 55860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55861 $as_echo "$MSVC_DLL" >&6; } 55862 else 55863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55864 $as_echo "incorrect, ignoring" >&6; } 55865 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55866 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55867 fi 55868 fi 55869 55870 fi 55871 fi 55872 55873 if test "x$MSVC_DLL" = x; then 55874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55875 $as_echo_n "checking for $DLL_NAME... " >&6; } 55876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 55877 $as_echo "no" >&6; } 55878 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 55879 fi 55880 55881 MSVCR_DLL="$MSVC_DLL" 55882 fi 55883 55884 55885 55886 # Check whether --with-msvcp-dll was given. 55887 if test "${with_msvcp_dll+set}" = set; then : 55888 withval=$with_msvcp_dll; 55889 fi 55890 55891 55892 if test "x$MSVCP_NAME" != "x"; then 55893 if test "x$with_msvcp_dll" != x; then 55894 # If given explicitly by user, do not probe. If not present, fail directly. 55895 55896 DLL_NAME="$MSVCP_NAME" 55897 POSSIBLE_MSVC_DLL="$with_msvcp_dll" 55898 METHOD="--with-msvcp-dll" 55899 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55900 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55901 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55902 55903 # Need to check if the found msvcr is correct architecture 55904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55905 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55906 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55907 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55908 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55909 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55910 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55911 CORRECT_MSVCR_ARCH="PE32 executable" 55912 else 55913 CORRECT_MSVCR_ARCH="PE32+ executable" 55914 fi 55915 else 55916 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55917 CORRECT_MSVCR_ARCH=386 55918 else 55919 CORRECT_MSVCR_ARCH=x86-64 55920 fi 55921 fi 55922 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55924 $as_echo "ok" >&6; } 55925 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55926 55927 # Only process if variable expands to non-empty 55928 55929 if test "x$MSVC_DLL" != x; then 55930 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55931 55932 # Input might be given as Windows format, start by converting to 55933 # unix format. 55934 path="$MSVC_DLL" 55935 new_path=`$CYGPATH -u "$path"` 55936 55937 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55938 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55939 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55940 # "foo.exe" is OK but "foo" is an error. 55941 # 55942 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55943 # It is also a way to make sure we got the proper file name for the real test later on. 55944 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55945 if test "x$test_shortpath" = x; then 55946 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55947 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55948 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55949 fi 55950 55951 # Call helper function which possibly converts this using DOS-style short mode. 55952 # If so, the updated path is stored in $new_path. 55953 55954 input_path="$new_path" 55955 # Check if we need to convert this using DOS-style short mode. If the path 55956 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55957 # take no chances and rewrite it. 55958 # Note: m4 eats our [], so we need to use [ and ] instead. 55959 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55960 if test "x$has_forbidden_chars" != x; then 55961 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55962 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55963 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55964 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55965 # Going to short mode and back again did indeed matter. Since short mode is 55966 # case insensitive, let's make it lowercase to improve readability. 55967 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55968 # Now convert it back to Unix-style (cygpath) 55969 input_path=`$CYGPATH -u "$shortmode_path"` 55970 new_path="$input_path" 55971 fi 55972 fi 55973 55974 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55975 if test "x$test_cygdrive_prefix" = x; then 55976 # As a simple fix, exclude /usr/bin since it's not a real path. 55977 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55978 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55979 # a path prefixed by /cygdrive for fixpath to work. 55980 new_path="$CYGWIN_ROOT_PATH$input_path" 55981 fi 55982 fi 55983 55984 55985 if test "x$path" != "x$new_path"; then 55986 MSVC_DLL="$new_path" 55987 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55988 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55989 fi 55990 55991 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55992 55993 path="$MSVC_DLL" 55994 has_colon=`$ECHO $path | $GREP ^.:` 55995 new_path="$path" 55996 if test "x$has_colon" = x; then 55997 # Not in mixed or Windows style, start by that. 55998 new_path=`cmd //c echo $path` 55999 fi 56000 56001 56002 input_path="$new_path" 56003 # Check if we need to convert this using DOS-style short mode. If the path 56004 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56005 # take no chances and rewrite it. 56006 # Note: m4 eats our [], so we need to use [ and ] instead. 56007 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56008 if test "x$has_forbidden_chars" != x; then 56009 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56010 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56011 fi 56012 56013 56014 windows_path="$new_path" 56015 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56016 unix_path=`$CYGPATH -u "$windows_path"` 56017 new_path="$unix_path" 56018 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56019 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56020 new_path="$unix_path" 56021 fi 56022 56023 if test "x$path" != "x$new_path"; then 56024 MSVC_DLL="$new_path" 56025 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56026 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56027 fi 56028 56029 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56030 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56031 56032 else 56033 # We're on a unix platform. Hooray! :) 56034 path="$MSVC_DLL" 56035 has_space=`$ECHO "$path" | $GREP " "` 56036 if test "x$has_space" != x; then 56037 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56038 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56039 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56040 fi 56041 56042 # Use eval to expand a potential ~ 56043 eval path="$path" 56044 if test ! -f "$path" && test ! -d "$path"; then 56045 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56046 fi 56047 56048 if test -d "$path"; then 56049 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56050 else 56051 dir="`$DIRNAME "$path"`" 56052 base="`$BASENAME "$path"`" 56053 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56054 fi 56055 fi 56056 fi 56057 56058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56059 $as_echo_n "checking for $DLL_NAME... " >&6; } 56060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56061 $as_echo "$MSVC_DLL" >&6; } 56062 else 56063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56064 $as_echo "incorrect, ignoring" >&6; } 56065 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56066 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56067 fi 56068 fi 56069 56070 if test "x$MSVC_DLL" = x; then 56071 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by --with-msvcp-dll" "$LINENO" 5 56072 fi 56073 MSVCP_DLL="$MSVC_DLL" 56074 elif test "x$DEVKIT_MSVCP_DLL" != x; then 56075 56076 DLL_NAME="$MSVCP_NAME" 56077 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCP_DLL" 56078 METHOD="devkit" 56079 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56080 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56081 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56082 56083 # Need to check if the found msvcr is correct architecture 56084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56085 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56086 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56087 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56088 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56089 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56090 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56091 CORRECT_MSVCR_ARCH="PE32 executable" 56092 else 56093 CORRECT_MSVCR_ARCH="PE32+ executable" 56094 fi 56095 else 56096 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56097 CORRECT_MSVCR_ARCH=386 56098 else 56099 CORRECT_MSVCR_ARCH=x86-64 56100 fi 56101 fi 56102 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56104 $as_echo "ok" >&6; } 56105 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56106 56107 # Only process if variable expands to non-empty 56108 56109 if test "x$MSVC_DLL" != x; then 56110 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56111 56112 # Input might be given as Windows format, start by converting to 56113 # unix format. 56114 path="$MSVC_DLL" 56115 new_path=`$CYGPATH -u "$path"` 56116 56117 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56118 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56119 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56120 # "foo.exe" is OK but "foo" is an error. 56121 # 56122 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56123 # It is also a way to make sure we got the proper file name for the real test later on. 56124 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56125 if test "x$test_shortpath" = x; then 56126 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56127 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56128 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56129 fi 56130 56131 # Call helper function which possibly converts this using DOS-style short mode. 56132 # If so, the updated path is stored in $new_path. 56133 56134 input_path="$new_path" 56135 # Check if we need to convert this using DOS-style short mode. If the path 56136 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56137 # take no chances and rewrite it. 56138 # Note: m4 eats our [], so we need to use [ and ] instead. 56139 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56140 if test "x$has_forbidden_chars" != x; then 56141 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56142 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56143 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56144 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56145 # Going to short mode and back again did indeed matter. Since short mode is 56146 # case insensitive, let's make it lowercase to improve readability. 56147 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56148 # Now convert it back to Unix-style (cygpath) 56149 input_path=`$CYGPATH -u "$shortmode_path"` 56150 new_path="$input_path" 56151 fi 56152 fi 56153 56154 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56155 if test "x$test_cygdrive_prefix" = x; then 56156 # As a simple fix, exclude /usr/bin since it's not a real path. 56157 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56158 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56159 # a path prefixed by /cygdrive for fixpath to work. 56160 new_path="$CYGWIN_ROOT_PATH$input_path" 56161 fi 56162 fi 56163 56164 56165 if test "x$path" != "x$new_path"; then 56166 MSVC_DLL="$new_path" 56167 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56168 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56169 fi 56170 56171 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56172 56173 path="$MSVC_DLL" 56174 has_colon=`$ECHO $path | $GREP ^.:` 56175 new_path="$path" 56176 if test "x$has_colon" = x; then 56177 # Not in mixed or Windows style, start by that. 56178 new_path=`cmd //c echo $path` 56179 fi 56180 56181 56182 input_path="$new_path" 56183 # Check if we need to convert this using DOS-style short mode. If the path 56184 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56185 # take no chances and rewrite it. 56186 # Note: m4 eats our [], so we need to use [ and ] instead. 56187 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56188 if test "x$has_forbidden_chars" != x; then 56189 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56190 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56191 fi 56192 56193 56194 windows_path="$new_path" 56195 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56196 unix_path=`$CYGPATH -u "$windows_path"` 56197 new_path="$unix_path" 56198 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56199 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56200 new_path="$unix_path" 56201 fi 56202 56203 if test "x$path" != "x$new_path"; then 56204 MSVC_DLL="$new_path" 56205 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56206 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56207 fi 56208 56209 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56210 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56211 56212 else 56213 # We're on a unix platform. Hooray! :) 56214 path="$MSVC_DLL" 56215 has_space=`$ECHO "$path" | $GREP " "` 56216 if test "x$has_space" != x; then 56217 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56218 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56219 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56220 fi 56221 56222 # Use eval to expand a potential ~ 56223 eval path="$path" 56224 if test ! -f "$path" && test ! -d "$path"; then 56225 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56226 fi 56227 56228 if test -d "$path"; then 56229 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56230 else 56231 dir="`$DIRNAME "$path"`" 56232 base="`$BASENAME "$path"`" 56233 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56234 fi 56235 fi 56236 fi 56237 56238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56239 $as_echo_n "checking for $DLL_NAME... " >&6; } 56240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56241 $as_echo "$MSVC_DLL" >&6; } 56242 else 56243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56244 $as_echo "incorrect, ignoring" >&6; } 56245 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56246 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56247 fi 56248 fi 56249 56250 if test "x$MSVC_DLL" = x; then 56251 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by devkit" "$LINENO" 5 56252 fi 56253 MSVCP_DLL="$MSVC_DLL" 56254 else 56255 56256 DLL_NAME="${MSVCP_NAME}" 56257 MSVC_DLL= 56258 56259 if test "x$MSVC_DLL" = x; then 56260 # Probe: Using well-known location from Visual Studio 10.0 56261 if test "x$VCINSTALLDIR" != x; then 56262 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 56263 56264 windows_path="$CYGWIN_VC_INSTALL_DIR" 56265 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56266 unix_path=`$CYGPATH -u "$windows_path"` 56267 CYGWIN_VC_INSTALL_DIR="$unix_path" 56268 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56269 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56270 CYGWIN_VC_INSTALL_DIR="$unix_path" 56271 fi 56272 56273 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56274 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 56275 else 56276 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 56277 fi 56278 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 56279 56280 DLL_NAME="$DLL_NAME" 56281 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56282 METHOD="well-known location in VCINSTALLDIR" 56283 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56284 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56285 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56286 56287 # Need to check if the found msvcr is correct architecture 56288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56289 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56290 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56291 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56292 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56293 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56294 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56295 CORRECT_MSVCR_ARCH="PE32 executable" 56296 else 56297 CORRECT_MSVCR_ARCH="PE32+ executable" 56298 fi 56299 else 56300 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56301 CORRECT_MSVCR_ARCH=386 56302 else 56303 CORRECT_MSVCR_ARCH=x86-64 56304 fi 56305 fi 56306 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56308 $as_echo "ok" >&6; } 56309 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56310 56311 # Only process if variable expands to non-empty 56312 56313 if test "x$MSVC_DLL" != x; then 56314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56315 56316 # Input might be given as Windows format, start by converting to 56317 # unix format. 56318 path="$MSVC_DLL" 56319 new_path=`$CYGPATH -u "$path"` 56320 56321 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56322 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56323 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56324 # "foo.exe" is OK but "foo" is an error. 56325 # 56326 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56327 # It is also a way to make sure we got the proper file name for the real test later on. 56328 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56329 if test "x$test_shortpath" = x; then 56330 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56331 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56332 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56333 fi 56334 56335 # Call helper function which possibly converts this using DOS-style short mode. 56336 # If so, the updated path is stored in $new_path. 56337 56338 input_path="$new_path" 56339 # Check if we need to convert this using DOS-style short mode. If the path 56340 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56341 # take no chances and rewrite it. 56342 # Note: m4 eats our [], so we need to use [ and ] instead. 56343 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56344 if test "x$has_forbidden_chars" != x; then 56345 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56346 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56347 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56348 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56349 # Going to short mode and back again did indeed matter. Since short mode is 56350 # case insensitive, let's make it lowercase to improve readability. 56351 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56352 # Now convert it back to Unix-style (cygpath) 56353 input_path=`$CYGPATH -u "$shortmode_path"` 56354 new_path="$input_path" 56355 fi 56356 fi 56357 56358 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56359 if test "x$test_cygdrive_prefix" = x; then 56360 # As a simple fix, exclude /usr/bin since it's not a real path. 56361 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56362 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56363 # a path prefixed by /cygdrive for fixpath to work. 56364 new_path="$CYGWIN_ROOT_PATH$input_path" 56365 fi 56366 fi 56367 56368 56369 if test "x$path" != "x$new_path"; then 56370 MSVC_DLL="$new_path" 56371 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56372 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56373 fi 56374 56375 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56376 56377 path="$MSVC_DLL" 56378 has_colon=`$ECHO $path | $GREP ^.:` 56379 new_path="$path" 56380 if test "x$has_colon" = x; then 56381 # Not in mixed or Windows style, start by that. 56382 new_path=`cmd //c echo $path` 56383 fi 56384 56385 56386 input_path="$new_path" 56387 # Check if we need to convert this using DOS-style short mode. If the path 56388 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56389 # take no chances and rewrite it. 56390 # Note: m4 eats our [], so we need to use [ and ] instead. 56391 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56392 if test "x$has_forbidden_chars" != x; then 56393 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56394 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56395 fi 56396 56397 56398 windows_path="$new_path" 56399 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56400 unix_path=`$CYGPATH -u "$windows_path"` 56401 new_path="$unix_path" 56402 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56403 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56404 new_path="$unix_path" 56405 fi 56406 56407 if test "x$path" != "x$new_path"; then 56408 MSVC_DLL="$new_path" 56409 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56410 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56411 fi 56412 56413 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56414 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56415 56416 else 56417 # We're on a unix platform. Hooray! :) 56418 path="$MSVC_DLL" 56419 has_space=`$ECHO "$path" | $GREP " "` 56420 if test "x$has_space" != x; then 56421 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56422 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56423 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56424 fi 56425 56426 # Use eval to expand a potential ~ 56427 eval path="$path" 56428 if test ! -f "$path" && test ! -d "$path"; then 56429 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56430 fi 56431 56432 if test -d "$path"; then 56433 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56434 else 56435 dir="`$DIRNAME "$path"`" 56436 base="`$BASENAME "$path"`" 56437 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56438 fi 56439 fi 56440 fi 56441 56442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56443 $as_echo_n "checking for $DLL_NAME... " >&6; } 56444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56445 $as_echo "$MSVC_DLL" >&6; } 56446 else 56447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56448 $as_echo "incorrect, ignoring" >&6; } 56449 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56450 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56451 fi 56452 fi 56453 56454 fi 56455 fi 56456 56457 if test "x$MSVC_DLL" = x; then 56458 # Probe: Check in the Boot JDK directory. 56459 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 56460 56461 DLL_NAME="$DLL_NAME" 56462 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56463 METHOD="well-known location in Boot JDK" 56464 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56465 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56466 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56467 56468 # Need to check if the found msvcr is correct architecture 56469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56470 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56471 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56472 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56473 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56474 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56475 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56476 CORRECT_MSVCR_ARCH="PE32 executable" 56477 else 56478 CORRECT_MSVCR_ARCH="PE32+ executable" 56479 fi 56480 else 56481 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56482 CORRECT_MSVCR_ARCH=386 56483 else 56484 CORRECT_MSVCR_ARCH=x86-64 56485 fi 56486 fi 56487 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56489 $as_echo "ok" >&6; } 56490 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56491 56492 # Only process if variable expands to non-empty 56493 56494 if test "x$MSVC_DLL" != x; then 56495 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56496 56497 # Input might be given as Windows format, start by converting to 56498 # unix format. 56499 path="$MSVC_DLL" 56500 new_path=`$CYGPATH -u "$path"` 56501 56502 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56503 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56504 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56505 # "foo.exe" is OK but "foo" is an error. 56506 # 56507 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56508 # It is also a way to make sure we got the proper file name for the real test later on. 56509 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56510 if test "x$test_shortpath" = x; then 56511 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56512 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56513 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56514 fi 56515 56516 # Call helper function which possibly converts this using DOS-style short mode. 56517 # If so, the updated path is stored in $new_path. 56518 56519 input_path="$new_path" 56520 # Check if we need to convert this using DOS-style short mode. If the path 56521 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56522 # take no chances and rewrite it. 56523 # Note: m4 eats our [], so we need to use [ and ] instead. 56524 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56525 if test "x$has_forbidden_chars" != x; then 56526 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56527 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56528 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56529 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56530 # Going to short mode and back again did indeed matter. Since short mode is 56531 # case insensitive, let's make it lowercase to improve readability. 56532 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56533 # Now convert it back to Unix-style (cygpath) 56534 input_path=`$CYGPATH -u "$shortmode_path"` 56535 new_path="$input_path" 56536 fi 56537 fi 56538 56539 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56540 if test "x$test_cygdrive_prefix" = x; then 56541 # As a simple fix, exclude /usr/bin since it's not a real path. 56542 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56543 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56544 # a path prefixed by /cygdrive for fixpath to work. 56545 new_path="$CYGWIN_ROOT_PATH$input_path" 56546 fi 56547 fi 56548 56549 56550 if test "x$path" != "x$new_path"; then 56551 MSVC_DLL="$new_path" 56552 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56553 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56554 fi 56555 56556 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56557 56558 path="$MSVC_DLL" 56559 has_colon=`$ECHO $path | $GREP ^.:` 56560 new_path="$path" 56561 if test "x$has_colon" = x; then 56562 # Not in mixed or Windows style, start by that. 56563 new_path=`cmd //c echo $path` 56564 fi 56565 56566 56567 input_path="$new_path" 56568 # Check if we need to convert this using DOS-style short mode. If the path 56569 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56570 # take no chances and rewrite it. 56571 # Note: m4 eats our [], so we need to use [ and ] instead. 56572 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56573 if test "x$has_forbidden_chars" != x; then 56574 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56575 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56576 fi 56577 56578 56579 windows_path="$new_path" 56580 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56581 unix_path=`$CYGPATH -u "$windows_path"` 56582 new_path="$unix_path" 56583 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56584 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56585 new_path="$unix_path" 56586 fi 56587 56588 if test "x$path" != "x$new_path"; then 56589 MSVC_DLL="$new_path" 56590 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56591 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56592 fi 56593 56594 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56595 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56596 56597 else 56598 # We're on a unix platform. Hooray! :) 56599 path="$MSVC_DLL" 56600 has_space=`$ECHO "$path" | $GREP " "` 56601 if test "x$has_space" != x; then 56602 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56603 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56604 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56605 fi 56606 56607 # Use eval to expand a potential ~ 56608 eval path="$path" 56609 if test ! -f "$path" && test ! -d "$path"; then 56610 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56611 fi 56612 56613 if test -d "$path"; then 56614 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56615 else 56616 dir="`$DIRNAME "$path"`" 56617 base="`$BASENAME "$path"`" 56618 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56619 fi 56620 fi 56621 fi 56622 56623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56624 $as_echo_n "checking for $DLL_NAME... " >&6; } 56625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56626 $as_echo "$MSVC_DLL" >&6; } 56627 else 56628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56629 $as_echo "incorrect, ignoring" >&6; } 56630 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56631 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56632 fi 56633 fi 56634 56635 fi 56636 56637 if test "x$MSVC_DLL" = x; then 56638 # Probe: Look in the Windows system32 directory 56639 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 56640 56641 windows_path="$CYGWIN_SYSTEMROOT" 56642 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56643 unix_path=`$CYGPATH -u "$windows_path"` 56644 CYGWIN_SYSTEMROOT="$unix_path" 56645 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56646 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56647 CYGWIN_SYSTEMROOT="$unix_path" 56648 fi 56649 56650 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 56651 56652 DLL_NAME="$DLL_NAME" 56653 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56654 METHOD="well-known location in SYSTEMROOT" 56655 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56656 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56657 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56658 56659 # Need to check if the found msvcr is correct architecture 56660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56661 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56662 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56663 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56664 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56665 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56666 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56667 CORRECT_MSVCR_ARCH="PE32 executable" 56668 else 56669 CORRECT_MSVCR_ARCH="PE32+ executable" 56670 fi 56671 else 56672 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56673 CORRECT_MSVCR_ARCH=386 56674 else 56675 CORRECT_MSVCR_ARCH=x86-64 56676 fi 56677 fi 56678 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56680 $as_echo "ok" >&6; } 56681 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56682 56683 # Only process if variable expands to non-empty 56684 56685 if test "x$MSVC_DLL" != x; then 56686 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56687 56688 # Input might be given as Windows format, start by converting to 56689 # unix format. 56690 path="$MSVC_DLL" 56691 new_path=`$CYGPATH -u "$path"` 56692 56693 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56694 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56695 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56696 # "foo.exe" is OK but "foo" is an error. 56697 # 56698 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56699 # It is also a way to make sure we got the proper file name for the real test later on. 56700 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56701 if test "x$test_shortpath" = x; then 56702 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56703 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56704 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56705 fi 56706 56707 # Call helper function which possibly converts this using DOS-style short mode. 56708 # If so, the updated path is stored in $new_path. 56709 56710 input_path="$new_path" 56711 # Check if we need to convert this using DOS-style short mode. If the path 56712 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56713 # take no chances and rewrite it. 56714 # Note: m4 eats our [], so we need to use [ and ] instead. 56715 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56716 if test "x$has_forbidden_chars" != x; then 56717 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56718 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56719 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56720 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56721 # Going to short mode and back again did indeed matter. Since short mode is 56722 # case insensitive, let's make it lowercase to improve readability. 56723 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56724 # Now convert it back to Unix-style (cygpath) 56725 input_path=`$CYGPATH -u "$shortmode_path"` 56726 new_path="$input_path" 56727 fi 56728 fi 56729 56730 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56731 if test "x$test_cygdrive_prefix" = x; then 56732 # As a simple fix, exclude /usr/bin since it's not a real path. 56733 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56734 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56735 # a path prefixed by /cygdrive for fixpath to work. 56736 new_path="$CYGWIN_ROOT_PATH$input_path" 56737 fi 56738 fi 56739 56740 56741 if test "x$path" != "x$new_path"; then 56742 MSVC_DLL="$new_path" 56743 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56744 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56745 fi 56746 56747 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56748 56749 path="$MSVC_DLL" 56750 has_colon=`$ECHO $path | $GREP ^.:` 56751 new_path="$path" 56752 if test "x$has_colon" = x; then 56753 # Not in mixed or Windows style, start by that. 56754 new_path=`cmd //c echo $path` 56755 fi 56756 56757 56758 input_path="$new_path" 56759 # Check if we need to convert this using DOS-style short mode. If the path 56760 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56761 # take no chances and rewrite it. 56762 # Note: m4 eats our [], so we need to use [ and ] instead. 56763 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56764 if test "x$has_forbidden_chars" != x; then 56765 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56766 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56767 fi 56768 56769 56770 windows_path="$new_path" 56771 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56772 unix_path=`$CYGPATH -u "$windows_path"` 56773 new_path="$unix_path" 56774 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56775 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56776 new_path="$unix_path" 56777 fi 56778 56779 if test "x$path" != "x$new_path"; then 56780 MSVC_DLL="$new_path" 56781 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56782 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56783 fi 56784 56785 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56786 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56787 56788 else 56789 # We're on a unix platform. Hooray! :) 56790 path="$MSVC_DLL" 56791 has_space=`$ECHO "$path" | $GREP " "` 56792 if test "x$has_space" != x; then 56793 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56794 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56795 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56796 fi 56797 56798 # Use eval to expand a potential ~ 56799 eval path="$path" 56800 if test ! -f "$path" && test ! -d "$path"; then 56801 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56802 fi 56803 56804 if test -d "$path"; then 56805 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56806 else 56807 dir="`$DIRNAME "$path"`" 56808 base="`$BASENAME "$path"`" 56809 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56810 fi 56811 fi 56812 fi 56813 56814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56815 $as_echo_n "checking for $DLL_NAME... " >&6; } 56816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56817 $as_echo "$MSVC_DLL" >&6; } 56818 else 56819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56820 $as_echo "incorrect, ignoring" >&6; } 56821 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56822 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56823 fi 56824 fi 56825 56826 fi 56827 56828 if test "x$MSVC_DLL" = x; then 56829 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 56830 if test "x$VS100COMNTOOLS" != x; then 56831 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 56832 56833 windows_path="$CYGWIN_VS_TOOLS_DIR" 56834 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56835 unix_path=`$CYGPATH -u "$windows_path"` 56836 CYGWIN_VS_TOOLS_DIR="$unix_path" 56837 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56838 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56839 CYGWIN_VS_TOOLS_DIR="$unix_path" 56840 fi 56841 56842 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56843 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 56844 | $GREP -i /x64/ | $HEAD --lines 1` 56845 else 56846 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 56847 | $GREP -i /x86/ | $HEAD --lines 1` 56848 fi 56849 56850 DLL_NAME="$DLL_NAME" 56851 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56852 METHOD="search of VS100COMNTOOLS" 56853 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56854 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56855 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56856 56857 # Need to check if the found msvcr is correct architecture 56858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56859 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56860 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56861 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56862 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56863 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56864 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56865 CORRECT_MSVCR_ARCH="PE32 executable" 56866 else 56867 CORRECT_MSVCR_ARCH="PE32+ executable" 56868 fi 56869 else 56870 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56871 CORRECT_MSVCR_ARCH=386 56872 else 56873 CORRECT_MSVCR_ARCH=x86-64 56874 fi 56875 fi 56876 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56878 $as_echo "ok" >&6; } 56879 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56880 56881 # Only process if variable expands to non-empty 56882 56883 if test "x$MSVC_DLL" != x; then 56884 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56885 56886 # Input might be given as Windows format, start by converting to 56887 # unix format. 56888 path="$MSVC_DLL" 56889 new_path=`$CYGPATH -u "$path"` 56890 56891 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56892 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56893 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56894 # "foo.exe" is OK but "foo" is an error. 56895 # 56896 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56897 # It is also a way to make sure we got the proper file name for the real test later on. 56898 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56899 if test "x$test_shortpath" = x; then 56900 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56901 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56902 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56903 fi 56904 56905 # Call helper function which possibly converts this using DOS-style short mode. 56906 # If so, the updated path is stored in $new_path. 56907 56908 input_path="$new_path" 56909 # Check if we need to convert this using DOS-style short mode. If the path 56910 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56911 # take no chances and rewrite it. 56912 # Note: m4 eats our [], so we need to use [ and ] instead. 56913 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56914 if test "x$has_forbidden_chars" != x; then 56915 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56916 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56917 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56918 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56919 # Going to short mode and back again did indeed matter. Since short mode is 56920 # case insensitive, let's make it lowercase to improve readability. 56921 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56922 # Now convert it back to Unix-style (cygpath) 56923 input_path=`$CYGPATH -u "$shortmode_path"` 56924 new_path="$input_path" 56925 fi 56926 fi 56927 56928 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56929 if test "x$test_cygdrive_prefix" = x; then 56930 # As a simple fix, exclude /usr/bin since it's not a real path. 56931 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56932 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56933 # a path prefixed by /cygdrive for fixpath to work. 56934 new_path="$CYGWIN_ROOT_PATH$input_path" 56935 fi 56936 fi 56937 56938 56939 if test "x$path" != "x$new_path"; then 56940 MSVC_DLL="$new_path" 56941 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56942 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56943 fi 56944 56945 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56946 56947 path="$MSVC_DLL" 56948 has_colon=`$ECHO $path | $GREP ^.:` 56949 new_path="$path" 56950 if test "x$has_colon" = x; then 56951 # Not in mixed or Windows style, start by that. 56952 new_path=`cmd //c echo $path` 56953 fi 56954 56955 56956 input_path="$new_path" 56957 # Check if we need to convert this using DOS-style short mode. If the path 56958 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56959 # take no chances and rewrite it. 56960 # Note: m4 eats our [], so we need to use [ and ] instead. 56961 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56962 if test "x$has_forbidden_chars" != x; then 56963 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56964 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56965 fi 56966 56967 56968 windows_path="$new_path" 56969 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56970 unix_path=`$CYGPATH -u "$windows_path"` 56971 new_path="$unix_path" 56972 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56973 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56974 new_path="$unix_path" 56975 fi 56976 56977 if test "x$path" != "x$new_path"; then 56978 MSVC_DLL="$new_path" 56979 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56980 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56981 fi 56982 56983 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56984 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56985 56986 else 56987 # We're on a unix platform. Hooray! :) 56988 path="$MSVC_DLL" 56989 has_space=`$ECHO "$path" | $GREP " "` 56990 if test "x$has_space" != x; then 56991 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56992 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56993 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56994 fi 56995 56996 # Use eval to expand a potential ~ 56997 eval path="$path" 56998 if test ! -f "$path" && test ! -d "$path"; then 56999 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 57000 fi 57001 57002 if test -d "$path"; then 57003 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 57004 else 57005 dir="`$DIRNAME "$path"`" 57006 base="`$BASENAME "$path"`" 57007 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 57008 fi 57009 fi 57010 fi 57011 57012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 57013 $as_echo_n "checking for $DLL_NAME... " >&6; } 57014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 57015 $as_echo "$MSVC_DLL" >&6; } 57016 else 57017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 57018 $as_echo "incorrect, ignoring" >&6; } 57019 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 57020 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 57021 fi 57022 fi 57023 57024 fi 57025 fi 57026 57027 if test "x$MSVC_DLL" = x; then 57028 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 57029 # (This was the original behaviour; kept since it might turn something up) 57030 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 57031 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 57032 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 57033 | $GREP x64 | $HEAD --lines 1` 57034 else 57035 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 57036 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 57037 if test "x$POSSIBLE_MSVC_DLL" = x; then 57038 # We're grasping at straws now... 57039 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 57040 | $HEAD --lines 1` 57041 fi 57042 fi 57043 57044 57045 DLL_NAME="$DLL_NAME" 57046 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 57047 METHOD="search of VCINSTALLDIR" 57048 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 57049 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 57050 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 57051 57052 # Need to check if the found msvcr is correct architecture 57053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 57054 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 57055 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 57056 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57057 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 57058 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 57059 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57060 CORRECT_MSVCR_ARCH="PE32 executable" 57061 else 57062 CORRECT_MSVCR_ARCH="PE32+ executable" 57063 fi 57064 else 57065 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57066 CORRECT_MSVCR_ARCH=386 57067 else 57068 CORRECT_MSVCR_ARCH=x86-64 57069 fi 57070 fi 57071 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 57072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 57073 $as_echo "ok" >&6; } 57074 MSVC_DLL="$POSSIBLE_MSVC_DLL" 57075 57076 # Only process if variable expands to non-empty 57077 57078 if test "x$MSVC_DLL" != x; then 57079 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57080 57081 # Input might be given as Windows format, start by converting to 57082 # unix format. 57083 path="$MSVC_DLL" 57084 new_path=`$CYGPATH -u "$path"` 57085 57086 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57087 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57088 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57089 # "foo.exe" is OK but "foo" is an error. 57090 # 57091 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57092 # It is also a way to make sure we got the proper file name for the real test later on. 57093 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57094 if test "x$test_shortpath" = x; then 57095 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57096 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57097 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 57098 fi 57099 57100 # Call helper function which possibly converts this using DOS-style short mode. 57101 # If so, the updated path is stored in $new_path. 57102 57103 input_path="$new_path" 57104 # Check if we need to convert this using DOS-style short mode. If the path 57105 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57106 # take no chances and rewrite it. 57107 # Note: m4 eats our [], so we need to use [ and ] instead. 57108 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57109 if test "x$has_forbidden_chars" != x; then 57110 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57111 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57112 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57113 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57114 # Going to short mode and back again did indeed matter. Since short mode is 57115 # case insensitive, let's make it lowercase to improve readability. 57116 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57117 # Now convert it back to Unix-style (cygpath) 57118 input_path=`$CYGPATH -u "$shortmode_path"` 57119 new_path="$input_path" 57120 fi 57121 fi 57122 57123 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57124 if test "x$test_cygdrive_prefix" = x; then 57125 # As a simple fix, exclude /usr/bin since it's not a real path. 57126 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57127 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57128 # a path prefixed by /cygdrive for fixpath to work. 57129 new_path="$CYGWIN_ROOT_PATH$input_path" 57130 fi 57131 fi 57132 57133 57134 if test "x$path" != "x$new_path"; then 57135 MSVC_DLL="$new_path" 57136 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57137 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57138 fi 57139 57140 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57141 57142 path="$MSVC_DLL" 57143 has_colon=`$ECHO $path | $GREP ^.:` 57144 new_path="$path" 57145 if test "x$has_colon" = x; then 57146 # Not in mixed or Windows style, start by that. 57147 new_path=`cmd //c echo $path` 57148 fi 57149 57150 57151 input_path="$new_path" 57152 # Check if we need to convert this using DOS-style short mode. If the path 57153 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57154 # take no chances and rewrite it. 57155 # Note: m4 eats our [], so we need to use [ and ] instead. 57156 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57157 if test "x$has_forbidden_chars" != x; then 57158 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57159 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57160 fi 57161 57162 57163 windows_path="$new_path" 57164 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57165 unix_path=`$CYGPATH -u "$windows_path"` 57166 new_path="$unix_path" 57167 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57168 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57169 new_path="$unix_path" 57170 fi 57171 57172 if test "x$path" != "x$new_path"; then 57173 MSVC_DLL="$new_path" 57174 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57175 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57176 fi 57177 57178 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57179 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57180 57181 else 57182 # We're on a unix platform. Hooray! :) 57183 path="$MSVC_DLL" 57184 has_space=`$ECHO "$path" | $GREP " "` 57185 if test "x$has_space" != x; then 57186 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57187 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57188 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57189 fi 57190 57191 # Use eval to expand a potential ~ 57192 eval path="$path" 57193 if test ! -f "$path" && test ! -d "$path"; then 57194 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 57195 fi 57196 57197 if test -d "$path"; then 57198 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 57199 else 57200 dir="`$DIRNAME "$path"`" 57201 base="`$BASENAME "$path"`" 57202 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 57203 fi 57204 fi 57205 fi 57206 57207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 57208 $as_echo_n "checking for $DLL_NAME... " >&6; } 57209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 57210 $as_echo "$MSVC_DLL" >&6; } 57211 else 57212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 57213 $as_echo "incorrect, ignoring" >&6; } 57214 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 57215 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 57216 fi 57217 fi 57218 57219 fi 57220 fi 57221 57222 if test "x$MSVC_DLL" = x; then 57223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 57224 $as_echo_n "checking for $DLL_NAME... " >&6; } 57225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57226 $as_echo "no" >&6; } 57227 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 57228 fi 57229 57230 MSVCP_DLL="$MSVC_DLL" 57231 fi 57232 57233 fi 57234 57235 fi 57236 57237 57238 if test "x$NEEDS_LIB_X11" = xfalse; then 57239 if (test "x${with_x}" != x && test "x${with_x}" != xno); then 57240 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: X11 is not used, so --with-x is ignored" >&5 57241 $as_echo "$as_me: WARNING: X11 is not used, so --with-x is ignored" >&2;} 57242 fi 57243 X_CFLAGS= 57244 X_LIBS= 57245 else 57246 57247 if test "x${with_x}" = xno; then 57248 as_fn_error $? "It is not possible to disable the use of X11. Remove the --without-x option." "$LINENO" 5 57249 fi 57250 57251 if test "x${with_x}" != x && test "x${with_x}" != xyes; then 57252 # The user has specified a X11 base directory. Use it for includes and 57253 # libraries, unless explicitly overridden. 57254 if test "x$x_includes" = xNONE; then 57255 x_includes="${with_x}/include" 57256 fi 57257 if test "x$x_libraries" = xNONE; then 57258 x_libraries="${with_x}/lib" 57259 fi 57260 else 57261 # Check if the user has specified sysroot, but not --with-x, --x-includes or --x-libraries. 57262 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 57263 # --x-libraries for the sysroot, if that seems to be correct. 57264 if test "x$SYSROOT" != "x"; then 57265 if test "x$x_includes" = xNONE; then 57266 if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then 57267 x_includes="$SYSROOT/usr/X11R6/include" 57268 elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then 57269 x_includes="$SYSROOT/usr/include" 57270 fi 57271 fi 57272 if test "x$x_libraries" = xNONE; then 57273 if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then 57274 x_libraries="$SYSROOT/usr/X11R6/lib" 57275 elif test -f "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 57276 x_libraries="$SYSROOT/usr/lib64" 57277 elif test -f "$SYSROOT/usr/lib/libX11.so"; then 57278 x_libraries="$SYSROOT/usr/lib" 57279 fi 57280 fi 57281 fi 57282 fi 57283 57284 # Now let autoconf do it's magic 57285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 57286 $as_echo_n "checking for X... " >&6; } 57287 57288 57289 # Check whether --with-x was given. 57290 if test "${with_x+set}" = set; then : 57291 withval=$with_x; 57292 fi 57293 57294 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 57295 if test "x$with_x" = xno; then 57296 # The user explicitly disabled X. 57297 have_x=disabled 57298 else 57299 case $x_includes,$x_libraries in #( 57300 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 57301 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 57302 $as_echo_n "(cached) " >&6 57303 else 57304 # One or both of the vars are not set, and there is no cached value. 57305 ac_x_includes=no ac_x_libraries=no 57306 rm -f -r conftest.dir 57307 if mkdir conftest.dir; then 57308 cd conftest.dir 57309 cat >Imakefile <<'_ACEOF' 57310 incroot: 57311 @echo incroot='${INCROOT}' 57312 usrlibdir: 57313 @echo usrlibdir='${USRLIBDIR}' 57314 libdir: 57315 @echo libdir='${LIBDIR}' 57316 _ACEOF 57317 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 57318 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 57319 for ac_var in incroot usrlibdir libdir; do 57320 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 57321 done 57322 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 57323 for ac_extension in a so sl dylib la dll; do 57324 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 57325 test -f "$ac_im_libdir/libX11.$ac_extension"; then 57326 ac_im_usrlibdir=$ac_im_libdir; break 57327 fi 57328 done 57329 # Screen out bogus values from the imake configuration. They are 57330 # bogus both because they are the default anyway, and because 57331 # using them would break gcc on systems where it needs fixed includes. 57332 case $ac_im_incroot in 57333 /usr/include) ac_x_includes= ;; 57334 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 57335 esac 57336 case $ac_im_usrlibdir in 57337 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 57338 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 57339 esac 57340 fi 57341 cd .. 57342 rm -f -r conftest.dir 57343 fi 57344 57345 # Standard set of common directories for X headers. 57346 # Check X11 before X11Rn because it is often a symlink to the current release. 57347 ac_x_header_dirs=' 57348 /usr/X11/include 57349 /usr/X11R7/include 57350 /usr/X11R6/include 57351 /usr/X11R5/include 57352 /usr/X11R4/include 57353 57354 /usr/include/X11 57355 /usr/include/X11R7 57356 /usr/include/X11R6 57357 /usr/include/X11R5 57358 /usr/include/X11R4 57359 57360 /usr/local/X11/include 57361 /usr/local/X11R7/include 57362 /usr/local/X11R6/include 57363 /usr/local/X11R5/include 57364 /usr/local/X11R4/include 57365 57366 /usr/local/include/X11 57367 /usr/local/include/X11R7 57368 /usr/local/include/X11R6 57369 /usr/local/include/X11R5 57370 /usr/local/include/X11R4 57371 57372 /usr/X386/include 57373 /usr/x386/include 57374 /usr/XFree86/include/X11 57375 57376 /usr/include 57377 /usr/local/include 57378 /usr/unsupported/include 57379 /usr/athena/include 57380 /usr/local/x11r5/include 57381 /usr/lpp/Xamples/include 57382 57383 /usr/openwin/include 57384 /usr/openwin/share/include' 57385 57386 if test "$ac_x_includes" = no; then 57387 # Guess where to find include files, by looking for Xlib.h. 57388 # First, try using that file with no special directory specified. 57389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57390 /* end confdefs.h. */ 57391 #include <X11/Xlib.h> 57392 _ACEOF 57393 if ac_fn_cxx_try_cpp "$LINENO"; then : 57394 # We can compile using X headers with no special include directory. 57395 ac_x_includes= 57396 else 57397 for ac_dir in $ac_x_header_dirs; do 57398 if test -r "$ac_dir/X11/Xlib.h"; then 57399 ac_x_includes=$ac_dir 57400 break 57401 fi 57402 done 57403 fi 57404 rm -f conftest.err conftest.i conftest.$ac_ext 57405 fi # $ac_x_includes = no 57406 57407 if test "$ac_x_libraries" = no; then 57408 # Check for the libraries. 57409 # See if we find them without any special options. 57410 # Don't add to $LIBS permanently. 57411 ac_save_LIBS=$LIBS 57412 LIBS="-lX11 $LIBS" 57413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57414 /* end confdefs.h. */ 57415 #include <X11/Xlib.h> 57416 int 57417 main () 57418 { 57419 XrmInitialize () 57420 ; 57421 return 0; 57422 } 57423 _ACEOF 57424 if ac_fn_cxx_try_link "$LINENO"; then : 57425 LIBS=$ac_save_LIBS 57426 # We can link X programs with no special library path. 57427 ac_x_libraries= 57428 else 57429 LIBS=$ac_save_LIBS 57430 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 57431 do 57432 # Don't even attempt the hair of trying to link an X program! 57433 for ac_extension in a so sl dylib la dll; do 57434 if test -r "$ac_dir/libX11.$ac_extension"; then 57435 ac_x_libraries=$ac_dir 57436 break 2 57437 fi 57438 done 57439 done 57440 fi 57441 rm -f core conftest.err conftest.$ac_objext \ 57442 conftest$ac_exeext conftest.$ac_ext 57443 fi # $ac_x_libraries = no 57444 57445 case $ac_x_includes,$ac_x_libraries in #( 57446 no,* | *,no | *\'*) 57447 # Didn't find X, or a directory has "'" in its name. 57448 ac_cv_have_x="have_x=no";; #( 57449 *) 57450 # Record where we found X for the cache. 57451 ac_cv_have_x="have_x=yes\ 57452 ac_x_includes='$ac_x_includes'\ 57453 ac_x_libraries='$ac_x_libraries'" 57454 esac 57455 fi 57456 ;; #( 57457 *) have_x=yes;; 57458 esac 57459 eval "$ac_cv_have_x" 57460 fi # $with_x != no 57461 57462 if test "$have_x" != yes; then 57463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 57464 $as_echo "$have_x" >&6; } 57465 no_x=yes 57466 else 57467 # If each of the values was on the command line, it overrides each guess. 57468 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 57469 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 57470 # Update the cache value to reflect the command line values. 57471 ac_cv_have_x="have_x=yes\ 57472 ac_x_includes='$x_includes'\ 57473 ac_x_libraries='$x_libraries'" 57474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 57475 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 57476 fi 57477 57478 if test "$no_x" = yes; then 57479 # Not all programs may use this symbol, but it does not hurt to define it. 57480 57481 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 57482 57483 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 57484 else 57485 if test -n "$x_includes"; then 57486 X_CFLAGS="$X_CFLAGS -I$x_includes" 57487 fi 57488 57489 # It would also be nice to do this for all -L options, not just this one. 57490 if test -n "$x_libraries"; then 57491 X_LIBS="$X_LIBS -L$x_libraries" 57492 # For Solaris; some versions of Sun CC require a space after -R and 57493 # others require no space. Words are not sufficient . . . . 57494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 57495 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 57496 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 57497 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 57498 ac_cxx_werror_flag=yes 57499 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57500 /* end confdefs.h. */ 57501 57502 int 57503 main () 57504 { 57505 57506 ; 57507 return 0; 57508 } 57509 _ACEOF 57510 if ac_fn_cxx_try_link "$LINENO"; then : 57511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57512 $as_echo "no" >&6; } 57513 X_LIBS="$X_LIBS -R$x_libraries" 57514 else 57515 LIBS="$ac_xsave_LIBS -R $x_libraries" 57516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57517 /* end confdefs.h. */ 57518 57519 int 57520 main () 57521 { 57522 57523 ; 57524 return 0; 57525 } 57526 _ACEOF 57527 if ac_fn_cxx_try_link "$LINENO"; then : 57528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 57529 $as_echo "yes" >&6; } 57530 X_LIBS="$X_LIBS -R $x_libraries" 57531 else 57532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 57533 $as_echo "neither works" >&6; } 57534 fi 57535 rm -f core conftest.err conftest.$ac_objext \ 57536 conftest$ac_exeext conftest.$ac_ext 57537 fi 57538 rm -f core conftest.err conftest.$ac_objext \ 57539 conftest$ac_exeext conftest.$ac_ext 57540 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 57541 LIBS=$ac_xsave_LIBS 57542 fi 57543 57544 # Check for system-dependent libraries X programs must link with. 57545 # Do this before checking for the system-independent R6 libraries 57546 # (-lICE), since we may need -lsocket or whatever for X linking. 57547 57548 if test "$ISC" = yes; then 57549 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 57550 else 57551 # Martyn Johnson says this is needed for Ultrix, if the X 57552 # libraries were built with DECnet support. And Karl Berry says 57553 # the Alpha needs dnet_stub (dnet does not exist). 57554 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 57555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57556 /* end confdefs.h. */ 57557 57558 /* Override any GCC internal prototype to avoid an error. 57559 Use char because int might match the return type of a GCC 57560 builtin and then its argument prototype would still apply. */ 57561 #ifdef __cplusplus 57562 extern "C" 57563 #endif 57564 char XOpenDisplay (); 57565 int 57566 main () 57567 { 57568 return XOpenDisplay (); 57569 ; 57570 return 0; 57571 } 57572 _ACEOF 57573 if ac_fn_cxx_try_link "$LINENO"; then : 57574 57575 else 57576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 57577 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 57578 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 57579 $as_echo_n "(cached) " >&6 57580 else 57581 ac_check_lib_save_LIBS=$LIBS 57582 LIBS="-ldnet $LIBS" 57583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57584 /* end confdefs.h. */ 57585 57586 /* Override any GCC internal prototype to avoid an error. 57587 Use char because int might match the return type of a GCC 57588 builtin and then its argument prototype would still apply. */ 57589 #ifdef __cplusplus 57590 extern "C" 57591 #endif 57592 char dnet_ntoa (); 57593 int 57594 main () 57595 { 57596 return dnet_ntoa (); 57597 ; 57598 return 0; 57599 } 57600 _ACEOF 57601 if ac_fn_cxx_try_link "$LINENO"; then : 57602 ac_cv_lib_dnet_dnet_ntoa=yes 57603 else 57604 ac_cv_lib_dnet_dnet_ntoa=no 57605 fi 57606 rm -f core conftest.err conftest.$ac_objext \ 57607 conftest$ac_exeext conftest.$ac_ext 57608 LIBS=$ac_check_lib_save_LIBS 57609 fi 57610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 57611 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 57612 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 57613 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 57614 fi 57615 57616 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 57617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 57618 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 57619 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 57620 $as_echo_n "(cached) " >&6 57621 else 57622 ac_check_lib_save_LIBS=$LIBS 57623 LIBS="-ldnet_stub $LIBS" 57624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57625 /* end confdefs.h. */ 57626 57627 /* Override any GCC internal prototype to avoid an error. 57628 Use char because int might match the return type of a GCC 57629 builtin and then its argument prototype would still apply. */ 57630 #ifdef __cplusplus 57631 extern "C" 57632 #endif 57633 char dnet_ntoa (); 57634 int 57635 main () 57636 { 57637 return dnet_ntoa (); 57638 ; 57639 return 0; 57640 } 57641 _ACEOF 57642 if ac_fn_cxx_try_link "$LINENO"; then : 57643 ac_cv_lib_dnet_stub_dnet_ntoa=yes 57644 else 57645 ac_cv_lib_dnet_stub_dnet_ntoa=no 57646 fi 57647 rm -f core conftest.err conftest.$ac_objext \ 57648 conftest$ac_exeext conftest.$ac_ext 57649 LIBS=$ac_check_lib_save_LIBS 57650 fi 57651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 57652 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 57653 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 57654 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 57655 fi 57656 57657 fi 57658 fi 57659 rm -f core conftest.err conftest.$ac_objext \ 57660 conftest$ac_exeext conftest.$ac_ext 57661 LIBS="$ac_xsave_LIBS" 57662 57663 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 57664 # to get the SysV transport functions. 57665 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 57666 # needs -lnsl. 57667 # The nsl library prevents programs from opening the X display 57668 # on Irix 5.2, according to T.E. Dickey. 57669 # The functions gethostbyname, getservbyname, and inet_addr are 57670 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 57671 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 57672 if test "x$ac_cv_func_gethostbyname" = xyes; then : 57673 57674 fi 57675 57676 if test $ac_cv_func_gethostbyname = no; then 57677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 57678 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 57679 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 57680 $as_echo_n "(cached) " >&6 57681 else 57682 ac_check_lib_save_LIBS=$LIBS 57683 LIBS="-lnsl $LIBS" 57684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57685 /* end confdefs.h. */ 57686 57687 /* Override any GCC internal prototype to avoid an error. 57688 Use char because int might match the return type of a GCC 57689 builtin and then its argument prototype would still apply. */ 57690 #ifdef __cplusplus 57691 extern "C" 57692 #endif 57693 char gethostbyname (); 57694 int 57695 main () 57696 { 57697 return gethostbyname (); 57698 ; 57699 return 0; 57700 } 57701 _ACEOF 57702 if ac_fn_cxx_try_link "$LINENO"; then : 57703 ac_cv_lib_nsl_gethostbyname=yes 57704 else 57705 ac_cv_lib_nsl_gethostbyname=no 57706 fi 57707 rm -f core conftest.err conftest.$ac_objext \ 57708 conftest$ac_exeext conftest.$ac_ext 57709 LIBS=$ac_check_lib_save_LIBS 57710 fi 57711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 57712 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 57713 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 57714 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 57715 fi 57716 57717 if test $ac_cv_lib_nsl_gethostbyname = no; then 57718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 57719 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 57720 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 57721 $as_echo_n "(cached) " >&6 57722 else 57723 ac_check_lib_save_LIBS=$LIBS 57724 LIBS="-lbsd $LIBS" 57725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57726 /* end confdefs.h. */ 57727 57728 /* Override any GCC internal prototype to avoid an error. 57729 Use char because int might match the return type of a GCC 57730 builtin and then its argument prototype would still apply. */ 57731 #ifdef __cplusplus 57732 extern "C" 57733 #endif 57734 char gethostbyname (); 57735 int 57736 main () 57737 { 57738 return gethostbyname (); 57739 ; 57740 return 0; 57741 } 57742 _ACEOF 57743 if ac_fn_cxx_try_link "$LINENO"; then : 57744 ac_cv_lib_bsd_gethostbyname=yes 57745 else 57746 ac_cv_lib_bsd_gethostbyname=no 57747 fi 57748 rm -f core conftest.err conftest.$ac_objext \ 57749 conftest$ac_exeext conftest.$ac_ext 57750 LIBS=$ac_check_lib_save_LIBS 57751 fi 57752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 57753 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 57754 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 57755 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 57756 fi 57757 57758 fi 57759 fi 57760 57761 # lieder@skyler.mavd.honeywell.com says without -lsocket, 57762 # socket/setsockopt and other routines are undefined under SCO ODT 57763 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 57764 # on later versions), says Simon Leinen: it contains gethostby* 57765 # variants that don't use the name server (or something). -lsocket 57766 # must be given before -lnsl if both are needed. We assume that 57767 # if connect needs -lnsl, so does gethostbyname. 57768 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 57769 if test "x$ac_cv_func_connect" = xyes; then : 57770 57771 fi 57772 57773 if test $ac_cv_func_connect = no; then 57774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 57775 $as_echo_n "checking for connect in -lsocket... " >&6; } 57776 if ${ac_cv_lib_socket_connect+:} false; then : 57777 $as_echo_n "(cached) " >&6 57778 else 57779 ac_check_lib_save_LIBS=$LIBS 57780 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 57781 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57782 /* end confdefs.h. */ 57783 57784 /* Override any GCC internal prototype to avoid an error. 57785 Use char because int might match the return type of a GCC 57786 builtin and then its argument prototype would still apply. */ 57787 #ifdef __cplusplus 57788 extern "C" 57789 #endif 57790 char connect (); 57791 int 57792 main () 57793 { 57794 return connect (); 57795 ; 57796 return 0; 57797 } 57798 _ACEOF 57799 if ac_fn_cxx_try_link "$LINENO"; then : 57800 ac_cv_lib_socket_connect=yes 57801 else 57802 ac_cv_lib_socket_connect=no 57803 fi 57804 rm -f core conftest.err conftest.$ac_objext \ 57805 conftest$ac_exeext conftest.$ac_ext 57806 LIBS=$ac_check_lib_save_LIBS 57807 fi 57808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 57809 $as_echo "$ac_cv_lib_socket_connect" >&6; } 57810 if test "x$ac_cv_lib_socket_connect" = xyes; then : 57811 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 57812 fi 57813 57814 fi 57815 57816 # Guillermo Gomez says -lposix is necessary on A/UX. 57817 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 57818 if test "x$ac_cv_func_remove" = xyes; then : 57819 57820 fi 57821 57822 if test $ac_cv_func_remove = no; then 57823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 57824 $as_echo_n "checking for remove in -lposix... " >&6; } 57825 if ${ac_cv_lib_posix_remove+:} false; then : 57826 $as_echo_n "(cached) " >&6 57827 else 57828 ac_check_lib_save_LIBS=$LIBS 57829 LIBS="-lposix $LIBS" 57830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57831 /* end confdefs.h. */ 57832 57833 /* Override any GCC internal prototype to avoid an error. 57834 Use char because int might match the return type of a GCC 57835 builtin and then its argument prototype would still apply. */ 57836 #ifdef __cplusplus 57837 extern "C" 57838 #endif 57839 char remove (); 57840 int 57841 main () 57842 { 57843 return remove (); 57844 ; 57845 return 0; 57846 } 57847 _ACEOF 57848 if ac_fn_cxx_try_link "$LINENO"; then : 57849 ac_cv_lib_posix_remove=yes 57850 else 57851 ac_cv_lib_posix_remove=no 57852 fi 57853 rm -f core conftest.err conftest.$ac_objext \ 57854 conftest$ac_exeext conftest.$ac_ext 57855 LIBS=$ac_check_lib_save_LIBS 57856 fi 57857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 57858 $as_echo "$ac_cv_lib_posix_remove" >&6; } 57859 if test "x$ac_cv_lib_posix_remove" = xyes; then : 57860 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 57861 fi 57862 57863 fi 57864 57865 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 57866 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 57867 if test "x$ac_cv_func_shmat" = xyes; then : 57868 57869 fi 57870 57871 if test $ac_cv_func_shmat = no; then 57872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 57873 $as_echo_n "checking for shmat in -lipc... " >&6; } 57874 if ${ac_cv_lib_ipc_shmat+:} false; then : 57875 $as_echo_n "(cached) " >&6 57876 else 57877 ac_check_lib_save_LIBS=$LIBS 57878 LIBS="-lipc $LIBS" 57879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57880 /* end confdefs.h. */ 57881 57882 /* Override any GCC internal prototype to avoid an error. 57883 Use char because int might match the return type of a GCC 57884 builtin and then its argument prototype would still apply. */ 57885 #ifdef __cplusplus 57886 extern "C" 57887 #endif 57888 char shmat (); 57889 int 57890 main () 57891 { 57892 return shmat (); 57893 ; 57894 return 0; 57895 } 57896 _ACEOF 57897 if ac_fn_cxx_try_link "$LINENO"; then : 57898 ac_cv_lib_ipc_shmat=yes 57899 else 57900 ac_cv_lib_ipc_shmat=no 57901 fi 57902 rm -f core conftest.err conftest.$ac_objext \ 57903 conftest$ac_exeext conftest.$ac_ext 57904 LIBS=$ac_check_lib_save_LIBS 57905 fi 57906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 57907 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 57908 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 57909 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 57910 fi 57911 57912 fi 57913 fi 57914 57915 # Check for libraries that X11R6 Xt/Xaw programs need. 57916 ac_save_LDFLAGS=$LDFLAGS 57917 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 57918 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 57919 # check for ICE first), but we must link in the order -lSM -lICE or 57920 # we get undefined symbols. So assume we have SM if we have ICE. 57921 # These have to be linked with before -lX11, unlike the other 57922 # libraries we check for below, so use a different variable. 57923 # John Interrante, Karl Berry 57924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 57925 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 57926 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 57927 $as_echo_n "(cached) " >&6 57928 else 57929 ac_check_lib_save_LIBS=$LIBS 57930 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 57931 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57932 /* end confdefs.h. */ 57933 57934 /* Override any GCC internal prototype to avoid an error. 57935 Use char because int might match the return type of a GCC 57936 builtin and then its argument prototype would still apply. */ 57937 #ifdef __cplusplus 57938 extern "C" 57939 #endif 57940 char IceConnectionNumber (); 57941 int 57942 main () 57943 { 57944 return IceConnectionNumber (); 57945 ; 57946 return 0; 57947 } 57948 _ACEOF 57949 if ac_fn_cxx_try_link "$LINENO"; then : 57950 ac_cv_lib_ICE_IceConnectionNumber=yes 57951 else 57952 ac_cv_lib_ICE_IceConnectionNumber=no 57953 fi 57954 rm -f core conftest.err conftest.$ac_objext \ 57955 conftest$ac_exeext conftest.$ac_ext 57956 LIBS=$ac_check_lib_save_LIBS 57957 fi 57958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 57959 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 57960 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 57961 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 57962 fi 57963 57964 LDFLAGS=$ac_save_LDFLAGS 57965 57966 fi 57967 57968 57969 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 57970 # this doesn't make sense so we remove it. 57971 if test "x$COMPILE_TYPE" = xcross; then 57972 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 57973 fi 57974 57975 if test "x$no_x" = xyes; then 57976 57977 # Print a helpful message on how to acquire the necessary build dependency. 57978 # x11 is the help tag: freetype, cups, alsa etc 57979 MISSING_DEPENDENCY=x11 57980 57981 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57982 cygwin_help $MISSING_DEPENDENCY 57983 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57984 msys_help $MISSING_DEPENDENCY 57985 else 57986 PKGHANDLER_COMMAND= 57987 57988 case $PKGHANDLER in 57989 apt-get) 57990 apt_help $MISSING_DEPENDENCY ;; 57991 yum) 57992 yum_help $MISSING_DEPENDENCY ;; 57993 brew) 57994 brew_help $MISSING_DEPENDENCY ;; 57995 port) 57996 port_help $MISSING_DEPENDENCY ;; 57997 pkgutil) 57998 pkgutil_help $MISSING_DEPENDENCY ;; 57999 pkgadd) 58000 pkgadd_help $MISSING_DEPENDENCY ;; 58001 esac 58002 58003 if test "x$PKGHANDLER_COMMAND" != x; then 58004 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 58005 fi 58006 fi 58007 58008 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 58009 fi 58010 58011 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 58012 OPENWIN_HOME="/usr/openwin" 58013 X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions" 58014 X_LIBS="-L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \ 58015 -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR" 58016 fi 58017 58018 ac_ext=c 58019 ac_cpp='$CPP $CPPFLAGS' 58020 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 58021 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 58022 ac_compiler_gnu=$ac_cv_c_compiler_gnu 58023 58024 OLD_CFLAGS="$CFLAGS" 58025 CFLAGS="$CFLAGS $SYSROOT_CFLAGS $X_CFLAGS" 58026 58027 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 58028 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h 58029 do : 58030 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 58031 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " 58032 # include <X11/Xlib.h> 58033 # include <X11/Xutil.h> 58034 58035 58036 " 58037 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 58038 cat >>confdefs.h <<_ACEOF 58039 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 58040 _ACEOF 58041 X11_HEADERS_OK=yes 58042 else 58043 X11_HEADERS_OK=no; break 58044 fi 58045 58046 done 58047 58048 58049 if test "x$X11_HEADERS_OK" = xno; then 58050 58051 # Print a helpful message on how to acquire the necessary build dependency. 58052 # x11 is the help tag: freetype, cups, alsa etc 58053 MISSING_DEPENDENCY=x11 58054 58055 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58056 cygwin_help $MISSING_DEPENDENCY 58057 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58058 msys_help $MISSING_DEPENDENCY 58059 else 58060 PKGHANDLER_COMMAND= 58061 58062 case $PKGHANDLER in 58063 apt-get) 58064 apt_help $MISSING_DEPENDENCY ;; 58065 yum) 58066 yum_help $MISSING_DEPENDENCY ;; 58067 brew) 58068 brew_help $MISSING_DEPENDENCY ;; 58069 port) 58070 port_help $MISSING_DEPENDENCY ;; 58071 pkgutil) 58072 pkgutil_help $MISSING_DEPENDENCY ;; 58073 pkgadd) 58074 pkgadd_help $MISSING_DEPENDENCY ;; 58075 esac 58076 58077 if test "x$PKGHANDLER_COMMAND" != x; then 58078 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 58079 fi 58080 fi 58081 58082 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5 58083 fi 58084 58085 # If XLinearGradient isn't available in Xrender.h, signal that it needs to be 58086 # defined in libawt_xawt. 58087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if XlinearGradient is defined in Xrender.h" >&5 58088 $as_echo_n "checking if XlinearGradient is defined in Xrender.h... " >&6; } 58089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58090 /* end confdefs.h. */ 58091 #include <X11/extensions/Xrender.h> 58092 int 58093 main () 58094 { 58095 XLinearGradient x; 58096 ; 58097 return 0; 58098 } 58099 _ACEOF 58100 if ac_fn_c_try_compile "$LINENO"; then : 58101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 58102 $as_echo "yes" >&6; } 58103 else 58104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 58105 $as_echo "no" >&6; } 58106 X_CFLAGS="$X_CFLAGS -DSOLARIS10_NO_XRENDER_STRUCTS" 58107 fi 58108 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 58109 58110 CFLAGS="$OLD_CFLAGS" 58111 ac_ext=cpp 58112 ac_cpp='$CXXCPP $CPPFLAGS' 58113 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 58114 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 58115 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 58116 58117 fi # NEEDS_LIB_X11 58118 58119 58120 58121 58122 58123 58124 # Check whether --with-cups was given. 58125 if test "${with_cups+set}" = set; then : 58126 withval=$with_cups; 58127 fi 58128 58129 58130 # Check whether --with-cups-include was given. 58131 if test "${with_cups_include+set}" = set; then : 58132 withval=$with_cups_include; 58133 fi 58134 58135 58136 if test "x$NEEDS_LIB_CUPS" = xfalse; then 58137 if (test "x${with_cups}" != x && test "x${with_cups}" != xno) || \ 58138 (test "x${with_cups_include}" != x && test "x${with_cups_include}" != xno); then 58139 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups[-*] is ignored" >&5 58140 $as_echo "$as_me: WARNING: cups not used, so --with-cups[-*] is ignored" >&2;} 58141 fi 58142 CUPS_CFLAGS= 58143 else 58144 CUPS_FOUND=no 58145 58146 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 58147 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 58148 fi 58149 58150 if test "x${with_cups}" != x; then 58151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 58152 $as_echo_n "checking for cups headers... " >&6; } 58153 if test -s "${with_cups}/include/cups/cups.h"; then 58154 CUPS_CFLAGS="-I${with_cups}/include" 58155 CUPS_FOUND=yes 58156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 58157 $as_echo "$CUPS_FOUND" >&6; } 58158 else 58159 as_fn_error $? "Can't find 'include/cups/cups.h' under ${with_cups} given with the --with-cups option." "$LINENO" 5 58160 fi 58161 fi 58162 if test "x${with_cups_include}" != x; then 58163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 58164 $as_echo_n "checking for cups headers... " >&6; } 58165 if test -s "${with_cups_include}/cups/cups.h"; then 58166 CUPS_CFLAGS="-I${with_cups_include}" 58167 CUPS_FOUND=yes 58168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 58169 $as_echo "$CUPS_FOUND" >&6; } 58170 else 58171 as_fn_error $? "Can't find 'cups/cups.h' under ${with_cups_include} given with the --with-cups-include option." "$LINENO" 5 58172 fi 58173 fi 58174 if test "x$CUPS_FOUND" = xno; then 58175 # Are the cups headers installed in the default /usr/include location? 58176 for ac_header in cups/cups.h cups/ppd.h 58177 do : 58178 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 58179 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 58180 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 58181 cat >>confdefs.h <<_ACEOF 58182 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 58183 _ACEOF 58184 58185 CUPS_FOUND=yes 58186 CUPS_CFLAGS= 58187 DEFAULT_CUPS=yes 58188 58189 fi 58190 58191 done 58192 58193 fi 58194 if test "x$CUPS_FOUND" = xno; then 58195 58196 # Print a helpful message on how to acquire the necessary build dependency. 58197 # cups is the help tag: freetype, cups, alsa etc 58198 MISSING_DEPENDENCY=cups 58199 58200 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58201 cygwin_help $MISSING_DEPENDENCY 58202 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58203 msys_help $MISSING_DEPENDENCY 58204 else 58205 PKGHANDLER_COMMAND= 58206 58207 case $PKGHANDLER in 58208 apt-get) 58209 apt_help $MISSING_DEPENDENCY ;; 58210 yum) 58211 yum_help $MISSING_DEPENDENCY ;; 58212 brew) 58213 brew_help $MISSING_DEPENDENCY ;; 58214 port) 58215 port_help $MISSING_DEPENDENCY ;; 58216 pkgutil) 58217 pkgutil_help $MISSING_DEPENDENCY ;; 58218 pkgadd) 58219 pkgadd_help $MISSING_DEPENDENCY ;; 58220 esac 58221 58222 if test "x$PKGHANDLER_COMMAND" != x; then 58223 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 58224 fi 58225 fi 58226 58227 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 58228 fi 58229 fi 58230 58231 58232 58233 58234 58235 # Check whether --with-freetype was given. 58236 if test "${with_freetype+set}" = set; then : 58237 withval=$with_freetype; 58238 fi 58239 58240 58241 # Check whether --with-freetype-include was given. 58242 if test "${with_freetype_include+set}" = set; then : 58243 withval=$with_freetype_include; 58244 fi 58245 58246 58247 # Check whether --with-freetype-lib was given. 58248 if test "${with_freetype_lib+set}" = set; then : 58249 withval=$with_freetype_lib; 58250 fi 58251 58252 58253 # Check whether --with-freetype-src was given. 58254 if test "${with_freetype_src+set}" = set; then : 58255 withval=$with_freetype_src; 58256 fi 58257 58258 # Check whether --enable-freetype-bundling was given. 58259 if test "${enable_freetype_bundling+set}" = set; then : 58260 enableval=$enable_freetype_bundling; 58261 fi 58262 58263 58264 # Check whether --with-freetype-license was given. 58265 if test "${with_freetype_license+set}" = set; then : 58266 withval=$with_freetype_license; 58267 fi 58268 58269 58270 # Need to specify explicitly since it needs to be overridden on some versions of macosx 58271 FREETYPE_BASE_NAME=freetype 58272 FREETYPE_CFLAGS= 58273 FREETYPE_LIBS= 58274 FREETYPE_BUNDLE_LIB_PATH= 58275 58276 if test "x$NEEDS_LIB_FREETYPE" = xfalse; then 58277 if (test "x$with_freetype" != x && test "x$with_freetype" != xno) || \ 58278 (test "x$with_freetype_include" != x && test "x$with_freetype_include" != xno) || \ 58279 (test "x$with_freetype_lib" != x && test "x$with_freetype_lib" != xno) || \ 58280 (test "x$with_freetype_src" != x && test "x$with_freetype_src" != xno); then 58281 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&5 58282 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&2;} 58283 fi 58284 if (test "x$enable_freetype_bundling" != x && test "x$enable_freetype_bundling" != xno); then 58285 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5 58286 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;} 58287 fi 58288 else 58289 # freetype is needed to build; go get it! 58290 58291 BUNDLE_FREETYPE="$enable_freetype_bundling" 58292 58293 if test "x$with_freetype_src" != x; then 58294 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58295 # Try to build freetype if --with-freetype-src was given on Windows 58296 58297 FREETYPE_SRC_PATH="$with_freetype_src" 58298 BUILD_FREETYPE=yes 58299 58300 # Check if the freetype sources are acessible.. 58301 if ! test -d $FREETYPE_SRC_PATH; then 58302 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&5 58303 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 58304 BUILD_FREETYPE=no 58305 fi 58306 # ..and contain a vc2010 project file 58307 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 58308 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 58309 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&5 58310 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 58311 BUILD_FREETYPE=no 58312 fi 58313 # Now check if configure found a version of 'msbuild.exe' 58314 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 58315 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can not find an msbuild.exe executable (you may try to install .NET 4.0) - ignoring --with-freetype-src" >&5 58316 $as_echo "$as_me: WARNING: Can not find an msbuild.exe executable (you may try to install .NET 4.0) - ignoring --with-freetype-src" >&2;} 58317 BUILD_FREETYPE=no 58318 fi 58319 58320 # Ready to go.. 58321 if test "x$BUILD_FREETYPE" = xyes; then 58322 # msbuild requires trailing slashes for output directories 58323 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 58324 freetype_lib_path_unix="$freetype_lib_path" 58325 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 58326 58327 unix_path="$vcxproj_path" 58328 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58329 windows_path=`$CYGPATH -m "$unix_path"` 58330 vcxproj_path="$windows_path" 58331 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58332 windows_path=`cmd //c echo $unix_path` 58333 vcxproj_path="$windows_path" 58334 fi 58335 58336 58337 unix_path="$freetype_lib_path" 58338 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58339 windows_path=`$CYGPATH -m "$unix_path"` 58340 freetype_lib_path="$windows_path" 58341 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58342 windows_path=`cmd //c echo $unix_path` 58343 freetype_lib_path="$windows_path" 58344 fi 58345 58346 58347 unix_path="$freetype_obj_path" 58348 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58349 windows_path=`$CYGPATH -m "$unix_path"` 58350 freetype_obj_path="$windows_path" 58351 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58352 windows_path=`cmd //c echo $unix_path` 58353 freetype_obj_path="$windows_path" 58354 fi 58355 58356 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 58357 freetype_platform=x64 58358 else 58359 freetype_platform=win32 58360 fi 58361 58362 # The original freetype project file is for VS 2010 (i.e. 'v100'), 58363 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 58364 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 58365 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 58366 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 58367 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 58368 58369 # First we try to build the freetype.dll 58370 $ECHO -e "@echo off\n"\ 58371 "$MSBUILD $vcxproj_path "\ 58372 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 58373 "/p:Configuration=\"Release Multithreaded\" "\ 58374 "/p:Platform=$freetype_platform "\ 58375 "/p:ConfigurationType=DynamicLibrary "\ 58376 "/p:TargetName=freetype "\ 58377 "/p:OutDir=\"$freetype_lib_path\" "\ 58378 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 58379 cmd /c freetype.bat 58380 58381 if test -s "$freetype_lib_path_unix/freetype.dll"; then 58382 # If that succeeds we also build freetype.lib 58383 $ECHO -e "@echo off\n"\ 58384 "$MSBUILD $vcxproj_path "\ 58385 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 58386 "/p:Configuration=\"Release Multithreaded\" "\ 58387 "/p:Platform=$freetype_platform "\ 58388 "/p:ConfigurationType=StaticLibrary "\ 58389 "/p:TargetName=freetype "\ 58390 "/p:OutDir=\"$freetype_lib_path\" "\ 58391 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 58392 cmd /c freetype.bat 58393 58394 if test -s "$freetype_lib_path_unix/freetype.lib"; then 58395 # Once we build both, lib and dll, set freetype lib and include path appropriately 58396 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 58397 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 58398 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 58399 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 58400 else 58401 BUILD_FREETYPE=no 58402 fi 58403 else 58404 BUILD_FREETYPE=no 58405 fi 58406 fi 58407 58408 if test "x$BUILD_FREETYPE" = xyes; then 58409 # Okay, we built it. Check that it works. 58410 58411 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58412 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58413 METHOD="--with-freetype-src" 58414 58415 # Let's start with an optimistic view of the world :-) 58416 FOUND_FREETYPE=yes 58417 58418 # First look for the canonical freetype main include file ft2build.h. 58419 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58420 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58421 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58422 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58423 # Fail. 58424 FOUND_FREETYPE=no 58425 fi 58426 fi 58427 58428 if test "x$FOUND_FREETYPE" = xyes; then 58429 # Include file found, let's continue the sanity check. 58430 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58431 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58432 58433 # Reset to default value 58434 FREETYPE_BASE_NAME=freetype 58435 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58436 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58437 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58438 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58439 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58440 # for the .6 version explicitly. 58441 FREETYPE_BASE_NAME=freetype.6 58442 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58443 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58444 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58445 else 58446 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58447 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58448 FOUND_FREETYPE=no 58449 fi 58450 else 58451 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58452 # On Windows, we will need both .lib and .dll file. 58453 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58454 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58455 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58456 FOUND_FREETYPE=no 58457 fi 58458 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58459 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58460 # Found lib in isa dir, use that instead. 58461 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58462 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58463 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58464 fi 58465 fi 58466 fi 58467 58468 if test "x$FOUND_FREETYPE" = xyes; then 58469 58470 # Only process if variable expands to non-empty 58471 58472 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58473 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58474 58475 # Input might be given as Windows format, start by converting to 58476 # unix format. 58477 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58478 new_path=`$CYGPATH -u "$path"` 58479 58480 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58481 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58482 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58483 # "foo.exe" is OK but "foo" is an error. 58484 # 58485 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58486 # It is also a way to make sure we got the proper file name for the real test later on. 58487 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58488 if test "x$test_shortpath" = x; then 58489 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58490 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58491 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58492 fi 58493 58494 # Call helper function which possibly converts this using DOS-style short mode. 58495 # If so, the updated path is stored in $new_path. 58496 58497 input_path="$new_path" 58498 # Check if we need to convert this using DOS-style short mode. If the path 58499 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58500 # take no chances and rewrite it. 58501 # Note: m4 eats our [], so we need to use [ and ] instead. 58502 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58503 if test "x$has_forbidden_chars" != x; then 58504 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58505 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58506 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58507 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58508 # Going to short mode and back again did indeed matter. Since short mode is 58509 # case insensitive, let's make it lowercase to improve readability. 58510 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58511 # Now convert it back to Unix-style (cygpath) 58512 input_path=`$CYGPATH -u "$shortmode_path"` 58513 new_path="$input_path" 58514 fi 58515 fi 58516 58517 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58518 if test "x$test_cygdrive_prefix" = x; then 58519 # As a simple fix, exclude /usr/bin since it's not a real path. 58520 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58521 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58522 # a path prefixed by /cygdrive for fixpath to work. 58523 new_path="$CYGWIN_ROOT_PATH$input_path" 58524 fi 58525 fi 58526 58527 58528 if test "x$path" != "x$new_path"; then 58529 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58530 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58531 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58532 fi 58533 58534 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58535 58536 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58537 has_colon=`$ECHO $path | $GREP ^.:` 58538 new_path="$path" 58539 if test "x$has_colon" = x; then 58540 # Not in mixed or Windows style, start by that. 58541 new_path=`cmd //c echo $path` 58542 fi 58543 58544 58545 input_path="$new_path" 58546 # Check if we need to convert this using DOS-style short mode. If the path 58547 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58548 # take no chances and rewrite it. 58549 # Note: m4 eats our [], so we need to use [ and ] instead. 58550 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58551 if test "x$has_forbidden_chars" != x; then 58552 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58553 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58554 fi 58555 58556 58557 windows_path="$new_path" 58558 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58559 unix_path=`$CYGPATH -u "$windows_path"` 58560 new_path="$unix_path" 58561 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58562 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58563 new_path="$unix_path" 58564 fi 58565 58566 if test "x$path" != "x$new_path"; then 58567 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58568 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58569 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58570 fi 58571 58572 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58573 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58574 58575 else 58576 # We're on a unix platform. Hooray! :) 58577 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58578 has_space=`$ECHO "$path" | $GREP " "` 58579 if test "x$has_space" != x; then 58580 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58581 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58582 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58583 fi 58584 58585 # Use eval to expand a potential ~ 58586 eval path="$path" 58587 if test ! -f "$path" && test ! -d "$path"; then 58588 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58589 fi 58590 58591 if test -d "$path"; then 58592 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58593 else 58594 dir="`$DIRNAME "$path"`" 58595 base="`$BASENAME "$path"`" 58596 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58597 fi 58598 fi 58599 fi 58600 58601 58602 # Only process if variable expands to non-empty 58603 58604 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58605 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58606 58607 # Input might be given as Windows format, start by converting to 58608 # unix format. 58609 path="$POTENTIAL_FREETYPE_LIB_PATH" 58610 new_path=`$CYGPATH -u "$path"` 58611 58612 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58613 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58614 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58615 # "foo.exe" is OK but "foo" is an error. 58616 # 58617 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58618 # It is also a way to make sure we got the proper file name for the real test later on. 58619 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58620 if test "x$test_shortpath" = x; then 58621 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58622 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58623 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58624 fi 58625 58626 # Call helper function which possibly converts this using DOS-style short mode. 58627 # If so, the updated path is stored in $new_path. 58628 58629 input_path="$new_path" 58630 # Check if we need to convert this using DOS-style short mode. If the path 58631 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58632 # take no chances and rewrite it. 58633 # Note: m4 eats our [], so we need to use [ and ] instead. 58634 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58635 if test "x$has_forbidden_chars" != x; then 58636 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58637 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58638 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58639 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58640 # Going to short mode and back again did indeed matter. Since short mode is 58641 # case insensitive, let's make it lowercase to improve readability. 58642 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58643 # Now convert it back to Unix-style (cygpath) 58644 input_path=`$CYGPATH -u "$shortmode_path"` 58645 new_path="$input_path" 58646 fi 58647 fi 58648 58649 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58650 if test "x$test_cygdrive_prefix" = x; then 58651 # As a simple fix, exclude /usr/bin since it's not a real path. 58652 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58653 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58654 # a path prefixed by /cygdrive for fixpath to work. 58655 new_path="$CYGWIN_ROOT_PATH$input_path" 58656 fi 58657 fi 58658 58659 58660 if test "x$path" != "x$new_path"; then 58661 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58662 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58663 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58664 fi 58665 58666 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58667 58668 path="$POTENTIAL_FREETYPE_LIB_PATH" 58669 has_colon=`$ECHO $path | $GREP ^.:` 58670 new_path="$path" 58671 if test "x$has_colon" = x; then 58672 # Not in mixed or Windows style, start by that. 58673 new_path=`cmd //c echo $path` 58674 fi 58675 58676 58677 input_path="$new_path" 58678 # Check if we need to convert this using DOS-style short mode. If the path 58679 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58680 # take no chances and rewrite it. 58681 # Note: m4 eats our [], so we need to use [ and ] instead. 58682 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58683 if test "x$has_forbidden_chars" != x; then 58684 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58685 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58686 fi 58687 58688 58689 windows_path="$new_path" 58690 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58691 unix_path=`$CYGPATH -u "$windows_path"` 58692 new_path="$unix_path" 58693 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58694 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58695 new_path="$unix_path" 58696 fi 58697 58698 if test "x$path" != "x$new_path"; then 58699 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58700 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58701 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58702 fi 58703 58704 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58705 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58706 58707 else 58708 # We're on a unix platform. Hooray! :) 58709 path="$POTENTIAL_FREETYPE_LIB_PATH" 58710 has_space=`$ECHO "$path" | $GREP " "` 58711 if test "x$has_space" != x; then 58712 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58713 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58714 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58715 fi 58716 58717 # Use eval to expand a potential ~ 58718 eval path="$path" 58719 if test ! -f "$path" && test ! -d "$path"; then 58720 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58721 fi 58722 58723 if test -d "$path"; then 58724 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58725 else 58726 dir="`$DIRNAME "$path"`" 58727 base="`$BASENAME "$path"`" 58728 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58729 fi 58730 fi 58731 fi 58732 58733 58734 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58736 $as_echo_n "checking for freetype includes... " >&6; } 58737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58738 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58739 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58741 $as_echo_n "checking for freetype libraries... " >&6; } 58742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58743 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58744 fi 58745 58746 if test "x$FOUND_FREETYPE" != xyes; then 58747 as_fn_error $? "Can not use the built freetype at location given by --with-freetype-src" "$LINENO" 5 58748 fi 58749 else 58750 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&5 58751 $as_echo "$as_me: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&6;} 58752 as_fn_error $? "Consider building freetype manually and using --with-freetype instead." "$LINENO" 5 58753 fi 58754 else 58755 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&5 58756 $as_echo "$as_me: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&2;} 58757 fi 58758 fi 58759 58760 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 58761 # User has specified settings 58762 58763 if test "x$BUNDLE_FREETYPE" = x; then 58764 # If not specified, default is to bundle freetype 58765 BUNDLE_FREETYPE=yes 58766 fi 58767 58768 if test "x$with_freetype" != x; then 58769 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include" 58770 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib" 58771 fi 58772 58773 # Allow --with-freetype-lib and --with-freetype-include to override 58774 if test "x$with_freetype_include" != x; then 58775 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include" 58776 fi 58777 if test "x$with_freetype_lib" != x; then 58778 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib" 58779 fi 58780 58781 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58782 # Okay, we got it. Check that it works. 58783 58784 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58785 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58786 METHOD="--with-freetype" 58787 58788 # Let's start with an optimistic view of the world :-) 58789 FOUND_FREETYPE=yes 58790 58791 # First look for the canonical freetype main include file ft2build.h. 58792 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58793 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58794 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58795 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58796 # Fail. 58797 FOUND_FREETYPE=no 58798 fi 58799 fi 58800 58801 if test "x$FOUND_FREETYPE" = xyes; then 58802 # Include file found, let's continue the sanity check. 58803 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58804 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58805 58806 # Reset to default value 58807 FREETYPE_BASE_NAME=freetype 58808 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58809 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58810 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58811 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58812 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58813 # for the .6 version explicitly. 58814 FREETYPE_BASE_NAME=freetype.6 58815 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58816 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58817 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58818 else 58819 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58820 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58821 FOUND_FREETYPE=no 58822 fi 58823 else 58824 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58825 # On Windows, we will need both .lib and .dll file. 58826 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58827 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58828 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58829 FOUND_FREETYPE=no 58830 fi 58831 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58832 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58833 # Found lib in isa dir, use that instead. 58834 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58835 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58836 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58837 fi 58838 fi 58839 fi 58840 58841 if test "x$FOUND_FREETYPE" = xyes; then 58842 58843 # Only process if variable expands to non-empty 58844 58845 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58846 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58847 58848 # Input might be given as Windows format, start by converting to 58849 # unix format. 58850 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58851 new_path=`$CYGPATH -u "$path"` 58852 58853 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58854 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58855 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58856 # "foo.exe" is OK but "foo" is an error. 58857 # 58858 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58859 # It is also a way to make sure we got the proper file name for the real test later on. 58860 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58861 if test "x$test_shortpath" = x; then 58862 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58863 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58864 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58865 fi 58866 58867 # Call helper function which possibly converts this using DOS-style short mode. 58868 # If so, the updated path is stored in $new_path. 58869 58870 input_path="$new_path" 58871 # Check if we need to convert this using DOS-style short mode. If the path 58872 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58873 # take no chances and rewrite it. 58874 # Note: m4 eats our [], so we need to use [ and ] instead. 58875 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58876 if test "x$has_forbidden_chars" != x; then 58877 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58878 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58879 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58880 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58881 # Going to short mode and back again did indeed matter. Since short mode is 58882 # case insensitive, let's make it lowercase to improve readability. 58883 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58884 # Now convert it back to Unix-style (cygpath) 58885 input_path=`$CYGPATH -u "$shortmode_path"` 58886 new_path="$input_path" 58887 fi 58888 fi 58889 58890 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58891 if test "x$test_cygdrive_prefix" = x; then 58892 # As a simple fix, exclude /usr/bin since it's not a real path. 58893 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58894 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58895 # a path prefixed by /cygdrive for fixpath to work. 58896 new_path="$CYGWIN_ROOT_PATH$input_path" 58897 fi 58898 fi 58899 58900 58901 if test "x$path" != "x$new_path"; then 58902 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58903 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58904 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58905 fi 58906 58907 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58908 58909 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58910 has_colon=`$ECHO $path | $GREP ^.:` 58911 new_path="$path" 58912 if test "x$has_colon" = x; then 58913 # Not in mixed or Windows style, start by that. 58914 new_path=`cmd //c echo $path` 58915 fi 58916 58917 58918 input_path="$new_path" 58919 # Check if we need to convert this using DOS-style short mode. If the path 58920 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58921 # take no chances and rewrite it. 58922 # Note: m4 eats our [], so we need to use [ and ] instead. 58923 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58924 if test "x$has_forbidden_chars" != x; then 58925 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58926 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58927 fi 58928 58929 58930 windows_path="$new_path" 58931 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58932 unix_path=`$CYGPATH -u "$windows_path"` 58933 new_path="$unix_path" 58934 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58935 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58936 new_path="$unix_path" 58937 fi 58938 58939 if test "x$path" != "x$new_path"; then 58940 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58941 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58942 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58943 fi 58944 58945 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58946 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58947 58948 else 58949 # We're on a unix platform. Hooray! :) 58950 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58951 has_space=`$ECHO "$path" | $GREP " "` 58952 if test "x$has_space" != x; then 58953 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58954 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58955 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58956 fi 58957 58958 # Use eval to expand a potential ~ 58959 eval path="$path" 58960 if test ! -f "$path" && test ! -d "$path"; then 58961 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58962 fi 58963 58964 if test -d "$path"; then 58965 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58966 else 58967 dir="`$DIRNAME "$path"`" 58968 base="`$BASENAME "$path"`" 58969 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58970 fi 58971 fi 58972 fi 58973 58974 58975 # Only process if variable expands to non-empty 58976 58977 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58978 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58979 58980 # Input might be given as Windows format, start by converting to 58981 # unix format. 58982 path="$POTENTIAL_FREETYPE_LIB_PATH" 58983 new_path=`$CYGPATH -u "$path"` 58984 58985 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58986 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58987 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58988 # "foo.exe" is OK but "foo" is an error. 58989 # 58990 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58991 # It is also a way to make sure we got the proper file name for the real test later on. 58992 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58993 if test "x$test_shortpath" = x; then 58994 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58995 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58996 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58997 fi 58998 58999 # Call helper function which possibly converts this using DOS-style short mode. 59000 # If so, the updated path is stored in $new_path. 59001 59002 input_path="$new_path" 59003 # Check if we need to convert this using DOS-style short mode. If the path 59004 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59005 # take no chances and rewrite it. 59006 # Note: m4 eats our [], so we need to use [ and ] instead. 59007 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59008 if test "x$has_forbidden_chars" != x; then 59009 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59010 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59011 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59012 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59013 # Going to short mode and back again did indeed matter. Since short mode is 59014 # case insensitive, let's make it lowercase to improve readability. 59015 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59016 # Now convert it back to Unix-style (cygpath) 59017 input_path=`$CYGPATH -u "$shortmode_path"` 59018 new_path="$input_path" 59019 fi 59020 fi 59021 59022 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59023 if test "x$test_cygdrive_prefix" = x; then 59024 # As a simple fix, exclude /usr/bin since it's not a real path. 59025 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59026 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59027 # a path prefixed by /cygdrive for fixpath to work. 59028 new_path="$CYGWIN_ROOT_PATH$input_path" 59029 fi 59030 fi 59031 59032 59033 if test "x$path" != "x$new_path"; then 59034 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59035 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59036 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59037 fi 59038 59039 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59040 59041 path="$POTENTIAL_FREETYPE_LIB_PATH" 59042 has_colon=`$ECHO $path | $GREP ^.:` 59043 new_path="$path" 59044 if test "x$has_colon" = x; then 59045 # Not in mixed or Windows style, start by that. 59046 new_path=`cmd //c echo $path` 59047 fi 59048 59049 59050 input_path="$new_path" 59051 # Check if we need to convert this using DOS-style short mode. If the path 59052 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59053 # take no chances and rewrite it. 59054 # Note: m4 eats our [], so we need to use [ and ] instead. 59055 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59056 if test "x$has_forbidden_chars" != x; then 59057 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59058 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59059 fi 59060 59061 59062 windows_path="$new_path" 59063 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59064 unix_path=`$CYGPATH -u "$windows_path"` 59065 new_path="$unix_path" 59066 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59067 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59068 new_path="$unix_path" 59069 fi 59070 59071 if test "x$path" != "x$new_path"; then 59072 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59073 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59074 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59075 fi 59076 59077 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59078 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59079 59080 else 59081 # We're on a unix platform. Hooray! :) 59082 path="$POTENTIAL_FREETYPE_LIB_PATH" 59083 has_space=`$ECHO "$path" | $GREP " "` 59084 if test "x$has_space" != x; then 59085 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59086 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59087 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59088 fi 59089 59090 # Use eval to expand a potential ~ 59091 eval path="$path" 59092 if test ! -f "$path" && test ! -d "$path"; then 59093 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59094 fi 59095 59096 if test -d "$path"; then 59097 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59098 else 59099 dir="`$DIRNAME "$path"`" 59100 base="`$BASENAME "$path"`" 59101 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59102 fi 59103 fi 59104 fi 59105 59106 59107 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59109 $as_echo_n "checking for freetype includes... " >&6; } 59110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59111 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59112 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59114 $as_echo_n "checking for freetype libraries... " >&6; } 59115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59116 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59117 fi 59118 59119 if test "x$FOUND_FREETYPE" != xyes; then 59120 as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5 59121 fi 59122 else 59123 # User specified only one of lib or include. This is an error. 59124 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then 59125 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5 59126 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;} 59127 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 59128 else 59129 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5 59130 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;} 59131 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 59132 fi 59133 fi 59134 else 59135 # User did not specify settings, but we need freetype. Try to locate it. 59136 59137 if test "x$BUNDLE_FREETYPE" = x; then 59138 # If not specified, default is to bundle freetype only on windows 59139 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59140 BUNDLE_FREETYPE=yes 59141 else 59142 BUNDLE_FREETYPE=no 59143 fi 59144 fi 59145 59146 # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config. 59147 if test "x$SYSROOT" = x; then 59148 if test "x$FOUND_FREETYPE" != xyes; then 59149 # Check modules using pkg-config, but only if we have it (ugly output results otherwise) 59150 if test "x$PKG_CONFIG" != x; then 59151 59152 pkg_failed=no 59153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5 59154 $as_echo_n "checking for FREETYPE... " >&6; } 59155 59156 if test -n "$FREETYPE_CFLAGS"; then 59157 pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS" 59158 elif test -n "$PKG_CONFIG"; then 59159 if test -n "$PKG_CONFIG" && \ 59160 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 59161 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 59162 ac_status=$? 59163 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 59164 test $ac_status = 0; }; then 59165 pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 59166 else 59167 pkg_failed=yes 59168 fi 59169 else 59170 pkg_failed=untried 59171 fi 59172 if test -n "$FREETYPE_LIBS"; then 59173 pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS" 59174 elif test -n "$PKG_CONFIG"; then 59175 if test -n "$PKG_CONFIG" && \ 59176 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 59177 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 59178 ac_status=$? 59179 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 59180 test $ac_status = 0; }; then 59181 pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 59182 else 59183 pkg_failed=yes 59184 fi 59185 else 59186 pkg_failed=untried 59187 fi 59188 59189 59190 59191 if test $pkg_failed = yes; then 59192 59193 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 59194 _pkg_short_errors_supported=yes 59195 else 59196 _pkg_short_errors_supported=no 59197 fi 59198 if test $_pkg_short_errors_supported = yes; then 59199 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 59200 else 59201 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 59202 fi 59203 # Put the nasty error message in config.log where it belongs 59204 echo "$FREETYPE_PKG_ERRORS" >&5 59205 59206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59207 $as_echo "no" >&6; } 59208 FOUND_FREETYPE=no 59209 elif test $pkg_failed = untried; then 59210 FOUND_FREETYPE=no 59211 else 59212 FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS 59213 FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS 59214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 59215 $as_echo "yes" >&6; } 59216 FOUND_FREETYPE=yes 59217 fi 59218 if test "x$FOUND_FREETYPE" = xyes; then 59219 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 59220 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'` 59221 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 59222 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 59223 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'` 59224 fi 59225 # PKG_CHECK_MODULES will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling. 59226 if test "x$BUNDLE_FREETYPE" = xyes; then 59227 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5 59228 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;} 59229 FOUND_FREETYPE=no 59230 else 59231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5 59232 $as_echo_n "checking for freetype... " >&6; } 59233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5 59234 $as_echo "yes (using pkg-config)" >&6; } 59235 fi 59236 fi 59237 fi 59238 fi 59239 fi 59240 59241 if test "x$FOUND_FREETYPE" != xyes; then 59242 # Check in well-known locations 59243 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59244 FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32" 59245 59246 windows_path="$FREETYPE_BASE_DIR" 59247 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59248 unix_path=`$CYGPATH -u "$windows_path"` 59249 FREETYPE_BASE_DIR="$unix_path" 59250 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59251 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59252 FREETYPE_BASE_DIR="$unix_path" 59253 fi 59254 59255 59256 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59257 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 59258 METHOD="well-known location" 59259 59260 # Let's start with an optimistic view of the world :-) 59261 FOUND_FREETYPE=yes 59262 59263 # First look for the canonical freetype main include file ft2build.h. 59264 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59265 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59266 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59267 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59268 # Fail. 59269 FOUND_FREETYPE=no 59270 fi 59271 fi 59272 59273 if test "x$FOUND_FREETYPE" = xyes; then 59274 # Include file found, let's continue the sanity check. 59275 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59276 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59277 59278 # Reset to default value 59279 FREETYPE_BASE_NAME=freetype 59280 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59281 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59282 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59283 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59284 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59285 # for the .6 version explicitly. 59286 FREETYPE_BASE_NAME=freetype.6 59287 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59288 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59289 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59290 else 59291 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59292 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59293 FOUND_FREETYPE=no 59294 fi 59295 else 59296 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59297 # On Windows, we will need both .lib and .dll file. 59298 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59299 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59300 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59301 FOUND_FREETYPE=no 59302 fi 59303 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59304 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59305 # Found lib in isa dir, use that instead. 59306 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59307 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59308 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59309 fi 59310 fi 59311 fi 59312 59313 if test "x$FOUND_FREETYPE" = xyes; then 59314 59315 # Only process if variable expands to non-empty 59316 59317 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59318 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59319 59320 # Input might be given as Windows format, start by converting to 59321 # unix format. 59322 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59323 new_path=`$CYGPATH -u "$path"` 59324 59325 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59326 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59327 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59328 # "foo.exe" is OK but "foo" is an error. 59329 # 59330 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59331 # It is also a way to make sure we got the proper file name for the real test later on. 59332 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59333 if test "x$test_shortpath" = x; then 59334 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59335 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59336 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59337 fi 59338 59339 # Call helper function which possibly converts this using DOS-style short mode. 59340 # If so, the updated path is stored in $new_path. 59341 59342 input_path="$new_path" 59343 # Check if we need to convert this using DOS-style short mode. If the path 59344 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59345 # take no chances and rewrite it. 59346 # Note: m4 eats our [], so we need to use [ and ] instead. 59347 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59348 if test "x$has_forbidden_chars" != x; then 59349 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59350 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59351 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59352 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59353 # Going to short mode and back again did indeed matter. Since short mode is 59354 # case insensitive, let's make it lowercase to improve readability. 59355 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59356 # Now convert it back to Unix-style (cygpath) 59357 input_path=`$CYGPATH -u "$shortmode_path"` 59358 new_path="$input_path" 59359 fi 59360 fi 59361 59362 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59363 if test "x$test_cygdrive_prefix" = x; then 59364 # As a simple fix, exclude /usr/bin since it's not a real path. 59365 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59366 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59367 # a path prefixed by /cygdrive for fixpath to work. 59368 new_path="$CYGWIN_ROOT_PATH$input_path" 59369 fi 59370 fi 59371 59372 59373 if test "x$path" != "x$new_path"; then 59374 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59375 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59376 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59377 fi 59378 59379 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59380 59381 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59382 has_colon=`$ECHO $path | $GREP ^.:` 59383 new_path="$path" 59384 if test "x$has_colon" = x; then 59385 # Not in mixed or Windows style, start by that. 59386 new_path=`cmd //c echo $path` 59387 fi 59388 59389 59390 input_path="$new_path" 59391 # Check if we need to convert this using DOS-style short mode. If the path 59392 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59393 # take no chances and rewrite it. 59394 # Note: m4 eats our [], so we need to use [ and ] instead. 59395 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59396 if test "x$has_forbidden_chars" != x; then 59397 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59398 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59399 fi 59400 59401 59402 windows_path="$new_path" 59403 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59404 unix_path=`$CYGPATH -u "$windows_path"` 59405 new_path="$unix_path" 59406 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59407 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59408 new_path="$unix_path" 59409 fi 59410 59411 if test "x$path" != "x$new_path"; then 59412 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59413 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59414 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59415 fi 59416 59417 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59418 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59419 59420 else 59421 # We're on a unix platform. Hooray! :) 59422 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59423 has_space=`$ECHO "$path" | $GREP " "` 59424 if test "x$has_space" != x; then 59425 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59426 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59427 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59428 fi 59429 59430 # Use eval to expand a potential ~ 59431 eval path="$path" 59432 if test ! -f "$path" && test ! -d "$path"; then 59433 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59434 fi 59435 59436 if test -d "$path"; then 59437 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59438 else 59439 dir="`$DIRNAME "$path"`" 59440 base="`$BASENAME "$path"`" 59441 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59442 fi 59443 fi 59444 fi 59445 59446 59447 # Only process if variable expands to non-empty 59448 59449 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59450 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59451 59452 # Input might be given as Windows format, start by converting to 59453 # unix format. 59454 path="$POTENTIAL_FREETYPE_LIB_PATH" 59455 new_path=`$CYGPATH -u "$path"` 59456 59457 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59458 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59459 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59460 # "foo.exe" is OK but "foo" is an error. 59461 # 59462 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59463 # It is also a way to make sure we got the proper file name for the real test later on. 59464 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59465 if test "x$test_shortpath" = x; then 59466 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59467 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59468 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59469 fi 59470 59471 # Call helper function which possibly converts this using DOS-style short mode. 59472 # If so, the updated path is stored in $new_path. 59473 59474 input_path="$new_path" 59475 # Check if we need to convert this using DOS-style short mode. If the path 59476 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59477 # take no chances and rewrite it. 59478 # Note: m4 eats our [], so we need to use [ and ] instead. 59479 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59480 if test "x$has_forbidden_chars" != x; then 59481 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59482 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59483 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59484 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59485 # Going to short mode and back again did indeed matter. Since short mode is 59486 # case insensitive, let's make it lowercase to improve readability. 59487 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59488 # Now convert it back to Unix-style (cygpath) 59489 input_path=`$CYGPATH -u "$shortmode_path"` 59490 new_path="$input_path" 59491 fi 59492 fi 59493 59494 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59495 if test "x$test_cygdrive_prefix" = x; then 59496 # As a simple fix, exclude /usr/bin since it's not a real path. 59497 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59498 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59499 # a path prefixed by /cygdrive for fixpath to work. 59500 new_path="$CYGWIN_ROOT_PATH$input_path" 59501 fi 59502 fi 59503 59504 59505 if test "x$path" != "x$new_path"; then 59506 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59507 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59508 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59509 fi 59510 59511 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59512 59513 path="$POTENTIAL_FREETYPE_LIB_PATH" 59514 has_colon=`$ECHO $path | $GREP ^.:` 59515 new_path="$path" 59516 if test "x$has_colon" = x; then 59517 # Not in mixed or Windows style, start by that. 59518 new_path=`cmd //c echo $path` 59519 fi 59520 59521 59522 input_path="$new_path" 59523 # Check if we need to convert this using DOS-style short mode. If the path 59524 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59525 # take no chances and rewrite it. 59526 # Note: m4 eats our [], so we need to use [ and ] instead. 59527 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59528 if test "x$has_forbidden_chars" != x; then 59529 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59530 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59531 fi 59532 59533 59534 windows_path="$new_path" 59535 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59536 unix_path=`$CYGPATH -u "$windows_path"` 59537 new_path="$unix_path" 59538 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59539 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59540 new_path="$unix_path" 59541 fi 59542 59543 if test "x$path" != "x$new_path"; then 59544 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59545 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59546 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59547 fi 59548 59549 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59550 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59551 59552 else 59553 # We're on a unix platform. Hooray! :) 59554 path="$POTENTIAL_FREETYPE_LIB_PATH" 59555 has_space=`$ECHO "$path" | $GREP " "` 59556 if test "x$has_space" != x; then 59557 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59558 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59559 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59560 fi 59561 59562 # Use eval to expand a potential ~ 59563 eval path="$path" 59564 if test ! -f "$path" && test ! -d "$path"; then 59565 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59566 fi 59567 59568 if test -d "$path"; then 59569 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59570 else 59571 dir="`$DIRNAME "$path"`" 59572 base="`$BASENAME "$path"`" 59573 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59574 fi 59575 fi 59576 fi 59577 59578 59579 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59581 $as_echo_n "checking for freetype includes... " >&6; } 59582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59583 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59584 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59586 $as_echo_n "checking for freetype libraries... " >&6; } 59587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59588 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59589 fi 59590 59591 if test "x$FOUND_FREETYPE" != xyes; then 59592 FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32" 59593 59594 windows_path="$FREETYPE_BASE_DIR" 59595 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59596 unix_path=`$CYGPATH -u "$windows_path"` 59597 FREETYPE_BASE_DIR="$unix_path" 59598 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59599 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59600 FREETYPE_BASE_DIR="$unix_path" 59601 fi 59602 59603 59604 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59605 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 59606 METHOD="well-known location" 59607 59608 # Let's start with an optimistic view of the world :-) 59609 FOUND_FREETYPE=yes 59610 59611 # First look for the canonical freetype main include file ft2build.h. 59612 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59613 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59614 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59615 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59616 # Fail. 59617 FOUND_FREETYPE=no 59618 fi 59619 fi 59620 59621 if test "x$FOUND_FREETYPE" = xyes; then 59622 # Include file found, let's continue the sanity check. 59623 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59624 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59625 59626 # Reset to default value 59627 FREETYPE_BASE_NAME=freetype 59628 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59629 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59630 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59631 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59632 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59633 # for the .6 version explicitly. 59634 FREETYPE_BASE_NAME=freetype.6 59635 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59636 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59637 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59638 else 59639 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59640 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59641 FOUND_FREETYPE=no 59642 fi 59643 else 59644 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59645 # On Windows, we will need both .lib and .dll file. 59646 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59647 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59648 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59649 FOUND_FREETYPE=no 59650 fi 59651 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59652 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59653 # Found lib in isa dir, use that instead. 59654 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59655 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59656 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59657 fi 59658 fi 59659 fi 59660 59661 if test "x$FOUND_FREETYPE" = xyes; then 59662 59663 # Only process if variable expands to non-empty 59664 59665 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59666 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59667 59668 # Input might be given as Windows format, start by converting to 59669 # unix format. 59670 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59671 new_path=`$CYGPATH -u "$path"` 59672 59673 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59674 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59675 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59676 # "foo.exe" is OK but "foo" is an error. 59677 # 59678 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59679 # It is also a way to make sure we got the proper file name for the real test later on. 59680 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59681 if test "x$test_shortpath" = x; then 59682 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59683 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59684 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59685 fi 59686 59687 # Call helper function which possibly converts this using DOS-style short mode. 59688 # If so, the updated path is stored in $new_path. 59689 59690 input_path="$new_path" 59691 # Check if we need to convert this using DOS-style short mode. If the path 59692 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59693 # take no chances and rewrite it. 59694 # Note: m4 eats our [], so we need to use [ and ] instead. 59695 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59696 if test "x$has_forbidden_chars" != x; then 59697 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59698 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59699 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59700 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59701 # Going to short mode and back again did indeed matter. Since short mode is 59702 # case insensitive, let's make it lowercase to improve readability. 59703 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59704 # Now convert it back to Unix-style (cygpath) 59705 input_path=`$CYGPATH -u "$shortmode_path"` 59706 new_path="$input_path" 59707 fi 59708 fi 59709 59710 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59711 if test "x$test_cygdrive_prefix" = x; then 59712 # As a simple fix, exclude /usr/bin since it's not a real path. 59713 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59714 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59715 # a path prefixed by /cygdrive for fixpath to work. 59716 new_path="$CYGWIN_ROOT_PATH$input_path" 59717 fi 59718 fi 59719 59720 59721 if test "x$path" != "x$new_path"; then 59722 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59723 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59724 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59725 fi 59726 59727 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59728 59729 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59730 has_colon=`$ECHO $path | $GREP ^.:` 59731 new_path="$path" 59732 if test "x$has_colon" = x; then 59733 # Not in mixed or Windows style, start by that. 59734 new_path=`cmd //c echo $path` 59735 fi 59736 59737 59738 input_path="$new_path" 59739 # Check if we need to convert this using DOS-style short mode. If the path 59740 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59741 # take no chances and rewrite it. 59742 # Note: m4 eats our [], so we need to use [ and ] instead. 59743 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59744 if test "x$has_forbidden_chars" != x; then 59745 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59746 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59747 fi 59748 59749 59750 windows_path="$new_path" 59751 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59752 unix_path=`$CYGPATH -u "$windows_path"` 59753 new_path="$unix_path" 59754 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59755 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59756 new_path="$unix_path" 59757 fi 59758 59759 if test "x$path" != "x$new_path"; then 59760 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59761 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59762 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59763 fi 59764 59765 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59766 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59767 59768 else 59769 # We're on a unix platform. Hooray! :) 59770 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59771 has_space=`$ECHO "$path" | $GREP " "` 59772 if test "x$has_space" != x; then 59773 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59774 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59775 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59776 fi 59777 59778 # Use eval to expand a potential ~ 59779 eval path="$path" 59780 if test ! -f "$path" && test ! -d "$path"; then 59781 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59782 fi 59783 59784 if test -d "$path"; then 59785 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59786 else 59787 dir="`$DIRNAME "$path"`" 59788 base="`$BASENAME "$path"`" 59789 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59790 fi 59791 fi 59792 fi 59793 59794 59795 # Only process if variable expands to non-empty 59796 59797 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59798 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59799 59800 # Input might be given as Windows format, start by converting to 59801 # unix format. 59802 path="$POTENTIAL_FREETYPE_LIB_PATH" 59803 new_path=`$CYGPATH -u "$path"` 59804 59805 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59806 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59807 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59808 # "foo.exe" is OK but "foo" is an error. 59809 # 59810 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59811 # It is also a way to make sure we got the proper file name for the real test later on. 59812 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59813 if test "x$test_shortpath" = x; then 59814 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59815 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59816 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59817 fi 59818 59819 # Call helper function which possibly converts this using DOS-style short mode. 59820 # If so, the updated path is stored in $new_path. 59821 59822 input_path="$new_path" 59823 # Check if we need to convert this using DOS-style short mode. If the path 59824 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59825 # take no chances and rewrite it. 59826 # Note: m4 eats our [], so we need to use [ and ] instead. 59827 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59828 if test "x$has_forbidden_chars" != x; then 59829 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59830 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59831 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59832 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59833 # Going to short mode and back again did indeed matter. Since short mode is 59834 # case insensitive, let's make it lowercase to improve readability. 59835 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59836 # Now convert it back to Unix-style (cygpath) 59837 input_path=`$CYGPATH -u "$shortmode_path"` 59838 new_path="$input_path" 59839 fi 59840 fi 59841 59842 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59843 if test "x$test_cygdrive_prefix" = x; then 59844 # As a simple fix, exclude /usr/bin since it's not a real path. 59845 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59846 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59847 # a path prefixed by /cygdrive for fixpath to work. 59848 new_path="$CYGWIN_ROOT_PATH$input_path" 59849 fi 59850 fi 59851 59852 59853 if test "x$path" != "x$new_path"; then 59854 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59855 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59856 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59857 fi 59858 59859 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59860 59861 path="$POTENTIAL_FREETYPE_LIB_PATH" 59862 has_colon=`$ECHO $path | $GREP ^.:` 59863 new_path="$path" 59864 if test "x$has_colon" = x; then 59865 # Not in mixed or Windows style, start by that. 59866 new_path=`cmd //c echo $path` 59867 fi 59868 59869 59870 input_path="$new_path" 59871 # Check if we need to convert this using DOS-style short mode. If the path 59872 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59873 # take no chances and rewrite it. 59874 # Note: m4 eats our [], so we need to use [ and ] instead. 59875 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59876 if test "x$has_forbidden_chars" != x; then 59877 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59878 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59879 fi 59880 59881 59882 windows_path="$new_path" 59883 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59884 unix_path=`$CYGPATH -u "$windows_path"` 59885 new_path="$unix_path" 59886 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59887 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59888 new_path="$unix_path" 59889 fi 59890 59891 if test "x$path" != "x$new_path"; then 59892 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59893 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59894 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59895 fi 59896 59897 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59898 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59899 59900 else 59901 # We're on a unix platform. Hooray! :) 59902 path="$POTENTIAL_FREETYPE_LIB_PATH" 59903 has_space=`$ECHO "$path" | $GREP " "` 59904 if test "x$has_space" != x; then 59905 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59906 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59907 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59908 fi 59909 59910 # Use eval to expand a potential ~ 59911 eval path="$path" 59912 if test ! -f "$path" && test ! -d "$path"; then 59913 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59914 fi 59915 59916 if test -d "$path"; then 59917 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59918 else 59919 dir="`$DIRNAME "$path"`" 59920 base="`$BASENAME "$path"`" 59921 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59922 fi 59923 fi 59924 fi 59925 59926 59927 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59929 $as_echo_n "checking for freetype includes... " >&6; } 59930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59931 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59932 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59934 $as_echo_n "checking for freetype libraries... " >&6; } 59935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59936 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59937 fi 59938 59939 fi 59940 if test "x$FOUND_FREETYPE" != xyes; then 59941 FREETYPE_BASE_DIR="$HOME/freetype" 59942 59943 windows_path="$FREETYPE_BASE_DIR" 59944 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59945 unix_path=`$CYGPATH -u "$windows_path"` 59946 FREETYPE_BASE_DIR="$unix_path" 59947 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59948 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59949 FREETYPE_BASE_DIR="$unix_path" 59950 fi 59951 59952 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59953 59954 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59955 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 59956 METHOD="well-known location" 59957 59958 # Let's start with an optimistic view of the world :-) 59959 FOUND_FREETYPE=yes 59960 59961 # First look for the canonical freetype main include file ft2build.h. 59962 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59963 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59964 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59965 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59966 # Fail. 59967 FOUND_FREETYPE=no 59968 fi 59969 fi 59970 59971 if test "x$FOUND_FREETYPE" = xyes; then 59972 # Include file found, let's continue the sanity check. 59973 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59974 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59975 59976 # Reset to default value 59977 FREETYPE_BASE_NAME=freetype 59978 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59979 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59980 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59981 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59982 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59983 # for the .6 version explicitly. 59984 FREETYPE_BASE_NAME=freetype.6 59985 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59986 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59987 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59988 else 59989 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59990 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59991 FOUND_FREETYPE=no 59992 fi 59993 else 59994 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59995 # On Windows, we will need both .lib and .dll file. 59996 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59997 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59998 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59999 FOUND_FREETYPE=no 60000 fi 60001 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60002 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60003 # Found lib in isa dir, use that instead. 60004 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60005 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60006 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60007 fi 60008 fi 60009 fi 60010 60011 if test "x$FOUND_FREETYPE" = xyes; then 60012 60013 # Only process if variable expands to non-empty 60014 60015 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60016 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60017 60018 # Input might be given as Windows format, start by converting to 60019 # unix format. 60020 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60021 new_path=`$CYGPATH -u "$path"` 60022 60023 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60024 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60025 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60026 # "foo.exe" is OK but "foo" is an error. 60027 # 60028 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60029 # It is also a way to make sure we got the proper file name for the real test later on. 60030 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60031 if test "x$test_shortpath" = x; then 60032 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60033 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60034 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60035 fi 60036 60037 # Call helper function which possibly converts this using DOS-style short mode. 60038 # If so, the updated path is stored in $new_path. 60039 60040 input_path="$new_path" 60041 # Check if we need to convert this using DOS-style short mode. If the path 60042 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60043 # take no chances and rewrite it. 60044 # Note: m4 eats our [], so we need to use [ and ] instead. 60045 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60046 if test "x$has_forbidden_chars" != x; then 60047 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60048 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60049 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60050 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60051 # Going to short mode and back again did indeed matter. Since short mode is 60052 # case insensitive, let's make it lowercase to improve readability. 60053 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60054 # Now convert it back to Unix-style (cygpath) 60055 input_path=`$CYGPATH -u "$shortmode_path"` 60056 new_path="$input_path" 60057 fi 60058 fi 60059 60060 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60061 if test "x$test_cygdrive_prefix" = x; then 60062 # As a simple fix, exclude /usr/bin since it's not a real path. 60063 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60064 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60065 # a path prefixed by /cygdrive for fixpath to work. 60066 new_path="$CYGWIN_ROOT_PATH$input_path" 60067 fi 60068 fi 60069 60070 60071 if test "x$path" != "x$new_path"; then 60072 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60073 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60074 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60075 fi 60076 60077 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60078 60079 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60080 has_colon=`$ECHO $path | $GREP ^.:` 60081 new_path="$path" 60082 if test "x$has_colon" = x; then 60083 # Not in mixed or Windows style, start by that. 60084 new_path=`cmd //c echo $path` 60085 fi 60086 60087 60088 input_path="$new_path" 60089 # Check if we need to convert this using DOS-style short mode. If the path 60090 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60091 # take no chances and rewrite it. 60092 # Note: m4 eats our [], so we need to use [ and ] instead. 60093 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60094 if test "x$has_forbidden_chars" != x; then 60095 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60096 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60097 fi 60098 60099 60100 windows_path="$new_path" 60101 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60102 unix_path=`$CYGPATH -u "$windows_path"` 60103 new_path="$unix_path" 60104 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60105 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60106 new_path="$unix_path" 60107 fi 60108 60109 if test "x$path" != "x$new_path"; then 60110 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60111 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60112 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60113 fi 60114 60115 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60116 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60117 60118 else 60119 # We're on a unix platform. Hooray! :) 60120 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60121 has_space=`$ECHO "$path" | $GREP " "` 60122 if test "x$has_space" != x; then 60123 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60124 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60125 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60126 fi 60127 60128 # Use eval to expand a potential ~ 60129 eval path="$path" 60130 if test ! -f "$path" && test ! -d "$path"; then 60131 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60132 fi 60133 60134 if test -d "$path"; then 60135 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60136 else 60137 dir="`$DIRNAME "$path"`" 60138 base="`$BASENAME "$path"`" 60139 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60140 fi 60141 fi 60142 fi 60143 60144 60145 # Only process if variable expands to non-empty 60146 60147 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60148 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60149 60150 # Input might be given as Windows format, start by converting to 60151 # unix format. 60152 path="$POTENTIAL_FREETYPE_LIB_PATH" 60153 new_path=`$CYGPATH -u "$path"` 60154 60155 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60156 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60157 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60158 # "foo.exe" is OK but "foo" is an error. 60159 # 60160 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60161 # It is also a way to make sure we got the proper file name for the real test later on. 60162 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60163 if test "x$test_shortpath" = x; then 60164 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60165 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60166 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60167 fi 60168 60169 # Call helper function which possibly converts this using DOS-style short mode. 60170 # If so, the updated path is stored in $new_path. 60171 60172 input_path="$new_path" 60173 # Check if we need to convert this using DOS-style short mode. If the path 60174 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60175 # take no chances and rewrite it. 60176 # Note: m4 eats our [], so we need to use [ and ] instead. 60177 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60178 if test "x$has_forbidden_chars" != x; then 60179 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60180 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60181 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60182 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60183 # Going to short mode and back again did indeed matter. Since short mode is 60184 # case insensitive, let's make it lowercase to improve readability. 60185 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60186 # Now convert it back to Unix-style (cygpath) 60187 input_path=`$CYGPATH -u "$shortmode_path"` 60188 new_path="$input_path" 60189 fi 60190 fi 60191 60192 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60193 if test "x$test_cygdrive_prefix" = x; then 60194 # As a simple fix, exclude /usr/bin since it's not a real path. 60195 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60196 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60197 # a path prefixed by /cygdrive for fixpath to work. 60198 new_path="$CYGWIN_ROOT_PATH$input_path" 60199 fi 60200 fi 60201 60202 60203 if test "x$path" != "x$new_path"; then 60204 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60205 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60206 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60207 fi 60208 60209 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60210 60211 path="$POTENTIAL_FREETYPE_LIB_PATH" 60212 has_colon=`$ECHO $path | $GREP ^.:` 60213 new_path="$path" 60214 if test "x$has_colon" = x; then 60215 # Not in mixed or Windows style, start by that. 60216 new_path=`cmd //c echo $path` 60217 fi 60218 60219 60220 input_path="$new_path" 60221 # Check if we need to convert this using DOS-style short mode. If the path 60222 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60223 # take no chances and rewrite it. 60224 # Note: m4 eats our [], so we need to use [ and ] instead. 60225 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60226 if test "x$has_forbidden_chars" != x; then 60227 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60228 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60229 fi 60230 60231 60232 windows_path="$new_path" 60233 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60234 unix_path=`$CYGPATH -u "$windows_path"` 60235 new_path="$unix_path" 60236 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60237 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60238 new_path="$unix_path" 60239 fi 60240 60241 if test "x$path" != "x$new_path"; then 60242 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60243 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60244 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60245 fi 60246 60247 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60248 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60249 60250 else 60251 # We're on a unix platform. Hooray! :) 60252 path="$POTENTIAL_FREETYPE_LIB_PATH" 60253 has_space=`$ECHO "$path" | $GREP " "` 60254 if test "x$has_space" != x; then 60255 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60256 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60257 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60258 fi 60259 60260 # Use eval to expand a potential ~ 60261 eval path="$path" 60262 if test ! -f "$path" && test ! -d "$path"; then 60263 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60264 fi 60265 60266 if test -d "$path"; then 60267 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60268 else 60269 dir="`$DIRNAME "$path"`" 60270 base="`$BASENAME "$path"`" 60271 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60272 fi 60273 fi 60274 fi 60275 60276 60277 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60279 $as_echo_n "checking for freetype includes... " >&6; } 60280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60281 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60282 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60284 $as_echo_n "checking for freetype libraries... " >&6; } 60285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60286 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60287 fi 60288 60289 else 60290 60291 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60292 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 60293 METHOD="well-known location" 60294 60295 # Let's start with an optimistic view of the world :-) 60296 FOUND_FREETYPE=yes 60297 60298 # First look for the canonical freetype main include file ft2build.h. 60299 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60300 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60301 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60302 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60303 # Fail. 60304 FOUND_FREETYPE=no 60305 fi 60306 fi 60307 60308 if test "x$FOUND_FREETYPE" = xyes; then 60309 # Include file found, let's continue the sanity check. 60310 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60311 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60312 60313 # Reset to default value 60314 FREETYPE_BASE_NAME=freetype 60315 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60316 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60317 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60318 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60319 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60320 # for the .6 version explicitly. 60321 FREETYPE_BASE_NAME=freetype.6 60322 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60323 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60324 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60325 else 60326 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60327 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60328 FOUND_FREETYPE=no 60329 fi 60330 else 60331 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60332 # On Windows, we will need both .lib and .dll file. 60333 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60334 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60335 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60336 FOUND_FREETYPE=no 60337 fi 60338 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60339 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60340 # Found lib in isa dir, use that instead. 60341 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60342 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60343 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60344 fi 60345 fi 60346 fi 60347 60348 if test "x$FOUND_FREETYPE" = xyes; then 60349 60350 # Only process if variable expands to non-empty 60351 60352 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60354 60355 # Input might be given as Windows format, start by converting to 60356 # unix format. 60357 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60358 new_path=`$CYGPATH -u "$path"` 60359 60360 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60361 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60362 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60363 # "foo.exe" is OK but "foo" is an error. 60364 # 60365 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60366 # It is also a way to make sure we got the proper file name for the real test later on. 60367 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60368 if test "x$test_shortpath" = x; then 60369 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60370 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60371 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60372 fi 60373 60374 # Call helper function which possibly converts this using DOS-style short mode. 60375 # If so, the updated path is stored in $new_path. 60376 60377 input_path="$new_path" 60378 # Check if we need to convert this using DOS-style short mode. If the path 60379 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60380 # take no chances and rewrite it. 60381 # Note: m4 eats our [], so we need to use [ and ] instead. 60382 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60383 if test "x$has_forbidden_chars" != x; then 60384 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60385 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60386 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60387 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60388 # Going to short mode and back again did indeed matter. Since short mode is 60389 # case insensitive, let's make it lowercase to improve readability. 60390 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60391 # Now convert it back to Unix-style (cygpath) 60392 input_path=`$CYGPATH -u "$shortmode_path"` 60393 new_path="$input_path" 60394 fi 60395 fi 60396 60397 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60398 if test "x$test_cygdrive_prefix" = x; then 60399 # As a simple fix, exclude /usr/bin since it's not a real path. 60400 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60401 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60402 # a path prefixed by /cygdrive for fixpath to work. 60403 new_path="$CYGWIN_ROOT_PATH$input_path" 60404 fi 60405 fi 60406 60407 60408 if test "x$path" != "x$new_path"; then 60409 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60410 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60411 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60412 fi 60413 60414 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60415 60416 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60417 has_colon=`$ECHO $path | $GREP ^.:` 60418 new_path="$path" 60419 if test "x$has_colon" = x; then 60420 # Not in mixed or Windows style, start by that. 60421 new_path=`cmd //c echo $path` 60422 fi 60423 60424 60425 input_path="$new_path" 60426 # Check if we need to convert this using DOS-style short mode. If the path 60427 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60428 # take no chances and rewrite it. 60429 # Note: m4 eats our [], so we need to use [ and ] instead. 60430 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60431 if test "x$has_forbidden_chars" != x; then 60432 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60433 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60434 fi 60435 60436 60437 windows_path="$new_path" 60438 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60439 unix_path=`$CYGPATH -u "$windows_path"` 60440 new_path="$unix_path" 60441 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60442 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60443 new_path="$unix_path" 60444 fi 60445 60446 if test "x$path" != "x$new_path"; then 60447 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60448 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60449 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60450 fi 60451 60452 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60453 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60454 60455 else 60456 # We're on a unix platform. Hooray! :) 60457 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60458 has_space=`$ECHO "$path" | $GREP " "` 60459 if test "x$has_space" != x; then 60460 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60461 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60462 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60463 fi 60464 60465 # Use eval to expand a potential ~ 60466 eval path="$path" 60467 if test ! -f "$path" && test ! -d "$path"; then 60468 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60469 fi 60470 60471 if test -d "$path"; then 60472 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60473 else 60474 dir="`$DIRNAME "$path"`" 60475 base="`$BASENAME "$path"`" 60476 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60477 fi 60478 fi 60479 fi 60480 60481 60482 # Only process if variable expands to non-empty 60483 60484 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60485 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60486 60487 # Input might be given as Windows format, start by converting to 60488 # unix format. 60489 path="$POTENTIAL_FREETYPE_LIB_PATH" 60490 new_path=`$CYGPATH -u "$path"` 60491 60492 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60493 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60494 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60495 # "foo.exe" is OK but "foo" is an error. 60496 # 60497 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60498 # It is also a way to make sure we got the proper file name for the real test later on. 60499 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60500 if test "x$test_shortpath" = x; then 60501 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60502 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60503 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60504 fi 60505 60506 # Call helper function which possibly converts this using DOS-style short mode. 60507 # If so, the updated path is stored in $new_path. 60508 60509 input_path="$new_path" 60510 # Check if we need to convert this using DOS-style short mode. If the path 60511 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60512 # take no chances and rewrite it. 60513 # Note: m4 eats our [], so we need to use [ and ] instead. 60514 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60515 if test "x$has_forbidden_chars" != x; then 60516 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60517 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60518 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60519 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60520 # Going to short mode and back again did indeed matter. Since short mode is 60521 # case insensitive, let's make it lowercase to improve readability. 60522 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60523 # Now convert it back to Unix-style (cygpath) 60524 input_path=`$CYGPATH -u "$shortmode_path"` 60525 new_path="$input_path" 60526 fi 60527 fi 60528 60529 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60530 if test "x$test_cygdrive_prefix" = x; then 60531 # As a simple fix, exclude /usr/bin since it's not a real path. 60532 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60533 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60534 # a path prefixed by /cygdrive for fixpath to work. 60535 new_path="$CYGWIN_ROOT_PATH$input_path" 60536 fi 60537 fi 60538 60539 60540 if test "x$path" != "x$new_path"; then 60541 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60542 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60543 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60544 fi 60545 60546 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60547 60548 path="$POTENTIAL_FREETYPE_LIB_PATH" 60549 has_colon=`$ECHO $path | $GREP ^.:` 60550 new_path="$path" 60551 if test "x$has_colon" = x; then 60552 # Not in mixed or Windows style, start by that. 60553 new_path=`cmd //c echo $path` 60554 fi 60555 60556 60557 input_path="$new_path" 60558 # Check if we need to convert this using DOS-style short mode. If the path 60559 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60560 # take no chances and rewrite it. 60561 # Note: m4 eats our [], so we need to use [ and ] instead. 60562 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60563 if test "x$has_forbidden_chars" != x; then 60564 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60565 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60566 fi 60567 60568 60569 windows_path="$new_path" 60570 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60571 unix_path=`$CYGPATH -u "$windows_path"` 60572 new_path="$unix_path" 60573 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60574 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60575 new_path="$unix_path" 60576 fi 60577 60578 if test "x$path" != "x$new_path"; then 60579 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60580 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60581 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60582 fi 60583 60584 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60585 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60586 60587 else 60588 # We're on a unix platform. Hooray! :) 60589 path="$POTENTIAL_FREETYPE_LIB_PATH" 60590 has_space=`$ECHO "$path" | $GREP " "` 60591 if test "x$has_space" != x; then 60592 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60593 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60594 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60595 fi 60596 60597 # Use eval to expand a potential ~ 60598 eval path="$path" 60599 if test ! -f "$path" && test ! -d "$path"; then 60600 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60601 fi 60602 60603 if test -d "$path"; then 60604 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60605 else 60606 dir="`$DIRNAME "$path"`" 60607 base="`$BASENAME "$path"`" 60608 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60609 fi 60610 fi 60611 fi 60612 60613 60614 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60616 $as_echo_n "checking for freetype includes... " >&6; } 60617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60618 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60619 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60621 $as_echo_n "checking for freetype libraries... " >&6; } 60622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60623 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60624 fi 60625 60626 fi 60627 if test "x$FOUND_FREETYPE" != xyes && test -d $FREETYPE_BASE_DIR \ 60628 && test -s "$FREETYPE_BASE_DIR/builds/windows/vc2010/freetype.vcxproj" && test "x$MSBUILD" != x; then 60629 # Source is available, as a last resort try to build freetype in default location 60630 60631 FREETYPE_SRC_PATH="$FREETYPE_BASE_DIR" 60632 BUILD_FREETYPE=yes 60633 60634 # Check if the freetype sources are acessible.. 60635 if ! test -d $FREETYPE_SRC_PATH; then 60636 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&5 60637 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 60638 BUILD_FREETYPE=no 60639 fi 60640 # ..and contain a vc2010 project file 60641 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 60642 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 60643 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&5 60644 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 60645 BUILD_FREETYPE=no 60646 fi 60647 # Now check if configure found a version of 'msbuild.exe' 60648 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 60649 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can not find an msbuild.exe executable (you may try to install .NET 4.0) - ignoring --with-freetype-src" >&5 60650 $as_echo "$as_me: WARNING: Can not find an msbuild.exe executable (you may try to install .NET 4.0) - ignoring --with-freetype-src" >&2;} 60651 BUILD_FREETYPE=no 60652 fi 60653 60654 # Ready to go.. 60655 if test "x$BUILD_FREETYPE" = xyes; then 60656 # msbuild requires trailing slashes for output directories 60657 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 60658 freetype_lib_path_unix="$freetype_lib_path" 60659 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 60660 60661 unix_path="$vcxproj_path" 60662 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60663 windows_path=`$CYGPATH -m "$unix_path"` 60664 vcxproj_path="$windows_path" 60665 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60666 windows_path=`cmd //c echo $unix_path` 60667 vcxproj_path="$windows_path" 60668 fi 60669 60670 60671 unix_path="$freetype_lib_path" 60672 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60673 windows_path=`$CYGPATH -m "$unix_path"` 60674 freetype_lib_path="$windows_path" 60675 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60676 windows_path=`cmd //c echo $unix_path` 60677 freetype_lib_path="$windows_path" 60678 fi 60679 60680 60681 unix_path="$freetype_obj_path" 60682 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60683 windows_path=`$CYGPATH -m "$unix_path"` 60684 freetype_obj_path="$windows_path" 60685 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60686 windows_path=`cmd //c echo $unix_path` 60687 freetype_obj_path="$windows_path" 60688 fi 60689 60690 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 60691 freetype_platform=x64 60692 else 60693 freetype_platform=win32 60694 fi 60695 60696 # The original freetype project file is for VS 2010 (i.e. 'v100'), 60697 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 60698 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 60699 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 60700 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 60701 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 60702 60703 # First we try to build the freetype.dll 60704 $ECHO -e "@echo off\n"\ 60705 "$MSBUILD $vcxproj_path "\ 60706 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 60707 "/p:Configuration=\"Release Multithreaded\" "\ 60708 "/p:Platform=$freetype_platform "\ 60709 "/p:ConfigurationType=DynamicLibrary "\ 60710 "/p:TargetName=freetype "\ 60711 "/p:OutDir=\"$freetype_lib_path\" "\ 60712 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 60713 cmd /c freetype.bat 60714 60715 if test -s "$freetype_lib_path_unix/freetype.dll"; then 60716 # If that succeeds we also build freetype.lib 60717 $ECHO -e "@echo off\n"\ 60718 "$MSBUILD $vcxproj_path "\ 60719 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 60720 "/p:Configuration=\"Release Multithreaded\" "\ 60721 "/p:Platform=$freetype_platform "\ 60722 "/p:ConfigurationType=StaticLibrary "\ 60723 "/p:TargetName=freetype "\ 60724 "/p:OutDir=\"$freetype_lib_path\" "\ 60725 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 60726 cmd /c freetype.bat 60727 60728 if test -s "$freetype_lib_path_unix/freetype.lib"; then 60729 # Once we build both, lib and dll, set freetype lib and include path appropriately 60730 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 60731 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 60732 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 60733 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 60734 else 60735 BUILD_FREETYPE=no 60736 fi 60737 else 60738 BUILD_FREETYPE=no 60739 fi 60740 fi 60741 60742 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 60743 60744 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60745 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 60746 METHOD="well-known location" 60747 60748 # Let's start with an optimistic view of the world :-) 60749 FOUND_FREETYPE=yes 60750 60751 # First look for the canonical freetype main include file ft2build.h. 60752 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60753 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60754 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60755 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60756 # Fail. 60757 FOUND_FREETYPE=no 60758 fi 60759 fi 60760 60761 if test "x$FOUND_FREETYPE" = xyes; then 60762 # Include file found, let's continue the sanity check. 60763 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60764 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60765 60766 # Reset to default value 60767 FREETYPE_BASE_NAME=freetype 60768 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60769 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60770 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60771 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60772 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60773 # for the .6 version explicitly. 60774 FREETYPE_BASE_NAME=freetype.6 60775 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60776 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60777 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60778 else 60779 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60780 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60781 FOUND_FREETYPE=no 60782 fi 60783 else 60784 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60785 # On Windows, we will need both .lib and .dll file. 60786 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60787 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60788 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60789 FOUND_FREETYPE=no 60790 fi 60791 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60792 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60793 # Found lib in isa dir, use that instead. 60794 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60795 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60796 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60797 fi 60798 fi 60799 fi 60800 60801 if test "x$FOUND_FREETYPE" = xyes; then 60802 60803 # Only process if variable expands to non-empty 60804 60805 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60806 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60807 60808 # Input might be given as Windows format, start by converting to 60809 # unix format. 60810 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60811 new_path=`$CYGPATH -u "$path"` 60812 60813 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60814 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60815 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60816 # "foo.exe" is OK but "foo" is an error. 60817 # 60818 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60819 # It is also a way to make sure we got the proper file name for the real test later on. 60820 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60821 if test "x$test_shortpath" = x; then 60822 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60823 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60824 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60825 fi 60826 60827 # Call helper function which possibly converts this using DOS-style short mode. 60828 # If so, the updated path is stored in $new_path. 60829 60830 input_path="$new_path" 60831 # Check if we need to convert this using DOS-style short mode. If the path 60832 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60833 # take no chances and rewrite it. 60834 # Note: m4 eats our [], so we need to use [ and ] instead. 60835 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60836 if test "x$has_forbidden_chars" != x; then 60837 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60838 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60839 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60840 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60841 # Going to short mode and back again did indeed matter. Since short mode is 60842 # case insensitive, let's make it lowercase to improve readability. 60843 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60844 # Now convert it back to Unix-style (cygpath) 60845 input_path=`$CYGPATH -u "$shortmode_path"` 60846 new_path="$input_path" 60847 fi 60848 fi 60849 60850 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60851 if test "x$test_cygdrive_prefix" = x; then 60852 # As a simple fix, exclude /usr/bin since it's not a real path. 60853 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60854 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60855 # a path prefixed by /cygdrive for fixpath to work. 60856 new_path="$CYGWIN_ROOT_PATH$input_path" 60857 fi 60858 fi 60859 60860 60861 if test "x$path" != "x$new_path"; then 60862 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60863 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60864 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60865 fi 60866 60867 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60868 60869 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60870 has_colon=`$ECHO $path | $GREP ^.:` 60871 new_path="$path" 60872 if test "x$has_colon" = x; then 60873 # Not in mixed or Windows style, start by that. 60874 new_path=`cmd //c echo $path` 60875 fi 60876 60877 60878 input_path="$new_path" 60879 # Check if we need to convert this using DOS-style short mode. If the path 60880 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60881 # take no chances and rewrite it. 60882 # Note: m4 eats our [], so we need to use [ and ] instead. 60883 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60884 if test "x$has_forbidden_chars" != x; then 60885 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60886 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60887 fi 60888 60889 60890 windows_path="$new_path" 60891 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60892 unix_path=`$CYGPATH -u "$windows_path"` 60893 new_path="$unix_path" 60894 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60895 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60896 new_path="$unix_path" 60897 fi 60898 60899 if test "x$path" != "x$new_path"; then 60900 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60901 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60902 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60903 fi 60904 60905 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60906 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60907 60908 else 60909 # We're on a unix platform. Hooray! :) 60910 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60911 has_space=`$ECHO "$path" | $GREP " "` 60912 if test "x$has_space" != x; then 60913 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60914 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60915 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60916 fi 60917 60918 # Use eval to expand a potential ~ 60919 eval path="$path" 60920 if test ! -f "$path" && test ! -d "$path"; then 60921 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60922 fi 60923 60924 if test -d "$path"; then 60925 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60926 else 60927 dir="`$DIRNAME "$path"`" 60928 base="`$BASENAME "$path"`" 60929 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60930 fi 60931 fi 60932 fi 60933 60934 60935 # Only process if variable expands to non-empty 60936 60937 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60938 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60939 60940 # Input might be given as Windows format, start by converting to 60941 # unix format. 60942 path="$POTENTIAL_FREETYPE_LIB_PATH" 60943 new_path=`$CYGPATH -u "$path"` 60944 60945 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60946 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60947 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60948 # "foo.exe" is OK but "foo" is an error. 60949 # 60950 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60951 # It is also a way to make sure we got the proper file name for the real test later on. 60952 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60953 if test "x$test_shortpath" = x; then 60954 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60955 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60956 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60957 fi 60958 60959 # Call helper function which possibly converts this using DOS-style short mode. 60960 # If so, the updated path is stored in $new_path. 60961 60962 input_path="$new_path" 60963 # Check if we need to convert this using DOS-style short mode. If the path 60964 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60965 # take no chances and rewrite it. 60966 # Note: m4 eats our [], so we need to use [ and ] instead. 60967 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60968 if test "x$has_forbidden_chars" != x; then 60969 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60970 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60971 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60972 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60973 # Going to short mode and back again did indeed matter. Since short mode is 60974 # case insensitive, let's make it lowercase to improve readability. 60975 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60976 # Now convert it back to Unix-style (cygpath) 60977 input_path=`$CYGPATH -u "$shortmode_path"` 60978 new_path="$input_path" 60979 fi 60980 fi 60981 60982 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60983 if test "x$test_cygdrive_prefix" = x; then 60984 # As a simple fix, exclude /usr/bin since it's not a real path. 60985 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60986 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60987 # a path prefixed by /cygdrive for fixpath to work. 60988 new_path="$CYGWIN_ROOT_PATH$input_path" 60989 fi 60990 fi 60991 60992 60993 if test "x$path" != "x$new_path"; then 60994 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60995 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60996 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60997 fi 60998 60999 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61000 61001 path="$POTENTIAL_FREETYPE_LIB_PATH" 61002 has_colon=`$ECHO $path | $GREP ^.:` 61003 new_path="$path" 61004 if test "x$has_colon" = x; then 61005 # Not in mixed or Windows style, start by that. 61006 new_path=`cmd //c echo $path` 61007 fi 61008 61009 61010 input_path="$new_path" 61011 # Check if we need to convert this using DOS-style short mode. If the path 61012 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61013 # take no chances and rewrite it. 61014 # Note: m4 eats our [], so we need to use [ and ] instead. 61015 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61016 if test "x$has_forbidden_chars" != x; then 61017 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61018 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61019 fi 61020 61021 61022 windows_path="$new_path" 61023 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61024 unix_path=`$CYGPATH -u "$windows_path"` 61025 new_path="$unix_path" 61026 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61027 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61028 new_path="$unix_path" 61029 fi 61030 61031 if test "x$path" != "x$new_path"; then 61032 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61033 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61034 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61035 fi 61036 61037 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61038 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61039 61040 else 61041 # We're on a unix platform. Hooray! :) 61042 path="$POTENTIAL_FREETYPE_LIB_PATH" 61043 has_space=`$ECHO "$path" | $GREP " "` 61044 if test "x$has_space" != x; then 61045 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61046 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61047 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61048 fi 61049 61050 # Use eval to expand a potential ~ 61051 eval path="$path" 61052 if test ! -f "$path" && test ! -d "$path"; then 61053 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61054 fi 61055 61056 if test -d "$path"; then 61057 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61058 else 61059 dir="`$DIRNAME "$path"`" 61060 base="`$BASENAME "$path"`" 61061 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61062 fi 61063 fi 61064 fi 61065 61066 61067 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61069 $as_echo_n "checking for freetype includes... " >&6; } 61070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61071 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61072 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61074 $as_echo_n "checking for freetype libraries... " >&6; } 61075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61076 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61077 fi 61078 61079 else 61080 61081 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61082 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 61083 METHOD="well-known location" 61084 61085 # Let's start with an optimistic view of the world :-) 61086 FOUND_FREETYPE=yes 61087 61088 # First look for the canonical freetype main include file ft2build.h. 61089 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61090 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61091 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61092 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61093 # Fail. 61094 FOUND_FREETYPE=no 61095 fi 61096 fi 61097 61098 if test "x$FOUND_FREETYPE" = xyes; then 61099 # Include file found, let's continue the sanity check. 61100 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61101 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61102 61103 # Reset to default value 61104 FREETYPE_BASE_NAME=freetype 61105 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61106 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61107 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61108 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61109 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61110 # for the .6 version explicitly. 61111 FREETYPE_BASE_NAME=freetype.6 61112 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61113 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61114 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61115 else 61116 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61117 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61118 FOUND_FREETYPE=no 61119 fi 61120 else 61121 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61122 # On Windows, we will need both .lib and .dll file. 61123 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61124 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61125 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61126 FOUND_FREETYPE=no 61127 fi 61128 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61129 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61130 # Found lib in isa dir, use that instead. 61131 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61132 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61133 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61134 fi 61135 fi 61136 fi 61137 61138 if test "x$FOUND_FREETYPE" = xyes; then 61139 61140 # Only process if variable expands to non-empty 61141 61142 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61143 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61144 61145 # Input might be given as Windows format, start by converting to 61146 # unix format. 61147 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61148 new_path=`$CYGPATH -u "$path"` 61149 61150 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61151 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61152 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61153 # "foo.exe" is OK but "foo" is an error. 61154 # 61155 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61156 # It is also a way to make sure we got the proper file name for the real test later on. 61157 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61158 if test "x$test_shortpath" = x; then 61159 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61160 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61161 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61162 fi 61163 61164 # Call helper function which possibly converts this using DOS-style short mode. 61165 # If so, the updated path is stored in $new_path. 61166 61167 input_path="$new_path" 61168 # Check if we need to convert this using DOS-style short mode. If the path 61169 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61170 # take no chances and rewrite it. 61171 # Note: m4 eats our [], so we need to use [ and ] instead. 61172 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61173 if test "x$has_forbidden_chars" != x; then 61174 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61175 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61176 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61177 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61178 # Going to short mode and back again did indeed matter. Since short mode is 61179 # case insensitive, let's make it lowercase to improve readability. 61180 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61181 # Now convert it back to Unix-style (cygpath) 61182 input_path=`$CYGPATH -u "$shortmode_path"` 61183 new_path="$input_path" 61184 fi 61185 fi 61186 61187 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61188 if test "x$test_cygdrive_prefix" = x; then 61189 # As a simple fix, exclude /usr/bin since it's not a real path. 61190 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61191 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61192 # a path prefixed by /cygdrive for fixpath to work. 61193 new_path="$CYGWIN_ROOT_PATH$input_path" 61194 fi 61195 fi 61196 61197 61198 if test "x$path" != "x$new_path"; then 61199 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61200 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61201 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61202 fi 61203 61204 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61205 61206 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61207 has_colon=`$ECHO $path | $GREP ^.:` 61208 new_path="$path" 61209 if test "x$has_colon" = x; then 61210 # Not in mixed or Windows style, start by that. 61211 new_path=`cmd //c echo $path` 61212 fi 61213 61214 61215 input_path="$new_path" 61216 # Check if we need to convert this using DOS-style short mode. If the path 61217 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61218 # take no chances and rewrite it. 61219 # Note: m4 eats our [], so we need to use [ and ] instead. 61220 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61221 if test "x$has_forbidden_chars" != x; then 61222 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61223 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61224 fi 61225 61226 61227 windows_path="$new_path" 61228 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61229 unix_path=`$CYGPATH -u "$windows_path"` 61230 new_path="$unix_path" 61231 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61232 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61233 new_path="$unix_path" 61234 fi 61235 61236 if test "x$path" != "x$new_path"; then 61237 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61238 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61239 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61240 fi 61241 61242 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61243 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61244 61245 else 61246 # We're on a unix platform. Hooray! :) 61247 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61248 has_space=`$ECHO "$path" | $GREP " "` 61249 if test "x$has_space" != x; then 61250 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61251 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61252 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61253 fi 61254 61255 # Use eval to expand a potential ~ 61256 eval path="$path" 61257 if test ! -f "$path" && test ! -d "$path"; then 61258 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61259 fi 61260 61261 if test -d "$path"; then 61262 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61263 else 61264 dir="`$DIRNAME "$path"`" 61265 base="`$BASENAME "$path"`" 61266 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61267 fi 61268 fi 61269 fi 61270 61271 61272 # Only process if variable expands to non-empty 61273 61274 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61275 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61276 61277 # Input might be given as Windows format, start by converting to 61278 # unix format. 61279 path="$POTENTIAL_FREETYPE_LIB_PATH" 61280 new_path=`$CYGPATH -u "$path"` 61281 61282 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61283 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61284 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61285 # "foo.exe" is OK but "foo" is an error. 61286 # 61287 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61288 # It is also a way to make sure we got the proper file name for the real test later on. 61289 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61290 if test "x$test_shortpath" = x; then 61291 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61292 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61293 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61294 fi 61295 61296 # Call helper function which possibly converts this using DOS-style short mode. 61297 # If so, the updated path is stored in $new_path. 61298 61299 input_path="$new_path" 61300 # Check if we need to convert this using DOS-style short mode. If the path 61301 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61302 # take no chances and rewrite it. 61303 # Note: m4 eats our [], so we need to use [ and ] instead. 61304 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61305 if test "x$has_forbidden_chars" != x; then 61306 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61307 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61308 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61309 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61310 # Going to short mode and back again did indeed matter. Since short mode is 61311 # case insensitive, let's make it lowercase to improve readability. 61312 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61313 # Now convert it back to Unix-style (cygpath) 61314 input_path=`$CYGPATH -u "$shortmode_path"` 61315 new_path="$input_path" 61316 fi 61317 fi 61318 61319 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61320 if test "x$test_cygdrive_prefix" = x; then 61321 # As a simple fix, exclude /usr/bin since it's not a real path. 61322 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61323 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61324 # a path prefixed by /cygdrive for fixpath to work. 61325 new_path="$CYGWIN_ROOT_PATH$input_path" 61326 fi 61327 fi 61328 61329 61330 if test "x$path" != "x$new_path"; then 61331 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61332 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61333 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61334 fi 61335 61336 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61337 61338 path="$POTENTIAL_FREETYPE_LIB_PATH" 61339 has_colon=`$ECHO $path | $GREP ^.:` 61340 new_path="$path" 61341 if test "x$has_colon" = x; then 61342 # Not in mixed or Windows style, start by that. 61343 new_path=`cmd //c echo $path` 61344 fi 61345 61346 61347 input_path="$new_path" 61348 # Check if we need to convert this using DOS-style short mode. If the path 61349 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61350 # take no chances and rewrite it. 61351 # Note: m4 eats our [], so we need to use [ and ] instead. 61352 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61353 if test "x$has_forbidden_chars" != x; then 61354 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61355 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61356 fi 61357 61358 61359 windows_path="$new_path" 61360 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61361 unix_path=`$CYGPATH -u "$windows_path"` 61362 new_path="$unix_path" 61363 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61364 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61365 new_path="$unix_path" 61366 fi 61367 61368 if test "x$path" != "x$new_path"; then 61369 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61370 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61371 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61372 fi 61373 61374 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61375 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61376 61377 else 61378 # We're on a unix platform. Hooray! :) 61379 path="$POTENTIAL_FREETYPE_LIB_PATH" 61380 has_space=`$ECHO "$path" | $GREP " "` 61381 if test "x$has_space" != x; then 61382 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61383 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61384 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61385 fi 61386 61387 # Use eval to expand a potential ~ 61388 eval path="$path" 61389 if test ! -f "$path" && test ! -d "$path"; then 61390 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61391 fi 61392 61393 if test -d "$path"; then 61394 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61395 else 61396 dir="`$DIRNAME "$path"`" 61397 base="`$BASENAME "$path"`" 61398 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61399 fi 61400 fi 61401 fi 61402 61403 61404 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61406 $as_echo_n "checking for freetype includes... " >&6; } 61407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61408 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61409 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61411 $as_echo_n "checking for freetype libraries... " >&6; } 61412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61413 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61414 fi 61415 61416 fi 61417 fi 61418 fi 61419 else 61420 FREETYPE_BASE_DIR="$SYSROOT/usr" 61421 61422 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61423 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 61424 METHOD="well-known location" 61425 61426 # Let's start with an optimistic view of the world :-) 61427 FOUND_FREETYPE=yes 61428 61429 # First look for the canonical freetype main include file ft2build.h. 61430 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61431 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61432 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61433 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61434 # Fail. 61435 FOUND_FREETYPE=no 61436 fi 61437 fi 61438 61439 if test "x$FOUND_FREETYPE" = xyes; then 61440 # Include file found, let's continue the sanity check. 61441 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61442 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61443 61444 # Reset to default value 61445 FREETYPE_BASE_NAME=freetype 61446 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61447 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61448 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61449 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61450 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61451 # for the .6 version explicitly. 61452 FREETYPE_BASE_NAME=freetype.6 61453 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61454 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61455 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61456 else 61457 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61458 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61459 FOUND_FREETYPE=no 61460 fi 61461 else 61462 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61463 # On Windows, we will need both .lib and .dll file. 61464 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61465 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61466 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61467 FOUND_FREETYPE=no 61468 fi 61469 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61470 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61471 # Found lib in isa dir, use that instead. 61472 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61473 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61474 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61475 fi 61476 fi 61477 fi 61478 61479 if test "x$FOUND_FREETYPE" = xyes; then 61480 61481 # Only process if variable expands to non-empty 61482 61483 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61484 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61485 61486 # Input might be given as Windows format, start by converting to 61487 # unix format. 61488 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61489 new_path=`$CYGPATH -u "$path"` 61490 61491 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61492 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61493 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61494 # "foo.exe" is OK but "foo" is an error. 61495 # 61496 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61497 # It is also a way to make sure we got the proper file name for the real test later on. 61498 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61499 if test "x$test_shortpath" = x; then 61500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61501 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61502 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61503 fi 61504 61505 # Call helper function which possibly converts this using DOS-style short mode. 61506 # If so, the updated path is stored in $new_path. 61507 61508 input_path="$new_path" 61509 # Check if we need to convert this using DOS-style short mode. If the path 61510 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61511 # take no chances and rewrite it. 61512 # Note: m4 eats our [], so we need to use [ and ] instead. 61513 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61514 if test "x$has_forbidden_chars" != x; then 61515 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61516 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61517 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61518 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61519 # Going to short mode and back again did indeed matter. Since short mode is 61520 # case insensitive, let's make it lowercase to improve readability. 61521 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61522 # Now convert it back to Unix-style (cygpath) 61523 input_path=`$CYGPATH -u "$shortmode_path"` 61524 new_path="$input_path" 61525 fi 61526 fi 61527 61528 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61529 if test "x$test_cygdrive_prefix" = x; then 61530 # As a simple fix, exclude /usr/bin since it's not a real path. 61531 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61532 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61533 # a path prefixed by /cygdrive for fixpath to work. 61534 new_path="$CYGWIN_ROOT_PATH$input_path" 61535 fi 61536 fi 61537 61538 61539 if test "x$path" != "x$new_path"; then 61540 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61541 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61542 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61543 fi 61544 61545 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61546 61547 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61548 has_colon=`$ECHO $path | $GREP ^.:` 61549 new_path="$path" 61550 if test "x$has_colon" = x; then 61551 # Not in mixed or Windows style, start by that. 61552 new_path=`cmd //c echo $path` 61553 fi 61554 61555 61556 input_path="$new_path" 61557 # Check if we need to convert this using DOS-style short mode. If the path 61558 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61559 # take no chances and rewrite it. 61560 # Note: m4 eats our [], so we need to use [ and ] instead. 61561 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61562 if test "x$has_forbidden_chars" != x; then 61563 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61564 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61565 fi 61566 61567 61568 windows_path="$new_path" 61569 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61570 unix_path=`$CYGPATH -u "$windows_path"` 61571 new_path="$unix_path" 61572 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61573 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61574 new_path="$unix_path" 61575 fi 61576 61577 if test "x$path" != "x$new_path"; then 61578 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61579 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61580 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61581 fi 61582 61583 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61584 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61585 61586 else 61587 # We're on a unix platform. Hooray! :) 61588 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61589 has_space=`$ECHO "$path" | $GREP " "` 61590 if test "x$has_space" != x; then 61591 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61592 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61593 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61594 fi 61595 61596 # Use eval to expand a potential ~ 61597 eval path="$path" 61598 if test ! -f "$path" && test ! -d "$path"; then 61599 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61600 fi 61601 61602 if test -d "$path"; then 61603 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61604 else 61605 dir="`$DIRNAME "$path"`" 61606 base="`$BASENAME "$path"`" 61607 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61608 fi 61609 fi 61610 fi 61611 61612 61613 # Only process if variable expands to non-empty 61614 61615 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61616 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61617 61618 # Input might be given as Windows format, start by converting to 61619 # unix format. 61620 path="$POTENTIAL_FREETYPE_LIB_PATH" 61621 new_path=`$CYGPATH -u "$path"` 61622 61623 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61624 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61625 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61626 # "foo.exe" is OK but "foo" is an error. 61627 # 61628 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61629 # It is also a way to make sure we got the proper file name for the real test later on. 61630 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61631 if test "x$test_shortpath" = x; then 61632 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61633 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61634 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61635 fi 61636 61637 # Call helper function which possibly converts this using DOS-style short mode. 61638 # If so, the updated path is stored in $new_path. 61639 61640 input_path="$new_path" 61641 # Check if we need to convert this using DOS-style short mode. If the path 61642 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61643 # take no chances and rewrite it. 61644 # Note: m4 eats our [], so we need to use [ and ] instead. 61645 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61646 if test "x$has_forbidden_chars" != x; then 61647 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61648 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61649 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61650 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61651 # Going to short mode and back again did indeed matter. Since short mode is 61652 # case insensitive, let's make it lowercase to improve readability. 61653 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61654 # Now convert it back to Unix-style (cygpath) 61655 input_path=`$CYGPATH -u "$shortmode_path"` 61656 new_path="$input_path" 61657 fi 61658 fi 61659 61660 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61661 if test "x$test_cygdrive_prefix" = x; then 61662 # As a simple fix, exclude /usr/bin since it's not a real path. 61663 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61664 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61665 # a path prefixed by /cygdrive for fixpath to work. 61666 new_path="$CYGWIN_ROOT_PATH$input_path" 61667 fi 61668 fi 61669 61670 61671 if test "x$path" != "x$new_path"; then 61672 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61673 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61674 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61675 fi 61676 61677 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61678 61679 path="$POTENTIAL_FREETYPE_LIB_PATH" 61680 has_colon=`$ECHO $path | $GREP ^.:` 61681 new_path="$path" 61682 if test "x$has_colon" = x; then 61683 # Not in mixed or Windows style, start by that. 61684 new_path=`cmd //c echo $path` 61685 fi 61686 61687 61688 input_path="$new_path" 61689 # Check if we need to convert this using DOS-style short mode. If the path 61690 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61691 # take no chances and rewrite it. 61692 # Note: m4 eats our [], so we need to use [ and ] instead. 61693 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61694 if test "x$has_forbidden_chars" != x; then 61695 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61696 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61697 fi 61698 61699 61700 windows_path="$new_path" 61701 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61702 unix_path=`$CYGPATH -u "$windows_path"` 61703 new_path="$unix_path" 61704 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61705 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61706 new_path="$unix_path" 61707 fi 61708 61709 if test "x$path" != "x$new_path"; then 61710 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61711 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61712 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61713 fi 61714 61715 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61716 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61717 61718 else 61719 # We're on a unix platform. Hooray! :) 61720 path="$POTENTIAL_FREETYPE_LIB_PATH" 61721 has_space=`$ECHO "$path" | $GREP " "` 61722 if test "x$has_space" != x; then 61723 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61724 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61725 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61726 fi 61727 61728 # Use eval to expand a potential ~ 61729 eval path="$path" 61730 if test ! -f "$path" && test ! -d "$path"; then 61731 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61732 fi 61733 61734 if test -d "$path"; then 61735 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61736 else 61737 dir="`$DIRNAME "$path"`" 61738 base="`$BASENAME "$path"`" 61739 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61740 fi 61741 fi 61742 fi 61743 61744 61745 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61747 $as_echo_n "checking for freetype includes... " >&6; } 61748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61749 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61750 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61752 $as_echo_n "checking for freetype libraries... " >&6; } 61753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61754 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61755 fi 61756 61757 61758 if test "x$FOUND_FREETYPE" != xyes; then 61759 FREETYPE_BASE_DIR="$SYSROOT/usr/X11" 61760 61761 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61762 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 61763 METHOD="well-known location" 61764 61765 # Let's start with an optimistic view of the world :-) 61766 FOUND_FREETYPE=yes 61767 61768 # First look for the canonical freetype main include file ft2build.h. 61769 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61770 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61771 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61772 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61773 # Fail. 61774 FOUND_FREETYPE=no 61775 fi 61776 fi 61777 61778 if test "x$FOUND_FREETYPE" = xyes; then 61779 # Include file found, let's continue the sanity check. 61780 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61781 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61782 61783 # Reset to default value 61784 FREETYPE_BASE_NAME=freetype 61785 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61786 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61787 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61788 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61789 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61790 # for the .6 version explicitly. 61791 FREETYPE_BASE_NAME=freetype.6 61792 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61793 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61794 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61795 else 61796 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61797 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61798 FOUND_FREETYPE=no 61799 fi 61800 else 61801 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61802 # On Windows, we will need both .lib and .dll file. 61803 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61804 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61805 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61806 FOUND_FREETYPE=no 61807 fi 61808 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61809 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61810 # Found lib in isa dir, use that instead. 61811 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61812 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61813 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61814 fi 61815 fi 61816 fi 61817 61818 if test "x$FOUND_FREETYPE" = xyes; then 61819 61820 # Only process if variable expands to non-empty 61821 61822 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61823 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61824 61825 # Input might be given as Windows format, start by converting to 61826 # unix format. 61827 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61828 new_path=`$CYGPATH -u "$path"` 61829 61830 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61831 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61832 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61833 # "foo.exe" is OK but "foo" is an error. 61834 # 61835 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61836 # It is also a way to make sure we got the proper file name for the real test later on. 61837 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61838 if test "x$test_shortpath" = x; then 61839 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61840 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61841 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61842 fi 61843 61844 # Call helper function which possibly converts this using DOS-style short mode. 61845 # If so, the updated path is stored in $new_path. 61846 61847 input_path="$new_path" 61848 # Check if we need to convert this using DOS-style short mode. If the path 61849 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61850 # take no chances and rewrite it. 61851 # Note: m4 eats our [], so we need to use [ and ] instead. 61852 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61853 if test "x$has_forbidden_chars" != x; then 61854 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61855 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61856 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61857 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61858 # Going to short mode and back again did indeed matter. Since short mode is 61859 # case insensitive, let's make it lowercase to improve readability. 61860 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61861 # Now convert it back to Unix-style (cygpath) 61862 input_path=`$CYGPATH -u "$shortmode_path"` 61863 new_path="$input_path" 61864 fi 61865 fi 61866 61867 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61868 if test "x$test_cygdrive_prefix" = x; then 61869 # As a simple fix, exclude /usr/bin since it's not a real path. 61870 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61871 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61872 # a path prefixed by /cygdrive for fixpath to work. 61873 new_path="$CYGWIN_ROOT_PATH$input_path" 61874 fi 61875 fi 61876 61877 61878 if test "x$path" != "x$new_path"; then 61879 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61880 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61881 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61882 fi 61883 61884 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61885 61886 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61887 has_colon=`$ECHO $path | $GREP ^.:` 61888 new_path="$path" 61889 if test "x$has_colon" = x; then 61890 # Not in mixed or Windows style, start by that. 61891 new_path=`cmd //c echo $path` 61892 fi 61893 61894 61895 input_path="$new_path" 61896 # Check if we need to convert this using DOS-style short mode. If the path 61897 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61898 # take no chances and rewrite it. 61899 # Note: m4 eats our [], so we need to use [ and ] instead. 61900 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61901 if test "x$has_forbidden_chars" != x; then 61902 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61903 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61904 fi 61905 61906 61907 windows_path="$new_path" 61908 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61909 unix_path=`$CYGPATH -u "$windows_path"` 61910 new_path="$unix_path" 61911 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61912 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61913 new_path="$unix_path" 61914 fi 61915 61916 if test "x$path" != "x$new_path"; then 61917 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61918 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61919 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61920 fi 61921 61922 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61923 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61924 61925 else 61926 # We're on a unix platform. Hooray! :) 61927 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61928 has_space=`$ECHO "$path" | $GREP " "` 61929 if test "x$has_space" != x; then 61930 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61931 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61932 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61933 fi 61934 61935 # Use eval to expand a potential ~ 61936 eval path="$path" 61937 if test ! -f "$path" && test ! -d "$path"; then 61938 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61939 fi 61940 61941 if test -d "$path"; then 61942 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61943 else 61944 dir="`$DIRNAME "$path"`" 61945 base="`$BASENAME "$path"`" 61946 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61947 fi 61948 fi 61949 fi 61950 61951 61952 # Only process if variable expands to non-empty 61953 61954 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61955 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61956 61957 # Input might be given as Windows format, start by converting to 61958 # unix format. 61959 path="$POTENTIAL_FREETYPE_LIB_PATH" 61960 new_path=`$CYGPATH -u "$path"` 61961 61962 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61963 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61964 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61965 # "foo.exe" is OK but "foo" is an error. 61966 # 61967 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61968 # It is also a way to make sure we got the proper file name for the real test later on. 61969 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61970 if test "x$test_shortpath" = x; then 61971 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61972 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61973 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61974 fi 61975 61976 # Call helper function which possibly converts this using DOS-style short mode. 61977 # If so, the updated path is stored in $new_path. 61978 61979 input_path="$new_path" 61980 # Check if we need to convert this using DOS-style short mode. If the path 61981 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61982 # take no chances and rewrite it. 61983 # Note: m4 eats our [], so we need to use [ and ] instead. 61984 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61985 if test "x$has_forbidden_chars" != x; then 61986 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61987 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61988 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61989 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61990 # Going to short mode and back again did indeed matter. Since short mode is 61991 # case insensitive, let's make it lowercase to improve readability. 61992 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61993 # Now convert it back to Unix-style (cygpath) 61994 input_path=`$CYGPATH -u "$shortmode_path"` 61995 new_path="$input_path" 61996 fi 61997 fi 61998 61999 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62000 if test "x$test_cygdrive_prefix" = x; then 62001 # As a simple fix, exclude /usr/bin since it's not a real path. 62002 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62003 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62004 # a path prefixed by /cygdrive for fixpath to work. 62005 new_path="$CYGWIN_ROOT_PATH$input_path" 62006 fi 62007 fi 62008 62009 62010 if test "x$path" != "x$new_path"; then 62011 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62012 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62013 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62014 fi 62015 62016 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62017 62018 path="$POTENTIAL_FREETYPE_LIB_PATH" 62019 has_colon=`$ECHO $path | $GREP ^.:` 62020 new_path="$path" 62021 if test "x$has_colon" = x; then 62022 # Not in mixed or Windows style, start by that. 62023 new_path=`cmd //c echo $path` 62024 fi 62025 62026 62027 input_path="$new_path" 62028 # Check if we need to convert this using DOS-style short mode. If the path 62029 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62030 # take no chances and rewrite it. 62031 # Note: m4 eats our [], so we need to use [ and ] instead. 62032 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62033 if test "x$has_forbidden_chars" != x; then 62034 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62035 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62036 fi 62037 62038 62039 windows_path="$new_path" 62040 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62041 unix_path=`$CYGPATH -u "$windows_path"` 62042 new_path="$unix_path" 62043 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62044 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62045 new_path="$unix_path" 62046 fi 62047 62048 if test "x$path" != "x$new_path"; then 62049 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62050 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62051 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62052 fi 62053 62054 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62055 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62056 62057 else 62058 # We're on a unix platform. Hooray! :) 62059 path="$POTENTIAL_FREETYPE_LIB_PATH" 62060 has_space=`$ECHO "$path" | $GREP " "` 62061 if test "x$has_space" != x; then 62062 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62063 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62064 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62065 fi 62066 62067 # Use eval to expand a potential ~ 62068 eval path="$path" 62069 if test ! -f "$path" && test ! -d "$path"; then 62070 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62071 fi 62072 62073 if test -d "$path"; then 62074 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62075 else 62076 dir="`$DIRNAME "$path"`" 62077 base="`$BASENAME "$path"`" 62078 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62079 fi 62080 fi 62081 fi 62082 62083 62084 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62086 $as_echo_n "checking for freetype includes... " >&6; } 62087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62088 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62089 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62091 $as_echo_n "checking for freetype libraries... " >&6; } 62092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62093 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62094 fi 62095 62096 fi 62097 if test "x$FOUND_FREETYPE" != xyes; then 62098 FREETYPE_BASE_DIR="$SYSROOT/usr/local" 62099 62100 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62101 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 62102 METHOD="well-known location" 62103 62104 # Let's start with an optimistic view of the world :-) 62105 FOUND_FREETYPE=yes 62106 62107 # First look for the canonical freetype main include file ft2build.h. 62108 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62109 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62110 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62111 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62112 # Fail. 62113 FOUND_FREETYPE=no 62114 fi 62115 fi 62116 62117 if test "x$FOUND_FREETYPE" = xyes; then 62118 # Include file found, let's continue the sanity check. 62119 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62120 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62121 62122 # Reset to default value 62123 FREETYPE_BASE_NAME=freetype 62124 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62125 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62126 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62127 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62128 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62129 # for the .6 version explicitly. 62130 FREETYPE_BASE_NAME=freetype.6 62131 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62132 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62133 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62134 else 62135 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62136 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62137 FOUND_FREETYPE=no 62138 fi 62139 else 62140 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62141 # On Windows, we will need both .lib and .dll file. 62142 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62143 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62144 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62145 FOUND_FREETYPE=no 62146 fi 62147 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62148 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62149 # Found lib in isa dir, use that instead. 62150 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62151 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62152 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62153 fi 62154 fi 62155 fi 62156 62157 if test "x$FOUND_FREETYPE" = xyes; then 62158 62159 # Only process if variable expands to non-empty 62160 62161 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62162 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62163 62164 # Input might be given as Windows format, start by converting to 62165 # unix format. 62166 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62167 new_path=`$CYGPATH -u "$path"` 62168 62169 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62170 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62171 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62172 # "foo.exe" is OK but "foo" is an error. 62173 # 62174 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62175 # It is also a way to make sure we got the proper file name for the real test later on. 62176 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62177 if test "x$test_shortpath" = x; then 62178 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62179 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62180 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62181 fi 62182 62183 # Call helper function which possibly converts this using DOS-style short mode. 62184 # If so, the updated path is stored in $new_path. 62185 62186 input_path="$new_path" 62187 # Check if we need to convert this using DOS-style short mode. If the path 62188 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62189 # take no chances and rewrite it. 62190 # Note: m4 eats our [], so we need to use [ and ] instead. 62191 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62192 if test "x$has_forbidden_chars" != x; then 62193 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62194 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62195 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62196 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62197 # Going to short mode and back again did indeed matter. Since short mode is 62198 # case insensitive, let's make it lowercase to improve readability. 62199 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62200 # Now convert it back to Unix-style (cygpath) 62201 input_path=`$CYGPATH -u "$shortmode_path"` 62202 new_path="$input_path" 62203 fi 62204 fi 62205 62206 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62207 if test "x$test_cygdrive_prefix" = x; then 62208 # As a simple fix, exclude /usr/bin since it's not a real path. 62209 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62210 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62211 # a path prefixed by /cygdrive for fixpath to work. 62212 new_path="$CYGWIN_ROOT_PATH$input_path" 62213 fi 62214 fi 62215 62216 62217 if test "x$path" != "x$new_path"; then 62218 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62219 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62220 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62221 fi 62222 62223 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62224 62225 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62226 has_colon=`$ECHO $path | $GREP ^.:` 62227 new_path="$path" 62228 if test "x$has_colon" = x; then 62229 # Not in mixed or Windows style, start by that. 62230 new_path=`cmd //c echo $path` 62231 fi 62232 62233 62234 input_path="$new_path" 62235 # Check if we need to convert this using DOS-style short mode. If the path 62236 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62237 # take no chances and rewrite it. 62238 # Note: m4 eats our [], so we need to use [ and ] instead. 62239 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62240 if test "x$has_forbidden_chars" != x; then 62241 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62242 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62243 fi 62244 62245 62246 windows_path="$new_path" 62247 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62248 unix_path=`$CYGPATH -u "$windows_path"` 62249 new_path="$unix_path" 62250 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62251 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62252 new_path="$unix_path" 62253 fi 62254 62255 if test "x$path" != "x$new_path"; then 62256 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62257 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62258 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62259 fi 62260 62261 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62262 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62263 62264 else 62265 # We're on a unix platform. Hooray! :) 62266 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62267 has_space=`$ECHO "$path" | $GREP " "` 62268 if test "x$has_space" != x; then 62269 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62270 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62271 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62272 fi 62273 62274 # Use eval to expand a potential ~ 62275 eval path="$path" 62276 if test ! -f "$path" && test ! -d "$path"; then 62277 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62278 fi 62279 62280 if test -d "$path"; then 62281 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62282 else 62283 dir="`$DIRNAME "$path"`" 62284 base="`$BASENAME "$path"`" 62285 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62286 fi 62287 fi 62288 fi 62289 62290 62291 # Only process if variable expands to non-empty 62292 62293 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62294 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62295 62296 # Input might be given as Windows format, start by converting to 62297 # unix format. 62298 path="$POTENTIAL_FREETYPE_LIB_PATH" 62299 new_path=`$CYGPATH -u "$path"` 62300 62301 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62302 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62303 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62304 # "foo.exe" is OK but "foo" is an error. 62305 # 62306 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62307 # It is also a way to make sure we got the proper file name for the real test later on. 62308 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62309 if test "x$test_shortpath" = x; then 62310 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62311 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62312 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62313 fi 62314 62315 # Call helper function which possibly converts this using DOS-style short mode. 62316 # If so, the updated path is stored in $new_path. 62317 62318 input_path="$new_path" 62319 # Check if we need to convert this using DOS-style short mode. If the path 62320 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62321 # take no chances and rewrite it. 62322 # Note: m4 eats our [], so we need to use [ and ] instead. 62323 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62324 if test "x$has_forbidden_chars" != x; then 62325 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62326 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62327 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62328 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62329 # Going to short mode and back again did indeed matter. Since short mode is 62330 # case insensitive, let's make it lowercase to improve readability. 62331 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62332 # Now convert it back to Unix-style (cygpath) 62333 input_path=`$CYGPATH -u "$shortmode_path"` 62334 new_path="$input_path" 62335 fi 62336 fi 62337 62338 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62339 if test "x$test_cygdrive_prefix" = x; then 62340 # As a simple fix, exclude /usr/bin since it's not a real path. 62341 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62342 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62343 # a path prefixed by /cygdrive for fixpath to work. 62344 new_path="$CYGWIN_ROOT_PATH$input_path" 62345 fi 62346 fi 62347 62348 62349 if test "x$path" != "x$new_path"; then 62350 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62351 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62352 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62353 fi 62354 62355 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62356 62357 path="$POTENTIAL_FREETYPE_LIB_PATH" 62358 has_colon=`$ECHO $path | $GREP ^.:` 62359 new_path="$path" 62360 if test "x$has_colon" = x; then 62361 # Not in mixed or Windows style, start by that. 62362 new_path=`cmd //c echo $path` 62363 fi 62364 62365 62366 input_path="$new_path" 62367 # Check if we need to convert this using DOS-style short mode. If the path 62368 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62369 # take no chances and rewrite it. 62370 # Note: m4 eats our [], so we need to use [ and ] instead. 62371 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62372 if test "x$has_forbidden_chars" != x; then 62373 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62374 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62375 fi 62376 62377 62378 windows_path="$new_path" 62379 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62380 unix_path=`$CYGPATH -u "$windows_path"` 62381 new_path="$unix_path" 62382 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62383 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62384 new_path="$unix_path" 62385 fi 62386 62387 if test "x$path" != "x$new_path"; then 62388 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62389 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62390 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62391 fi 62392 62393 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62394 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62395 62396 else 62397 # We're on a unix platform. Hooray! :) 62398 path="$POTENTIAL_FREETYPE_LIB_PATH" 62399 has_space=`$ECHO "$path" | $GREP " "` 62400 if test "x$has_space" != x; then 62401 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62402 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62403 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62404 fi 62405 62406 # Use eval to expand a potential ~ 62407 eval path="$path" 62408 if test ! -f "$path" && test ! -d "$path"; then 62409 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62410 fi 62411 62412 if test -d "$path"; then 62413 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62414 else 62415 dir="`$DIRNAME "$path"`" 62416 base="`$BASENAME "$path"`" 62417 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62418 fi 62419 fi 62420 fi 62421 62422 62423 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62424 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62425 $as_echo_n "checking for freetype includes... " >&6; } 62426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62427 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62428 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62430 $as_echo_n "checking for freetype libraries... " >&6; } 62431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62432 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62433 fi 62434 62435 fi 62436 62437 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 62438 if test "x$FOUND_FREETYPE" != xyes; then 62439 # Due to changes in OSX 10.11 XQuartz now installs to /opt/X11 62440 FREETYPE_BASE_DIR="$SYSROOT/opt/X11" 62441 62442 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62443 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 62444 METHOD="well-known location" 62445 62446 # Let's start with an optimistic view of the world :-) 62447 FOUND_FREETYPE=yes 62448 62449 # First look for the canonical freetype main include file ft2build.h. 62450 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62451 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62452 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62453 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62454 # Fail. 62455 FOUND_FREETYPE=no 62456 fi 62457 fi 62458 62459 if test "x$FOUND_FREETYPE" = xyes; then 62460 # Include file found, let's continue the sanity check. 62461 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62462 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62463 62464 # Reset to default value 62465 FREETYPE_BASE_NAME=freetype 62466 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62467 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62468 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62469 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62470 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62471 # for the .6 version explicitly. 62472 FREETYPE_BASE_NAME=freetype.6 62473 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62474 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62475 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62476 else 62477 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62478 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62479 FOUND_FREETYPE=no 62480 fi 62481 else 62482 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62483 # On Windows, we will need both .lib and .dll file. 62484 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62485 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62486 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62487 FOUND_FREETYPE=no 62488 fi 62489 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62490 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62491 # Found lib in isa dir, use that instead. 62492 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62493 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62494 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62495 fi 62496 fi 62497 fi 62498 62499 if test "x$FOUND_FREETYPE" = xyes; then 62500 62501 # Only process if variable expands to non-empty 62502 62503 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62504 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62505 62506 # Input might be given as Windows format, start by converting to 62507 # unix format. 62508 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62509 new_path=`$CYGPATH -u "$path"` 62510 62511 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62512 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62513 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62514 # "foo.exe" is OK but "foo" is an error. 62515 # 62516 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62517 # It is also a way to make sure we got the proper file name for the real test later on. 62518 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62519 if test "x$test_shortpath" = x; then 62520 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62521 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62522 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62523 fi 62524 62525 # Call helper function which possibly converts this using DOS-style short mode. 62526 # If so, the updated path is stored in $new_path. 62527 62528 input_path="$new_path" 62529 # Check if we need to convert this using DOS-style short mode. If the path 62530 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62531 # take no chances and rewrite it. 62532 # Note: m4 eats our [], so we need to use [ and ] instead. 62533 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62534 if test "x$has_forbidden_chars" != x; then 62535 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62536 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62537 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62538 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62539 # Going to short mode and back again did indeed matter. Since short mode is 62540 # case insensitive, let's make it lowercase to improve readability. 62541 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62542 # Now convert it back to Unix-style (cygpath) 62543 input_path=`$CYGPATH -u "$shortmode_path"` 62544 new_path="$input_path" 62545 fi 62546 fi 62547 62548 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62549 if test "x$test_cygdrive_prefix" = x; then 62550 # As a simple fix, exclude /usr/bin since it's not a real path. 62551 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62552 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62553 # a path prefixed by /cygdrive for fixpath to work. 62554 new_path="$CYGWIN_ROOT_PATH$input_path" 62555 fi 62556 fi 62557 62558 62559 if test "x$path" != "x$new_path"; then 62560 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62561 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62562 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62563 fi 62564 62565 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62566 62567 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62568 has_colon=`$ECHO $path | $GREP ^.:` 62569 new_path="$path" 62570 if test "x$has_colon" = x; then 62571 # Not in mixed or Windows style, start by that. 62572 new_path=`cmd //c echo $path` 62573 fi 62574 62575 62576 input_path="$new_path" 62577 # Check if we need to convert this using DOS-style short mode. If the path 62578 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62579 # take no chances and rewrite it. 62580 # Note: m4 eats our [], so we need to use [ and ] instead. 62581 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62582 if test "x$has_forbidden_chars" != x; then 62583 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62584 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62585 fi 62586 62587 62588 windows_path="$new_path" 62589 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62590 unix_path=`$CYGPATH -u "$windows_path"` 62591 new_path="$unix_path" 62592 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62593 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62594 new_path="$unix_path" 62595 fi 62596 62597 if test "x$path" != "x$new_path"; then 62598 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62599 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62600 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62601 fi 62602 62603 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62604 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62605 62606 else 62607 # We're on a unix platform. Hooray! :) 62608 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62609 has_space=`$ECHO "$path" | $GREP " "` 62610 if test "x$has_space" != x; then 62611 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62612 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62613 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62614 fi 62615 62616 # Use eval to expand a potential ~ 62617 eval path="$path" 62618 if test ! -f "$path" && test ! -d "$path"; then 62619 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62620 fi 62621 62622 if test -d "$path"; then 62623 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62624 else 62625 dir="`$DIRNAME "$path"`" 62626 base="`$BASENAME "$path"`" 62627 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62628 fi 62629 fi 62630 fi 62631 62632 62633 # Only process if variable expands to non-empty 62634 62635 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62636 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62637 62638 # Input might be given as Windows format, start by converting to 62639 # unix format. 62640 path="$POTENTIAL_FREETYPE_LIB_PATH" 62641 new_path=`$CYGPATH -u "$path"` 62642 62643 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62644 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62645 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62646 # "foo.exe" is OK but "foo" is an error. 62647 # 62648 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62649 # It is also a way to make sure we got the proper file name for the real test later on. 62650 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62651 if test "x$test_shortpath" = x; then 62652 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62653 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62654 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62655 fi 62656 62657 # Call helper function which possibly converts this using DOS-style short mode. 62658 # If so, the updated path is stored in $new_path. 62659 62660 input_path="$new_path" 62661 # Check if we need to convert this using DOS-style short mode. If the path 62662 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62663 # take no chances and rewrite it. 62664 # Note: m4 eats our [], so we need to use [ and ] instead. 62665 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62666 if test "x$has_forbidden_chars" != x; then 62667 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62668 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62669 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62670 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62671 # Going to short mode and back again did indeed matter. Since short mode is 62672 # case insensitive, let's make it lowercase to improve readability. 62673 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62674 # Now convert it back to Unix-style (cygpath) 62675 input_path=`$CYGPATH -u "$shortmode_path"` 62676 new_path="$input_path" 62677 fi 62678 fi 62679 62680 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62681 if test "x$test_cygdrive_prefix" = x; then 62682 # As a simple fix, exclude /usr/bin since it's not a real path. 62683 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62684 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62685 # a path prefixed by /cygdrive for fixpath to work. 62686 new_path="$CYGWIN_ROOT_PATH$input_path" 62687 fi 62688 fi 62689 62690 62691 if test "x$path" != "x$new_path"; then 62692 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62693 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62694 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62695 fi 62696 62697 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62698 62699 path="$POTENTIAL_FREETYPE_LIB_PATH" 62700 has_colon=`$ECHO $path | $GREP ^.:` 62701 new_path="$path" 62702 if test "x$has_colon" = x; then 62703 # Not in mixed or Windows style, start by that. 62704 new_path=`cmd //c echo $path` 62705 fi 62706 62707 62708 input_path="$new_path" 62709 # Check if we need to convert this using DOS-style short mode. If the path 62710 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62711 # take no chances and rewrite it. 62712 # Note: m4 eats our [], so we need to use [ and ] instead. 62713 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62714 if test "x$has_forbidden_chars" != x; then 62715 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62716 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62717 fi 62718 62719 62720 windows_path="$new_path" 62721 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62722 unix_path=`$CYGPATH -u "$windows_path"` 62723 new_path="$unix_path" 62724 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62725 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62726 new_path="$unix_path" 62727 fi 62728 62729 if test "x$path" != "x$new_path"; then 62730 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62731 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62732 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62733 fi 62734 62735 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62736 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62737 62738 else 62739 # We're on a unix platform. Hooray! :) 62740 path="$POTENTIAL_FREETYPE_LIB_PATH" 62741 has_space=`$ECHO "$path" | $GREP " "` 62742 if test "x$has_space" != x; then 62743 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62744 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62745 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62746 fi 62747 62748 # Use eval to expand a potential ~ 62749 eval path="$path" 62750 if test ! -f "$path" && test ! -d "$path"; then 62751 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62752 fi 62753 62754 if test -d "$path"; then 62755 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62756 else 62757 dir="`$DIRNAME "$path"`" 62758 base="`$BASENAME "$path"`" 62759 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62760 fi 62761 fi 62762 fi 62763 62764 62765 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62767 $as_echo_n "checking for freetype includes... " >&6; } 62768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62769 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62770 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62772 $as_echo_n "checking for freetype libraries... " >&6; } 62773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62774 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62775 fi 62776 62777 fi 62778 fi 62779 62780 if test "x$FOUND_FREETYPE" != xyes; then 62781 FREETYPE_BASE_DIR="$SYSROOT/usr" 62782 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 62783 62784 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62785 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/$OPENJDK_TARGET_CPU-linux-gnu" 62786 METHOD="well-known location" 62787 62788 # Let's start with an optimistic view of the world :-) 62789 FOUND_FREETYPE=yes 62790 62791 # First look for the canonical freetype main include file ft2build.h. 62792 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62793 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62794 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62795 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62796 # Fail. 62797 FOUND_FREETYPE=no 62798 fi 62799 fi 62800 62801 if test "x$FOUND_FREETYPE" = xyes; then 62802 # Include file found, let's continue the sanity check. 62803 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62804 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62805 62806 # Reset to default value 62807 FREETYPE_BASE_NAME=freetype 62808 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62809 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62810 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62811 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62812 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62813 # for the .6 version explicitly. 62814 FREETYPE_BASE_NAME=freetype.6 62815 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62816 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62817 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62818 else 62819 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62820 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62821 FOUND_FREETYPE=no 62822 fi 62823 else 62824 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62825 # On Windows, we will need both .lib and .dll file. 62826 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62827 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62828 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62829 FOUND_FREETYPE=no 62830 fi 62831 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62832 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62833 # Found lib in isa dir, use that instead. 62834 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62835 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62836 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62837 fi 62838 fi 62839 fi 62840 62841 if test "x$FOUND_FREETYPE" = xyes; then 62842 62843 # Only process if variable expands to non-empty 62844 62845 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62846 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62847 62848 # Input might be given as Windows format, start by converting to 62849 # unix format. 62850 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62851 new_path=`$CYGPATH -u "$path"` 62852 62853 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62854 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62855 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62856 # "foo.exe" is OK but "foo" is an error. 62857 # 62858 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62859 # It is also a way to make sure we got the proper file name for the real test later on. 62860 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62861 if test "x$test_shortpath" = x; then 62862 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62863 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62864 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62865 fi 62866 62867 # Call helper function which possibly converts this using DOS-style short mode. 62868 # If so, the updated path is stored in $new_path. 62869 62870 input_path="$new_path" 62871 # Check if we need to convert this using DOS-style short mode. If the path 62872 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62873 # take no chances and rewrite it. 62874 # Note: m4 eats our [], so we need to use [ and ] instead. 62875 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62876 if test "x$has_forbidden_chars" != x; then 62877 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62878 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62879 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62880 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62881 # Going to short mode and back again did indeed matter. Since short mode is 62882 # case insensitive, let's make it lowercase to improve readability. 62883 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62884 # Now convert it back to Unix-style (cygpath) 62885 input_path=`$CYGPATH -u "$shortmode_path"` 62886 new_path="$input_path" 62887 fi 62888 fi 62889 62890 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62891 if test "x$test_cygdrive_prefix" = x; then 62892 # As a simple fix, exclude /usr/bin since it's not a real path. 62893 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62894 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62895 # a path prefixed by /cygdrive for fixpath to work. 62896 new_path="$CYGWIN_ROOT_PATH$input_path" 62897 fi 62898 fi 62899 62900 62901 if test "x$path" != "x$new_path"; then 62902 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62903 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62904 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62905 fi 62906 62907 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62908 62909 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62910 has_colon=`$ECHO $path | $GREP ^.:` 62911 new_path="$path" 62912 if test "x$has_colon" = x; then 62913 # Not in mixed or Windows style, start by that. 62914 new_path=`cmd //c echo $path` 62915 fi 62916 62917 62918 input_path="$new_path" 62919 # Check if we need to convert this using DOS-style short mode. If the path 62920 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62921 # take no chances and rewrite it. 62922 # Note: m4 eats our [], so we need to use [ and ] instead. 62923 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62924 if test "x$has_forbidden_chars" != x; then 62925 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62926 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62927 fi 62928 62929 62930 windows_path="$new_path" 62931 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62932 unix_path=`$CYGPATH -u "$windows_path"` 62933 new_path="$unix_path" 62934 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62935 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62936 new_path="$unix_path" 62937 fi 62938 62939 if test "x$path" != "x$new_path"; then 62940 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62941 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62942 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62943 fi 62944 62945 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62946 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62947 62948 else 62949 # We're on a unix platform. Hooray! :) 62950 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62951 has_space=`$ECHO "$path" | $GREP " "` 62952 if test "x$has_space" != x; then 62953 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62954 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62955 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62956 fi 62957 62958 # Use eval to expand a potential ~ 62959 eval path="$path" 62960 if test ! -f "$path" && test ! -d "$path"; then 62961 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62962 fi 62963 62964 if test -d "$path"; then 62965 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62966 else 62967 dir="`$DIRNAME "$path"`" 62968 base="`$BASENAME "$path"`" 62969 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62970 fi 62971 fi 62972 fi 62973 62974 62975 # Only process if variable expands to non-empty 62976 62977 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62978 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62979 62980 # Input might be given as Windows format, start by converting to 62981 # unix format. 62982 path="$POTENTIAL_FREETYPE_LIB_PATH" 62983 new_path=`$CYGPATH -u "$path"` 62984 62985 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62986 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62987 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62988 # "foo.exe" is OK but "foo" is an error. 62989 # 62990 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62991 # It is also a way to make sure we got the proper file name for the real test later on. 62992 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62993 if test "x$test_shortpath" = x; then 62994 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62995 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62996 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62997 fi 62998 62999 # Call helper function which possibly converts this using DOS-style short mode. 63000 # If so, the updated path is stored in $new_path. 63001 63002 input_path="$new_path" 63003 # Check if we need to convert this using DOS-style short mode. If the path 63004 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63005 # take no chances and rewrite it. 63006 # Note: m4 eats our [], so we need to use [ and ] instead. 63007 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63008 if test "x$has_forbidden_chars" != x; then 63009 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63010 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63011 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63012 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63013 # Going to short mode and back again did indeed matter. Since short mode is 63014 # case insensitive, let's make it lowercase to improve readability. 63015 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63016 # Now convert it back to Unix-style (cygpath) 63017 input_path=`$CYGPATH -u "$shortmode_path"` 63018 new_path="$input_path" 63019 fi 63020 fi 63021 63022 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63023 if test "x$test_cygdrive_prefix" = x; then 63024 # As a simple fix, exclude /usr/bin since it's not a real path. 63025 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63026 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63027 # a path prefixed by /cygdrive for fixpath to work. 63028 new_path="$CYGWIN_ROOT_PATH$input_path" 63029 fi 63030 fi 63031 63032 63033 if test "x$path" != "x$new_path"; then 63034 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63035 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63036 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63037 fi 63038 63039 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63040 63041 path="$POTENTIAL_FREETYPE_LIB_PATH" 63042 has_colon=`$ECHO $path | $GREP ^.:` 63043 new_path="$path" 63044 if test "x$has_colon" = x; then 63045 # Not in mixed or Windows style, start by that. 63046 new_path=`cmd //c echo $path` 63047 fi 63048 63049 63050 input_path="$new_path" 63051 # Check if we need to convert this using DOS-style short mode. If the path 63052 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63053 # take no chances and rewrite it. 63054 # Note: m4 eats our [], so we need to use [ and ] instead. 63055 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63056 if test "x$has_forbidden_chars" != x; then 63057 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63058 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63059 fi 63060 63061 63062 windows_path="$new_path" 63063 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63064 unix_path=`$CYGPATH -u "$windows_path"` 63065 new_path="$unix_path" 63066 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63067 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63068 new_path="$unix_path" 63069 fi 63070 63071 if test "x$path" != "x$new_path"; then 63072 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63073 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63074 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63075 fi 63076 63077 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63078 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63079 63080 else 63081 # We're on a unix platform. Hooray! :) 63082 path="$POTENTIAL_FREETYPE_LIB_PATH" 63083 has_space=`$ECHO "$path" | $GREP " "` 63084 if test "x$has_space" != x; then 63085 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63086 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63087 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63088 fi 63089 63090 # Use eval to expand a potential ~ 63091 eval path="$path" 63092 if test ! -f "$path" && test ! -d "$path"; then 63093 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63094 fi 63095 63096 if test -d "$path"; then 63097 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 63098 else 63099 dir="`$DIRNAME "$path"`" 63100 base="`$BASENAME "$path"`" 63101 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63102 fi 63103 fi 63104 fi 63105 63106 63107 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 63109 $as_echo_n "checking for freetype includes... " >&6; } 63110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 63111 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 63112 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 63113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 63114 $as_echo_n "checking for freetype libraries... " >&6; } 63115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 63116 $as_echo "$FREETYPE_LIB_PATH" >&6; } 63117 fi 63118 63119 else 63120 63121 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 63122 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu" 63123 METHOD="well-known location" 63124 63125 # Let's start with an optimistic view of the world :-) 63126 FOUND_FREETYPE=yes 63127 63128 # First look for the canonical freetype main include file ft2build.h. 63129 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63130 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 63131 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 63132 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63133 # Fail. 63134 FOUND_FREETYPE=no 63135 fi 63136 fi 63137 63138 if test "x$FOUND_FREETYPE" = xyes; then 63139 # Include file found, let's continue the sanity check. 63140 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 63141 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 63142 63143 # Reset to default value 63144 FREETYPE_BASE_NAME=freetype 63145 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63146 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 63147 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 63148 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 63149 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 63150 # for the .6 version explicitly. 63151 FREETYPE_BASE_NAME=freetype.6 63152 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63153 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 63154 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 63155 else 63156 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 63157 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 63158 FOUND_FREETYPE=no 63159 fi 63160 else 63161 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63162 # On Windows, we will need both .lib and .dll file. 63163 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 63164 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 63165 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 63166 FOUND_FREETYPE=no 63167 fi 63168 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 63169 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 63170 # Found lib in isa dir, use that instead. 63171 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 63172 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 63173 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 63174 fi 63175 fi 63176 fi 63177 63178 if test "x$FOUND_FREETYPE" = xyes; then 63179 63180 # Only process if variable expands to non-empty 63181 63182 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 63183 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63184 63185 # Input might be given as Windows format, start by converting to 63186 # unix format. 63187 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63188 new_path=`$CYGPATH -u "$path"` 63189 63190 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63191 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63192 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63193 # "foo.exe" is OK but "foo" is an error. 63194 # 63195 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63196 # It is also a way to make sure we got the proper file name for the real test later on. 63197 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63198 if test "x$test_shortpath" = x; then 63199 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63200 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63201 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 63202 fi 63203 63204 # Call helper function which possibly converts this using DOS-style short mode. 63205 # If so, the updated path is stored in $new_path. 63206 63207 input_path="$new_path" 63208 # Check if we need to convert this using DOS-style short mode. If the path 63209 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63210 # take no chances and rewrite it. 63211 # Note: m4 eats our [], so we need to use [ and ] instead. 63212 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63213 if test "x$has_forbidden_chars" != x; then 63214 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63215 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63216 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63217 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63218 # Going to short mode and back again did indeed matter. Since short mode is 63219 # case insensitive, let's make it lowercase to improve readability. 63220 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63221 # Now convert it back to Unix-style (cygpath) 63222 input_path=`$CYGPATH -u "$shortmode_path"` 63223 new_path="$input_path" 63224 fi 63225 fi 63226 63227 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63228 if test "x$test_cygdrive_prefix" = x; then 63229 # As a simple fix, exclude /usr/bin since it's not a real path. 63230 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63231 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63232 # a path prefixed by /cygdrive for fixpath to work. 63233 new_path="$CYGWIN_ROOT_PATH$input_path" 63234 fi 63235 fi 63236 63237 63238 if test "x$path" != "x$new_path"; then 63239 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63240 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63241 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63242 fi 63243 63244 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63245 63246 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63247 has_colon=`$ECHO $path | $GREP ^.:` 63248 new_path="$path" 63249 if test "x$has_colon" = x; then 63250 # Not in mixed or Windows style, start by that. 63251 new_path=`cmd //c echo $path` 63252 fi 63253 63254 63255 input_path="$new_path" 63256 # Check if we need to convert this using DOS-style short mode. If the path 63257 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63258 # take no chances and rewrite it. 63259 # Note: m4 eats our [], so we need to use [ and ] instead. 63260 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63261 if test "x$has_forbidden_chars" != x; then 63262 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63263 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63264 fi 63265 63266 63267 windows_path="$new_path" 63268 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63269 unix_path=`$CYGPATH -u "$windows_path"` 63270 new_path="$unix_path" 63271 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63272 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63273 new_path="$unix_path" 63274 fi 63275 63276 if test "x$path" != "x$new_path"; then 63277 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63278 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63279 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63280 fi 63281 63282 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63283 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63284 63285 else 63286 # We're on a unix platform. Hooray! :) 63287 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63288 has_space=`$ECHO "$path" | $GREP " "` 63289 if test "x$has_space" != x; then 63290 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63291 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63292 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63293 fi 63294 63295 # Use eval to expand a potential ~ 63296 eval path="$path" 63297 if test ! -f "$path" && test ! -d "$path"; then 63298 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63299 fi 63300 63301 if test -d "$path"; then 63302 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 63303 else 63304 dir="`$DIRNAME "$path"`" 63305 base="`$BASENAME "$path"`" 63306 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63307 fi 63308 fi 63309 fi 63310 63311 63312 # Only process if variable expands to non-empty 63313 63314 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 63315 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63316 63317 # Input might be given as Windows format, start by converting to 63318 # unix format. 63319 path="$POTENTIAL_FREETYPE_LIB_PATH" 63320 new_path=`$CYGPATH -u "$path"` 63321 63322 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63323 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63324 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63325 # "foo.exe" is OK but "foo" is an error. 63326 # 63327 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63328 # It is also a way to make sure we got the proper file name for the real test later on. 63329 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63330 if test "x$test_shortpath" = x; then 63331 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63332 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63333 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 63334 fi 63335 63336 # Call helper function which possibly converts this using DOS-style short mode. 63337 # If so, the updated path is stored in $new_path. 63338 63339 input_path="$new_path" 63340 # Check if we need to convert this using DOS-style short mode. If the path 63341 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63342 # take no chances and rewrite it. 63343 # Note: m4 eats our [], so we need to use [ and ] instead. 63344 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63345 if test "x$has_forbidden_chars" != x; then 63346 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63347 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63348 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63349 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63350 # Going to short mode and back again did indeed matter. Since short mode is 63351 # case insensitive, let's make it lowercase to improve readability. 63352 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63353 # Now convert it back to Unix-style (cygpath) 63354 input_path=`$CYGPATH -u "$shortmode_path"` 63355 new_path="$input_path" 63356 fi 63357 fi 63358 63359 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63360 if test "x$test_cygdrive_prefix" = x; then 63361 # As a simple fix, exclude /usr/bin since it's not a real path. 63362 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63363 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63364 # a path prefixed by /cygdrive for fixpath to work. 63365 new_path="$CYGWIN_ROOT_PATH$input_path" 63366 fi 63367 fi 63368 63369 63370 if test "x$path" != "x$new_path"; then 63371 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63372 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63373 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63374 fi 63375 63376 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63377 63378 path="$POTENTIAL_FREETYPE_LIB_PATH" 63379 has_colon=`$ECHO $path | $GREP ^.:` 63380 new_path="$path" 63381 if test "x$has_colon" = x; then 63382 # Not in mixed or Windows style, start by that. 63383 new_path=`cmd //c echo $path` 63384 fi 63385 63386 63387 input_path="$new_path" 63388 # Check if we need to convert this using DOS-style short mode. If the path 63389 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63390 # take no chances and rewrite it. 63391 # Note: m4 eats our [], so we need to use [ and ] instead. 63392 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63393 if test "x$has_forbidden_chars" != x; then 63394 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63395 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63396 fi 63397 63398 63399 windows_path="$new_path" 63400 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63401 unix_path=`$CYGPATH -u "$windows_path"` 63402 new_path="$unix_path" 63403 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63404 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63405 new_path="$unix_path" 63406 fi 63407 63408 if test "x$path" != "x$new_path"; then 63409 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63410 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63411 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63412 fi 63413 63414 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63415 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63416 63417 else 63418 # We're on a unix platform. Hooray! :) 63419 path="$POTENTIAL_FREETYPE_LIB_PATH" 63420 has_space=`$ECHO "$path" | $GREP " "` 63421 if test "x$has_space" != x; then 63422 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63423 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63424 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63425 fi 63426 63427 # Use eval to expand a potential ~ 63428 eval path="$path" 63429 if test ! -f "$path" && test ! -d "$path"; then 63430 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63431 fi 63432 63433 if test -d "$path"; then 63434 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 63435 else 63436 dir="`$DIRNAME "$path"`" 63437 base="`$BASENAME "$path"`" 63438 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63439 fi 63440 fi 63441 fi 63442 63443 63444 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 63446 $as_echo_n "checking for freetype includes... " >&6; } 63447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 63448 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 63449 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 63450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 63451 $as_echo_n "checking for freetype libraries... " >&6; } 63452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 63453 $as_echo "$FREETYPE_LIB_PATH" >&6; } 63454 fi 63455 63456 if test "x$FOUND_FREETYPE" != xyes; then 63457 63458 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 63459 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 63460 METHOD="well-known location" 63461 63462 # Let's start with an optimistic view of the world :-) 63463 FOUND_FREETYPE=yes 63464 63465 # First look for the canonical freetype main include file ft2build.h. 63466 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63467 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 63468 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 63469 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63470 # Fail. 63471 FOUND_FREETYPE=no 63472 fi 63473 fi 63474 63475 if test "x$FOUND_FREETYPE" = xyes; then 63476 # Include file found, let's continue the sanity check. 63477 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 63478 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 63479 63480 # Reset to default value 63481 FREETYPE_BASE_NAME=freetype 63482 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63483 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 63484 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 63485 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 63486 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 63487 # for the .6 version explicitly. 63488 FREETYPE_BASE_NAME=freetype.6 63489 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63490 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 63491 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 63492 else 63493 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 63494 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 63495 FOUND_FREETYPE=no 63496 fi 63497 else 63498 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63499 # On Windows, we will need both .lib and .dll file. 63500 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 63501 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 63502 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 63503 FOUND_FREETYPE=no 63504 fi 63505 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 63506 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 63507 # Found lib in isa dir, use that instead. 63508 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 63509 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 63510 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 63511 fi 63512 fi 63513 fi 63514 63515 if test "x$FOUND_FREETYPE" = xyes; then 63516 63517 # Only process if variable expands to non-empty 63518 63519 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 63520 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63521 63522 # Input might be given as Windows format, start by converting to 63523 # unix format. 63524 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63525 new_path=`$CYGPATH -u "$path"` 63526 63527 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63528 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63529 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63530 # "foo.exe" is OK but "foo" is an error. 63531 # 63532 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63533 # It is also a way to make sure we got the proper file name for the real test later on. 63534 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63535 if test "x$test_shortpath" = x; then 63536 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63537 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63538 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 63539 fi 63540 63541 # Call helper function which possibly converts this using DOS-style short mode. 63542 # If so, the updated path is stored in $new_path. 63543 63544 input_path="$new_path" 63545 # Check if we need to convert this using DOS-style short mode. If the path 63546 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63547 # take no chances and rewrite it. 63548 # Note: m4 eats our [], so we need to use [ and ] instead. 63549 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63550 if test "x$has_forbidden_chars" != x; then 63551 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63552 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63553 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63554 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63555 # Going to short mode and back again did indeed matter. Since short mode is 63556 # case insensitive, let's make it lowercase to improve readability. 63557 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63558 # Now convert it back to Unix-style (cygpath) 63559 input_path=`$CYGPATH -u "$shortmode_path"` 63560 new_path="$input_path" 63561 fi 63562 fi 63563 63564 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63565 if test "x$test_cygdrive_prefix" = x; then 63566 # As a simple fix, exclude /usr/bin since it's not a real path. 63567 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63568 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63569 # a path prefixed by /cygdrive for fixpath to work. 63570 new_path="$CYGWIN_ROOT_PATH$input_path" 63571 fi 63572 fi 63573 63574 63575 if test "x$path" != "x$new_path"; then 63576 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63577 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63578 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63579 fi 63580 63581 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63582 63583 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63584 has_colon=`$ECHO $path | $GREP ^.:` 63585 new_path="$path" 63586 if test "x$has_colon" = x; then 63587 # Not in mixed or Windows style, start by that. 63588 new_path=`cmd //c echo $path` 63589 fi 63590 63591 63592 input_path="$new_path" 63593 # Check if we need to convert this using DOS-style short mode. If the path 63594 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63595 # take no chances and rewrite it. 63596 # Note: m4 eats our [], so we need to use [ and ] instead. 63597 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63598 if test "x$has_forbidden_chars" != x; then 63599 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63600 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63601 fi 63602 63603 63604 windows_path="$new_path" 63605 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63606 unix_path=`$CYGPATH -u "$windows_path"` 63607 new_path="$unix_path" 63608 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63609 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63610 new_path="$unix_path" 63611 fi 63612 63613 if test "x$path" != "x$new_path"; then 63614 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63615 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63616 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63617 fi 63618 63619 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63620 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63621 63622 else 63623 # We're on a unix platform. Hooray! :) 63624 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63625 has_space=`$ECHO "$path" | $GREP " "` 63626 if test "x$has_space" != x; then 63627 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63628 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63629 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63630 fi 63631 63632 # Use eval to expand a potential ~ 63633 eval path="$path" 63634 if test ! -f "$path" && test ! -d "$path"; then 63635 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63636 fi 63637 63638 if test -d "$path"; then 63639 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 63640 else 63641 dir="`$DIRNAME "$path"`" 63642 base="`$BASENAME "$path"`" 63643 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63644 fi 63645 fi 63646 fi 63647 63648 63649 # Only process if variable expands to non-empty 63650 63651 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 63652 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63653 63654 # Input might be given as Windows format, start by converting to 63655 # unix format. 63656 path="$POTENTIAL_FREETYPE_LIB_PATH" 63657 new_path=`$CYGPATH -u "$path"` 63658 63659 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63660 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63661 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63662 # "foo.exe" is OK but "foo" is an error. 63663 # 63664 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63665 # It is also a way to make sure we got the proper file name for the real test later on. 63666 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63667 if test "x$test_shortpath" = x; then 63668 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63669 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63670 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 63671 fi 63672 63673 # Call helper function which possibly converts this using DOS-style short mode. 63674 # If so, the updated path is stored in $new_path. 63675 63676 input_path="$new_path" 63677 # Check if we need to convert this using DOS-style short mode. If the path 63678 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63679 # take no chances and rewrite it. 63680 # Note: m4 eats our [], so we need to use [ and ] instead. 63681 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63682 if test "x$has_forbidden_chars" != x; then 63683 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63684 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63685 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63686 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63687 # Going to short mode and back again did indeed matter. Since short mode is 63688 # case insensitive, let's make it lowercase to improve readability. 63689 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63690 # Now convert it back to Unix-style (cygpath) 63691 input_path=`$CYGPATH -u "$shortmode_path"` 63692 new_path="$input_path" 63693 fi 63694 fi 63695 63696 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63697 if test "x$test_cygdrive_prefix" = x; then 63698 # As a simple fix, exclude /usr/bin since it's not a real path. 63699 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63700 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63701 # a path prefixed by /cygdrive for fixpath to work. 63702 new_path="$CYGWIN_ROOT_PATH$input_path" 63703 fi 63704 fi 63705 63706 63707 if test "x$path" != "x$new_path"; then 63708 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63709 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63710 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63711 fi 63712 63713 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63714 63715 path="$POTENTIAL_FREETYPE_LIB_PATH" 63716 has_colon=`$ECHO $path | $GREP ^.:` 63717 new_path="$path" 63718 if test "x$has_colon" = x; then 63719 # Not in mixed or Windows style, start by that. 63720 new_path=`cmd //c echo $path` 63721 fi 63722 63723 63724 input_path="$new_path" 63725 # Check if we need to convert this using DOS-style short mode. If the path 63726 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63727 # take no chances and rewrite it. 63728 # Note: m4 eats our [], so we need to use [ and ] instead. 63729 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63730 if test "x$has_forbidden_chars" != x; then 63731 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63732 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63733 fi 63734 63735 63736 windows_path="$new_path" 63737 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63738 unix_path=`$CYGPATH -u "$windows_path"` 63739 new_path="$unix_path" 63740 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63741 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63742 new_path="$unix_path" 63743 fi 63744 63745 if test "x$path" != "x$new_path"; then 63746 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63747 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63748 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63749 fi 63750 63751 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63752 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63753 63754 else 63755 # We're on a unix platform. Hooray! :) 63756 path="$POTENTIAL_FREETYPE_LIB_PATH" 63757 has_space=`$ECHO "$path" | $GREP " "` 63758 if test "x$has_space" != x; then 63759 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63760 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63761 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63762 fi 63763 63764 # Use eval to expand a potential ~ 63765 eval path="$path" 63766 if test ! -f "$path" && test ! -d "$path"; then 63767 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63768 fi 63769 63770 if test -d "$path"; then 63771 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 63772 else 63773 dir="`$DIRNAME "$path"`" 63774 base="`$BASENAME "$path"`" 63775 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63776 fi 63777 fi 63778 fi 63779 63780 63781 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 63783 $as_echo_n "checking for freetype includes... " >&6; } 63784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 63785 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 63786 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 63787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 63788 $as_echo_n "checking for freetype libraries... " >&6; } 63789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 63790 $as_echo "$FREETYPE_LIB_PATH" >&6; } 63791 fi 63792 63793 fi 63794 fi 63795 fi 63796 fi 63797 fi # end check in well-known locations 63798 63799 if test "x$FOUND_FREETYPE" != xyes; then 63800 63801 # Print a helpful message on how to acquire the necessary build dependency. 63802 # freetype is the help tag: freetype, cups, alsa etc 63803 MISSING_DEPENDENCY=freetype 63804 63805 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63806 cygwin_help $MISSING_DEPENDENCY 63807 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63808 msys_help $MISSING_DEPENDENCY 63809 else 63810 PKGHANDLER_COMMAND= 63811 63812 case $PKGHANDLER in 63813 apt-get) 63814 apt_help $MISSING_DEPENDENCY ;; 63815 yum) 63816 yum_help $MISSING_DEPENDENCY ;; 63817 brew) 63818 brew_help $MISSING_DEPENDENCY ;; 63819 port) 63820 port_help $MISSING_DEPENDENCY ;; 63821 pkgutil) 63822 pkgutil_help $MISSING_DEPENDENCY ;; 63823 pkgadd) 63824 pkgadd_help $MISSING_DEPENDENCY ;; 63825 esac 63826 63827 if test "x$PKGHANDLER_COMMAND" != x; then 63828 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63829 fi 63830 fi 63831 63832 as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5 63833 fi 63834 fi # end user specified settings 63835 63836 # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir. 63837 if test "x$FREETYPE_CFLAGS" = x; then 63838 63839 # Only process if variable expands to non-empty 63840 63841 if test "x$FREETYPE_INCLUDE_PATH" != x; then 63842 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63843 63844 # Input might be given as Windows format, start by converting to 63845 # unix format. 63846 path="$FREETYPE_INCLUDE_PATH" 63847 new_path=`$CYGPATH -u "$path"` 63848 63849 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63850 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63851 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63852 # "foo.exe" is OK but "foo" is an error. 63853 # 63854 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63855 # It is also a way to make sure we got the proper file name for the real test later on. 63856 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63857 if test "x$test_shortpath" = x; then 63858 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63859 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63860 as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5 63861 fi 63862 63863 # Call helper function which possibly converts this using DOS-style short mode. 63864 # If so, the updated path is stored in $new_path. 63865 63866 input_path="$new_path" 63867 # Check if we need to convert this using DOS-style short mode. If the path 63868 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63869 # take no chances and rewrite it. 63870 # Note: m4 eats our [], so we need to use [ and ] instead. 63871 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63872 if test "x$has_forbidden_chars" != x; then 63873 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63874 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63875 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63876 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63877 # Going to short mode and back again did indeed matter. Since short mode is 63878 # case insensitive, let's make it lowercase to improve readability. 63879 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63880 # Now convert it back to Unix-style (cygpath) 63881 input_path=`$CYGPATH -u "$shortmode_path"` 63882 new_path="$input_path" 63883 fi 63884 fi 63885 63886 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63887 if test "x$test_cygdrive_prefix" = x; then 63888 # As a simple fix, exclude /usr/bin since it's not a real path. 63889 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63890 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63891 # a path prefixed by /cygdrive for fixpath to work. 63892 new_path="$CYGWIN_ROOT_PATH$input_path" 63893 fi 63894 fi 63895 63896 63897 if test "x$path" != "x$new_path"; then 63898 FREETYPE_INCLUDE_PATH="$new_path" 63899 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63900 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63901 fi 63902 63903 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63904 63905 path="$FREETYPE_INCLUDE_PATH" 63906 has_colon=`$ECHO $path | $GREP ^.:` 63907 new_path="$path" 63908 if test "x$has_colon" = x; then 63909 # Not in mixed or Windows style, start by that. 63910 new_path=`cmd //c echo $path` 63911 fi 63912 63913 63914 input_path="$new_path" 63915 # Check if we need to convert this using DOS-style short mode. If the path 63916 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63917 # take no chances and rewrite it. 63918 # Note: m4 eats our [], so we need to use [ and ] instead. 63919 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63920 if test "x$has_forbidden_chars" != x; then 63921 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63922 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63923 fi 63924 63925 63926 windows_path="$new_path" 63927 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63928 unix_path=`$CYGPATH -u "$windows_path"` 63929 new_path="$unix_path" 63930 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63931 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63932 new_path="$unix_path" 63933 fi 63934 63935 if test "x$path" != "x$new_path"; then 63936 FREETYPE_INCLUDE_PATH="$new_path" 63937 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63938 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63939 fi 63940 63941 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63942 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63943 63944 else 63945 # We're on a unix platform. Hooray! :) 63946 path="$FREETYPE_INCLUDE_PATH" 63947 has_space=`$ECHO "$path" | $GREP " "` 63948 if test "x$has_space" != x; then 63949 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63950 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63951 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63952 fi 63953 63954 # Use eval to expand a potential ~ 63955 eval path="$path" 63956 if test ! -f "$path" && test ! -d "$path"; then 63957 as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63958 fi 63959 63960 if test -d "$path"; then 63961 FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 63962 else 63963 dir="`$DIRNAME "$path"`" 63964 base="`$BASENAME "$path"`" 63965 FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63966 fi 63967 fi 63968 fi 63969 63970 if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then 63971 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH" 63972 else 63973 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH" 63974 fi 63975 fi 63976 63977 if test "x$FREETYPE_LIBS" = x; then 63978 63979 # Only process if variable expands to non-empty 63980 63981 if test "x$FREETYPE_LIB_PATH" != x; then 63982 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63983 63984 # Input might be given as Windows format, start by converting to 63985 # unix format. 63986 path="$FREETYPE_LIB_PATH" 63987 new_path=`$CYGPATH -u "$path"` 63988 63989 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63990 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63991 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63992 # "foo.exe" is OK but "foo" is an error. 63993 # 63994 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63995 # It is also a way to make sure we got the proper file name for the real test later on. 63996 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63997 if test "x$test_shortpath" = x; then 63998 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63999 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 64000 as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5 64001 fi 64002 64003 # Call helper function which possibly converts this using DOS-style short mode. 64004 # If so, the updated path is stored in $new_path. 64005 64006 input_path="$new_path" 64007 # Check if we need to convert this using DOS-style short mode. If the path 64008 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64009 # take no chances and rewrite it. 64010 # Note: m4 eats our [], so we need to use [ and ] instead. 64011 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64012 if test "x$has_forbidden_chars" != x; then 64013 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64014 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64015 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64016 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64017 # Going to short mode and back again did indeed matter. Since short mode is 64018 # case insensitive, let's make it lowercase to improve readability. 64019 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64020 # Now convert it back to Unix-style (cygpath) 64021 input_path=`$CYGPATH -u "$shortmode_path"` 64022 new_path="$input_path" 64023 fi 64024 fi 64025 64026 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64027 if test "x$test_cygdrive_prefix" = x; then 64028 # As a simple fix, exclude /usr/bin since it's not a real path. 64029 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64030 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64031 # a path prefixed by /cygdrive for fixpath to work. 64032 new_path="$CYGWIN_ROOT_PATH$input_path" 64033 fi 64034 fi 64035 64036 64037 if test "x$path" != "x$new_path"; then 64038 FREETYPE_LIB_PATH="$new_path" 64039 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 64040 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 64041 fi 64042 64043 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64044 64045 path="$FREETYPE_LIB_PATH" 64046 has_colon=`$ECHO $path | $GREP ^.:` 64047 new_path="$path" 64048 if test "x$has_colon" = x; then 64049 # Not in mixed or Windows style, start by that. 64050 new_path=`cmd //c echo $path` 64051 fi 64052 64053 64054 input_path="$new_path" 64055 # Check if we need to convert this using DOS-style short mode. If the path 64056 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64057 # take no chances and rewrite it. 64058 # Note: m4 eats our [], so we need to use [ and ] instead. 64059 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64060 if test "x$has_forbidden_chars" != x; then 64061 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64062 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64063 fi 64064 64065 64066 windows_path="$new_path" 64067 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64068 unix_path=`$CYGPATH -u "$windows_path"` 64069 new_path="$unix_path" 64070 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64071 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64072 new_path="$unix_path" 64073 fi 64074 64075 if test "x$path" != "x$new_path"; then 64076 FREETYPE_LIB_PATH="$new_path" 64077 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 64078 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 64079 fi 64080 64081 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64082 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64083 64084 else 64085 # We're on a unix platform. Hooray! :) 64086 path="$FREETYPE_LIB_PATH" 64087 has_space=`$ECHO "$path" | $GREP " "` 64088 if test "x$has_space" != x; then 64089 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 64090 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 64091 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64092 fi 64093 64094 # Use eval to expand a potential ~ 64095 eval path="$path" 64096 if test ! -f "$path" && test ! -d "$path"; then 64097 as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 64098 fi 64099 64100 if test -d "$path"; then 64101 FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 64102 else 64103 dir="`$DIRNAME "$path"`" 64104 base="`$BASENAME "$path"`" 64105 FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 64106 fi 64107 fi 64108 fi 64109 64110 if test "x$OPENJDK_TARGET_OS" = xwindows; then 64111 FREETYPE_LIBS="$FREETYPE_LIB_PATH/$FREETYPE_BASE_NAME.lib" 64112 else 64113 FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -l$FREETYPE_BASE_NAME" 64114 fi 64115 fi 64116 64117 # Try to compile it 64118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5 64119 $as_echo_n "checking if we can compile and link with freetype... " >&6; } 64120 ac_ext=cpp 64121 ac_cpp='$CXXCPP $CPPFLAGS' 64122 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 64123 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 64124 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 64125 64126 PREV_CXXCFLAGS="$CXXFLAGS" 64127 PREV_LIBS="$LIBS" 64128 PREV_CXX="$CXX" 64129 CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS" 64130 LIBS="$LIBS $FREETYPE_LIBS" 64131 CXX="$FIXPATH $CXX" 64132 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 64133 /* end confdefs.h. */ 64134 64135 #include<ft2build.h> 64136 #include FT_FREETYPE_H 64137 int main () { 64138 FT_Init_FreeType(NULL); 64139 return 0; 64140 } 64141 64142 _ACEOF 64143 if ac_fn_cxx_try_link "$LINENO"; then : 64144 64145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64146 $as_echo "yes" >&6; } 64147 64148 else 64149 64150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64151 $as_echo "no" >&6; } 64152 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5 64153 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;} 64154 { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5 64155 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;} 64156 64157 64158 # Print a helpful message on how to acquire the necessary build dependency. 64159 # freetype is the help tag: freetype, cups, alsa etc 64160 MISSING_DEPENDENCY=freetype 64161 64162 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64163 cygwin_help $MISSING_DEPENDENCY 64164 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64165 msys_help $MISSING_DEPENDENCY 64166 else 64167 PKGHANDLER_COMMAND= 64168 64169 case $PKGHANDLER in 64170 apt-get) 64171 apt_help $MISSING_DEPENDENCY ;; 64172 yum) 64173 yum_help $MISSING_DEPENDENCY ;; 64174 brew) 64175 brew_help $MISSING_DEPENDENCY ;; 64176 port) 64177 port_help $MISSING_DEPENDENCY ;; 64178 pkgutil) 64179 pkgutil_help $MISSING_DEPENDENCY ;; 64180 pkgadd) 64181 pkgadd_help $MISSING_DEPENDENCY ;; 64182 esac 64183 64184 if test "x$PKGHANDLER_COMMAND" != x; then 64185 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64186 fi 64187 fi 64188 64189 64190 as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5 64191 64192 64193 fi 64194 rm -f core conftest.err conftest.$ac_objext \ 64195 conftest$ac_exeext conftest.$ac_ext 64196 CXXCFLAGS="$PREV_CXXFLAGS" 64197 LIBS="$PREV_LIBS" 64198 CXX="$PREV_CXX" 64199 ac_ext=cpp 64200 ac_cpp='$CXXCPP $CPPFLAGS' 64201 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 64202 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 64203 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 64204 64205 64206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5 64207 $as_echo_n "checking if we should bundle freetype... " >&6; } 64208 if test "x$BUNDLE_FREETYPE" = xyes; then 64209 FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH" 64210 fi 64211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5 64212 $as_echo "$BUNDLE_FREETYPE" >&6; } 64213 64214 fi # end freetype needed 64215 64216 FREETYPE_LICENSE="" 64217 if test "x$with_freetype_license" = "xyes"; then 64218 as_fn_error $? "--with-freetype-license must have a value" "$LINENO" 5 64219 elif test "x$with_freetype_license" != "x"; then 64220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype license" >&5 64221 $as_echo_n "checking for freetype license... " >&6; } 64222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_freetype_license" >&5 64223 $as_echo "$with_freetype_license" >&6; } 64224 FREETYPE_LICENSE="$with_freetype_license" 64225 64226 # Only process if variable expands to non-empty 64227 64228 if test "x$FREETYPE_LICENSE" != x; then 64229 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64230 64231 # Input might be given as Windows format, start by converting to 64232 # unix format. 64233 path="$FREETYPE_LICENSE" 64234 new_path=`$CYGPATH -u "$path"` 64235 64236 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64237 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64238 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64239 # "foo.exe" is OK but "foo" is an error. 64240 # 64241 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64242 # It is also a way to make sure we got the proper file name for the real test later on. 64243 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64244 if test "x$test_shortpath" = x; then 64245 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&5 64246 $as_echo "$as_me: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&6;} 64247 as_fn_error $? "Cannot locate the the path of FREETYPE_LICENSE" "$LINENO" 5 64248 fi 64249 64250 # Call helper function which possibly converts this using DOS-style short mode. 64251 # If so, the updated path is stored in $new_path. 64252 64253 input_path="$new_path" 64254 # Check if we need to convert this using DOS-style short mode. If the path 64255 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64256 # take no chances and rewrite it. 64257 # Note: m4 eats our [], so we need to use [ and ] instead. 64258 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64259 if test "x$has_forbidden_chars" != x; then 64260 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64261 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64262 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64263 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64264 # Going to short mode and back again did indeed matter. Since short mode is 64265 # case insensitive, let's make it lowercase to improve readability. 64266 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64267 # Now convert it back to Unix-style (cygpath) 64268 input_path=`$CYGPATH -u "$shortmode_path"` 64269 new_path="$input_path" 64270 fi 64271 fi 64272 64273 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64274 if test "x$test_cygdrive_prefix" = x; then 64275 # As a simple fix, exclude /usr/bin since it's not a real path. 64276 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64277 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64278 # a path prefixed by /cygdrive for fixpath to work. 64279 new_path="$CYGWIN_ROOT_PATH$input_path" 64280 fi 64281 fi 64282 64283 64284 if test "x$path" != "x$new_path"; then 64285 FREETYPE_LICENSE="$new_path" 64286 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&5 64287 $as_echo "$as_me: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&6;} 64288 fi 64289 64290 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64291 64292 path="$FREETYPE_LICENSE" 64293 has_colon=`$ECHO $path | $GREP ^.:` 64294 new_path="$path" 64295 if test "x$has_colon" = x; then 64296 # Not in mixed or Windows style, start by that. 64297 new_path=`cmd //c echo $path` 64298 fi 64299 64300 64301 input_path="$new_path" 64302 # Check if we need to convert this using DOS-style short mode. If the path 64303 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64304 # take no chances and rewrite it. 64305 # Note: m4 eats our [], so we need to use [ and ] instead. 64306 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64307 if test "x$has_forbidden_chars" != x; then 64308 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64309 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64310 fi 64311 64312 64313 windows_path="$new_path" 64314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64315 unix_path=`$CYGPATH -u "$windows_path"` 64316 new_path="$unix_path" 64317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64318 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64319 new_path="$unix_path" 64320 fi 64321 64322 if test "x$path" != "x$new_path"; then 64323 FREETYPE_LICENSE="$new_path" 64324 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&5 64325 $as_echo "$as_me: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&6;} 64326 fi 64327 64328 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64329 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64330 64331 else 64332 # We're on a unix platform. Hooray! :) 64333 path="$FREETYPE_LICENSE" 64334 has_space=`$ECHO "$path" | $GREP " "` 64335 if test "x$has_space" != x; then 64336 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&5 64337 $as_echo "$as_me: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&6;} 64338 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64339 fi 64340 64341 # Use eval to expand a potential ~ 64342 eval path="$path" 64343 if test ! -f "$path" && test ! -d "$path"; then 64344 as_fn_error $? "The path of FREETYPE_LICENSE, which resolves as \"$path\", is not found." "$LINENO" 5 64345 fi 64346 64347 if test -d "$path"; then 64348 FREETYPE_LICENSE="`cd "$path"; $THEPWDCMD -L`" 64349 else 64350 dir="`$DIRNAME "$path"`" 64351 base="`$BASENAME "$path"`" 64352 FREETYPE_LICENSE="`cd "$dir"; $THEPWDCMD -L`/$base" 64353 fi 64354 fi 64355 fi 64356 64357 if test ! -f "$FREETYPE_LICENSE"; then 64358 as_fn_error $? "$FREETYPE_LICENSE cannot be found" "$LINENO" 5 64359 fi 64360 fi 64361 64362 64363 64364 64365 64366 64367 64368 64369 # Check whether --with-alsa was given. 64370 if test "${with_alsa+set}" = set; then : 64371 withval=$with_alsa; 64372 fi 64373 64374 64375 # Check whether --with-alsa-include was given. 64376 if test "${with_alsa_include+set}" = set; then : 64377 withval=$with_alsa_include; 64378 fi 64379 64380 64381 # Check whether --with-alsa-lib was given. 64382 if test "${with_alsa_lib+set}" = set; then : 64383 withval=$with_alsa_lib; 64384 fi 64385 64386 64387 if test "x$NEEDS_LIB_ALSA" = xfalse; then 64388 if (test "x${with_alsa}" != x && test "x${with_alsa}" != xno) || \ 64389 (test "x${with_alsa_include}" != x && test "x${with_alsa_include}" != xno) || \ 64390 (test "x${with_alsa_lib}" != x && test "x${with_alsa_lib}" != xno); then 64391 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&5 64392 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&2;} 64393 fi 64394 ALSA_CFLAGS= 64395 ALSA_LIBS= 64396 else 64397 ALSA_FOUND=no 64398 64399 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 64400 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 64401 fi 64402 64403 if test "x${with_alsa}" != x; then 64404 ALSA_LIBS="-L${with_alsa}/lib -lasound" 64405 ALSA_CFLAGS="-I${with_alsa}/include" 64406 ALSA_FOUND=yes 64407 fi 64408 if test "x${with_alsa_include}" != x; then 64409 ALSA_CFLAGS="-I${with_alsa_include}" 64410 ALSA_FOUND=yes 64411 fi 64412 if test "x${with_alsa_lib}" != x; then 64413 ALSA_LIBS="-L${with_alsa_lib} -lasound" 64414 ALSA_FOUND=yes 64415 fi 64416 # Do not try pkg-config if we have a sysroot set. 64417 if test "x$SYSROOT" = x; then 64418 if test "x$ALSA_FOUND" = xno; then 64419 64420 pkg_failed=no 64421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 64422 $as_echo_n "checking for ALSA... " >&6; } 64423 64424 if test -n "$ALSA_CFLAGS"; then 64425 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 64426 elif test -n "$PKG_CONFIG"; then 64427 if test -n "$PKG_CONFIG" && \ 64428 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 64429 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 64430 ac_status=$? 64431 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64432 test $ac_status = 0; }; then 64433 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 64434 else 64435 pkg_failed=yes 64436 fi 64437 else 64438 pkg_failed=untried 64439 fi 64440 if test -n "$ALSA_LIBS"; then 64441 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 64442 elif test -n "$PKG_CONFIG"; then 64443 if test -n "$PKG_CONFIG" && \ 64444 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 64445 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 64446 ac_status=$? 64447 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64448 test $ac_status = 0; }; then 64449 pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 64450 else 64451 pkg_failed=yes 64452 fi 64453 else 64454 pkg_failed=untried 64455 fi 64456 64457 64458 64459 if test $pkg_failed = yes; then 64460 64461 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 64462 _pkg_short_errors_supported=yes 64463 else 64464 _pkg_short_errors_supported=no 64465 fi 64466 if test $_pkg_short_errors_supported = yes; then 64467 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 64468 else 64469 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 64470 fi 64471 # Put the nasty error message in config.log where it belongs 64472 echo "$ALSA_PKG_ERRORS" >&5 64473 64474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64475 $as_echo "no" >&6; } 64476 ALSA_FOUND=no 64477 elif test $pkg_failed = untried; then 64478 ALSA_FOUND=no 64479 else 64480 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 64481 ALSA_LIBS=$pkg_cv_ALSA_LIBS 64482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64483 $as_echo "yes" >&6; } 64484 ALSA_FOUND=yes 64485 fi 64486 fi 64487 fi 64488 if test "x$ALSA_FOUND" = xno; then 64489 for ac_header in alsa/asoundlib.h 64490 do : 64491 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 64492 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 64493 cat >>confdefs.h <<_ACEOF 64494 #define HAVE_ALSA_ASOUNDLIB_H 1 64495 _ACEOF 64496 64497 ALSA_FOUND=yes 64498 ALSA_CFLAGS=-Iignoreme 64499 ALSA_LIBS=-lasound 64500 DEFAULT_ALSA=yes 64501 64502 else 64503 ALSA_FOUND=no 64504 64505 fi 64506 64507 done 64508 64509 fi 64510 if test "x$ALSA_FOUND" = xno; then 64511 64512 # Print a helpful message on how to acquire the necessary build dependency. 64513 # alsa is the help tag: freetype, cups, alsa etc 64514 MISSING_DEPENDENCY=alsa 64515 64516 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64517 cygwin_help $MISSING_DEPENDENCY 64518 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64519 msys_help $MISSING_DEPENDENCY 64520 else 64521 PKGHANDLER_COMMAND= 64522 64523 case $PKGHANDLER in 64524 apt-get) 64525 apt_help $MISSING_DEPENDENCY ;; 64526 yum) 64527 yum_help $MISSING_DEPENDENCY ;; 64528 brew) 64529 brew_help $MISSING_DEPENDENCY ;; 64530 port) 64531 port_help $MISSING_DEPENDENCY ;; 64532 pkgutil) 64533 pkgutil_help $MISSING_DEPENDENCY ;; 64534 pkgadd) 64535 pkgadd_help $MISSING_DEPENDENCY ;; 64536 esac 64537 64538 if test "x$PKGHANDLER_COMMAND" != x; then 64539 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64540 fi 64541 fi 64542 64543 as_fn_error $? "Could not find alsa! $HELP_MSG" "$LINENO" 5 64544 fi 64545 fi 64546 64547 64548 64549 64550 64551 64552 # Check whether --with-libffi was given. 64553 if test "${with_libffi+set}" = set; then : 64554 withval=$with_libffi; 64555 fi 64556 64557 64558 # Check whether --with-libffi-include was given. 64559 if test "${with_libffi_include+set}" = set; then : 64560 withval=$with_libffi_include; 64561 fi 64562 64563 64564 # Check whether --with-libffi-lib was given. 64565 if test "${with_libffi_lib+set}" = set; then : 64566 withval=$with_libffi_lib; 64567 fi 64568 64569 # Check whether --enable-libffi-bundling was given. 64570 if test "${enable_libffi_bundling+set}" = set; then : 64571 enableval=$enable_libffi_bundling; 64572 fi 64573 64574 64575 if test "x$NEEDS_LIB_FFI" = xfalse; then 64576 if (test "x${with_libffi}" != x && test "x${with_libffi}" != xno) || \ 64577 (test "x${with_libffi_include}" != x && test "x${with_libffi_include}" != xno) || \ 64578 (test "x${with_libffi_lib}" != x && test "x${with_libffi_lib}" != xno); then 64579 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&5 64580 $as_echo "$as_me: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&2;} 64581 fi 64582 LIBFFI_CFLAGS= 64583 LIBFFI_LIBS= 64584 else 64585 LIBFFI_FOUND=no 64586 64587 if test "x${with_libffi}" = xno || test "x${with_libffi_include}" = xno || test "x${with_libffi_lib}" = xno; then 64588 as_fn_error $? "It is not possible to disable the use of libffi. Remove the --without-libffi option." "$LINENO" 5 64589 fi 64590 64591 if test "x${with_libffi}" != x; then 64592 LIBFFI_LIB_PATH="${with_libffi}/lib" 64593 LIBFFI_LIBS="-L${with_libffi}/lib -lffi" 64594 LIBFFI_CFLAGS="-I${with_libffi}/include" 64595 LIBFFI_FOUND=yes 64596 fi 64597 if test "x${with_libffi_include}" != x; then 64598 LIBFFI_CFLAGS="-I${with_libffi_include}" 64599 LIBFFI_FOUND=yes 64600 fi 64601 if test "x${with_libffi_lib}" != x; then 64602 LIBFFI_LIB_PATH="${with_libffi_lib}" 64603 LIBFFI_LIBS="-L${with_libffi_lib} -lffi" 64604 LIBFFI_FOUND=yes 64605 fi 64606 # Do not try pkg-config if we have a sysroot set. 64607 if test "x$SYSROOT" = x; then 64608 if test "x$LIBFFI_FOUND" = xno; then 64609 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 64610 64611 pkg_failed=no 64612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 64613 $as_echo_n "checking for LIBFFI... " >&6; } 64614 64615 if test -n "$LIBFFI_CFLAGS"; then 64616 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 64617 elif test -n "$PKG_CONFIG"; then 64618 if test -n "$PKG_CONFIG" && \ 64619 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 64620 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 64621 ac_status=$? 64622 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64623 test $ac_status = 0; }; then 64624 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 64625 else 64626 pkg_failed=yes 64627 fi 64628 else 64629 pkg_failed=untried 64630 fi 64631 if test -n "$LIBFFI_LIBS"; then 64632 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 64633 elif test -n "$PKG_CONFIG"; then 64634 if test -n "$PKG_CONFIG" && \ 64635 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 64636 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 64637 ac_status=$? 64638 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64639 test $ac_status = 0; }; then 64640 pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 64641 else 64642 pkg_failed=yes 64643 fi 64644 else 64645 pkg_failed=untried 64646 fi 64647 64648 64649 64650 if test $pkg_failed = yes; then 64651 64652 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 64653 _pkg_short_errors_supported=yes 64654 else 64655 _pkg_short_errors_supported=no 64656 fi 64657 if test $_pkg_short_errors_supported = yes; then 64658 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 64659 else 64660 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 64661 fi 64662 # Put the nasty error message in config.log where it belongs 64663 echo "$LIBFFI_PKG_ERRORS" >&5 64664 64665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64666 $as_echo "no" >&6; } 64667 LIBFFI_FOUND=no 64668 elif test $pkg_failed = untried; then 64669 LIBFFI_FOUND=no 64670 else 64671 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 64672 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 64673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64674 $as_echo "yes" >&6; } 64675 LIBFFI_FOUND=yes 64676 fi 64677 fi 64678 fi 64679 if test "x$LIBFFI_FOUND" = xno; then 64680 for ac_header in ffi.h 64681 do : 64682 ac_fn_cxx_check_header_mongrel "$LINENO" "ffi.h" "ac_cv_header_ffi_h" "$ac_includes_default" 64683 if test "x$ac_cv_header_ffi_h" = xyes; then : 64684 cat >>confdefs.h <<_ACEOF 64685 #define HAVE_FFI_H 1 64686 _ACEOF 64687 64688 LIBFFI_FOUND=yes 64689 LIBFFI_CFLAGS= 64690 LIBFFI_LIBS=-lffi 64691 64692 else 64693 LIBFFI_FOUND=no 64694 64695 fi 64696 64697 done 64698 64699 fi 64700 if test "x$LIBFFI_FOUND" = xno; then 64701 64702 # Print a helpful message on how to acquire the necessary build dependency. 64703 # ffi is the help tag: freetype, cups, alsa etc 64704 MISSING_DEPENDENCY=ffi 64705 64706 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64707 cygwin_help $MISSING_DEPENDENCY 64708 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64709 msys_help $MISSING_DEPENDENCY 64710 else 64711 PKGHANDLER_COMMAND= 64712 64713 case $PKGHANDLER in 64714 apt-get) 64715 apt_help $MISSING_DEPENDENCY ;; 64716 yum) 64717 yum_help $MISSING_DEPENDENCY ;; 64718 brew) 64719 brew_help $MISSING_DEPENDENCY ;; 64720 port) 64721 port_help $MISSING_DEPENDENCY ;; 64722 pkgutil) 64723 pkgutil_help $MISSING_DEPENDENCY ;; 64724 pkgadd) 64725 pkgadd_help $MISSING_DEPENDENCY ;; 64726 esac 64727 64728 if test "x$PKGHANDLER_COMMAND" != x; then 64729 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64730 fi 64731 fi 64732 64733 as_fn_error $? "Could not find libffi! $HELP_MSG" "$LINENO" 5 64734 fi 64735 64736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi works" >&5 64737 $as_echo_n "checking if libffi works... " >&6; } 64738 ac_ext=c 64739 ac_cpp='$CPP $CPPFLAGS' 64740 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 64741 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 64742 ac_compiler_gnu=$ac_cv_c_compiler_gnu 64743 64744 OLD_CFLAGS="$CFLAGS" 64745 CFLAGS="$CFLAGS $LIBFFI_CFLAGS" 64746 OLD_LIBS="$LIBS" 64747 LIBS="$LIBS $LIBFFI_LIBS" 64748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 64749 /* end confdefs.h. */ 64750 #include <ffi.h> 64751 int 64752 main () 64753 { 64754 64755 ffi_call(NULL, NULL, NULL, NULL); 64756 return 0; 64757 64758 ; 64759 return 0; 64760 } 64761 _ACEOF 64762 if ac_fn_c_try_link "$LINENO"; then : 64763 LIBFFI_WORKS=yes 64764 else 64765 LIBFFI_WORKS=no 64766 64767 fi 64768 rm -f core conftest.err conftest.$ac_objext \ 64769 conftest$ac_exeext conftest.$ac_ext 64770 CFLAGS="$OLD_CFLAGS" 64771 LIBS="$OLD_LIBS" 64772 ac_ext=cpp 64773 ac_cpp='$CXXCPP $CPPFLAGS' 64774 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 64775 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 64776 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 64777 64778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBFFI_WORKS" >&5 64779 $as_echo "$LIBFFI_WORKS" >&6; } 64780 64781 if test "x$LIBFFI_WORKS" = xno; then 64782 64783 # Print a helpful message on how to acquire the necessary build dependency. 64784 # ffi is the help tag: freetype, cups, alsa etc 64785 MISSING_DEPENDENCY=ffi 64786 64787 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64788 cygwin_help $MISSING_DEPENDENCY 64789 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64790 msys_help $MISSING_DEPENDENCY 64791 else 64792 PKGHANDLER_COMMAND= 64793 64794 case $PKGHANDLER in 64795 apt-get) 64796 apt_help $MISSING_DEPENDENCY ;; 64797 yum) 64798 yum_help $MISSING_DEPENDENCY ;; 64799 brew) 64800 brew_help $MISSING_DEPENDENCY ;; 64801 port) 64802 port_help $MISSING_DEPENDENCY ;; 64803 pkgutil) 64804 pkgutil_help $MISSING_DEPENDENCY ;; 64805 pkgadd) 64806 pkgadd_help $MISSING_DEPENDENCY ;; 64807 esac 64808 64809 if test "x$PKGHANDLER_COMMAND" != x; then 64810 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64811 fi 64812 fi 64813 64814 as_fn_error $? "Found libffi but could not link and compile with it. $HELP_MSG" "$LINENO" 5 64815 fi 64816 64817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi should be bundled" >&5 64818 $as_echo_n "checking if libffi should be bundled... " >&6; } 64819 if test "x$enable_libffi_bundling" = "x"; then 64820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64821 $as_echo "no" >&6; } 64822 ENABLE_LIBFFI_BUNDLING=false 64823 elif test "x$enable_libffi_bundling" = "xno"; then 64824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 64825 $as_echo "no, forced" >&6; } 64826 ENABLE_LIBFFI_BUNDLING=false 64827 elif test "x$enable_libffi_bundling" = "xyes"; then 64828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 64829 $as_echo "yes, forced" >&6; } 64830 ENABLE_LIBFFI_BUNDLING=true 64831 else 64832 as_fn_error $? "Invalid value for --enable-libffi-bundling" "$LINENO" 5 64833 fi 64834 64835 # Find the libffi.so.X to bundle 64836 if test "x${ENABLE_LIBFFI_BUNDLING}" = "xtrue"; then 64837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libffi lib file location" >&5 64838 $as_echo_n "checking for libffi lib file location... " >&6; } 64839 if test "x${LIBFFI_LIB_PATH}" != x; then 64840 if test -e ${LIBFFI_LIB_PATH}/libffi.so.?; then 64841 LIBFFI_LIB_FILE="${LIBFFI_LIB_PATH}/libffi.so.?" 64842 else 64843 as_fn_error $? "Could not locate libffi.so.? for bundling in ${LIBFFI_LIB_PATH}" "$LINENO" 5 64844 fi 64845 else 64846 # If we don't have an explicit path, look in a few obvious places 64847 if test "x${OPENJDK_TARGET_CPU}" = "xx86"; then 64848 if test -e ${SYSROOT}/usr/lib/libffi.so.? ; then 64849 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/libffi.so.?" 64850 elif test -e ${SYSROOT}/usr/lib/i386-linux-gnu/libffi.so.? ; then 64851 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/i386-linux-gnu/libffi.so.?" 64852 else 64853 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 64854 fi 64855 elif test "x${OPENJDK_TARGET_CPU}" = "xx86_64"; then 64856 if test -e ${SYSROOT}/usr/lib64/libffi.so.? ; then 64857 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib64/libffi.so.?" 64858 elif test -e ${SYSROOT}/usr/lib/x86_64-linux-gnu/libffi.so.? ; then 64859 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/x86_64-linux-gnu/libffi.so.?" 64860 else 64861 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 64862 fi 64863 else 64864 # Fallback on the default /usr/lib dir 64865 if test -e ${SYSROOT}/usr/lib/libffi.so.? ; then 64866 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/libffi.so.?" 64867 else 64868 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 64869 fi 64870 fi 64871 fi 64872 # Make sure the wildcard is evaluated 64873 LIBFFI_LIB_FILE="$(ls ${LIBFFI_LIB_FILE})" 64874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${LIBFFI_LIB_FILE}" >&5 64875 $as_echo "${LIBFFI_LIB_FILE}" >&6; } 64876 fi 64877 fi 64878 64879 64880 64881 64882 64883 64884 64885 if [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 64886 # Extract the first word of "llvm-config", so it can be a program name with args. 64887 set dummy llvm-config; ac_word=$2 64888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64889 $as_echo_n "checking for $ac_word... " >&6; } 64890 if ${ac_cv_prog_LLVM_CONFIG+:} false; then : 64891 $as_echo_n "(cached) " >&6 64892 else 64893 if test -n "$LLVM_CONFIG"; then 64894 ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test. 64895 else 64896 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64897 for as_dir in $PATH 64898 do 64899 IFS=$as_save_IFS 64900 test -z "$as_dir" && as_dir=. 64901 for ac_exec_ext in '' $ac_executable_extensions; do 64902 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64903 ac_cv_prog_LLVM_CONFIG="llvm-config" 64904 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64905 break 2 64906 fi 64907 done 64908 done 64909 IFS=$as_save_IFS 64910 64911 fi 64912 fi 64913 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG 64914 if test -n "$LLVM_CONFIG"; then 64915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 64916 $as_echo "$LLVM_CONFIG" >&6; } 64917 else 64918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64919 $as_echo "no" >&6; } 64920 fi 64921 64922 64923 64924 if test "x$LLVM_CONFIG" != xllvm-config; then 64925 as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5 64926 fi 64927 64928 llvm_components="jit mcjit engine nativecodegen native" 64929 unset LLVM_CFLAGS 64930 for flag in $("$LLVM_CONFIG" --cxxflags); do 64931 if echo "${flag}" | grep -q '^-[ID]'; then 64932 if test "${flag}" != "-D_DEBUG" ; then 64933 if test "${LLVM_CFLAGS}" != "" ; then 64934 LLVM_CFLAGS="${LLVM_CFLAGS} " 64935 fi 64936 LLVM_CFLAGS="${LLVM_CFLAGS}${flag}" 64937 fi 64938 fi 64939 done 64940 llvm_version=$("${LLVM_CONFIG}" --version | $SED 's/\.//; s/svn.*//') 64941 LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}" 64942 64943 unset LLVM_LDFLAGS 64944 for flag in $("${LLVM_CONFIG}" --ldflags); do 64945 if echo "${flag}" | grep -q '^-L'; then 64946 if test "${LLVM_LDFLAGS}" != ""; then 64947 LLVM_LDFLAGS="${LLVM_LDFLAGS} " 64948 fi 64949 LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}" 64950 fi 64951 done 64952 64953 unset LLVM_LIBS 64954 for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do 64955 if echo "${flag}" | grep -q '^-l'; then 64956 if test "${LLVM_LIBS}" != ""; then 64957 LLVM_LIBS="${LLVM_LIBS} " 64958 fi 64959 LLVM_LIBS="${LLVM_LIBS}${flag}" 64960 fi 64961 done 64962 64963 # Due to https://llvm.org/bugs/show_bug.cgi?id=16902, llvm does not 64964 # always properly detect -ltinfo 64965 LLVM_LIBS="${LLVM_LIBS} -ltinfo" 64966 64967 64968 64969 64970 fi 64971 64972 64973 64974 # Check whether --with-libjpeg was given. 64975 if test "${with_libjpeg+set}" = set; then : 64976 withval=$with_libjpeg; 64977 fi 64978 64979 64980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libjpeg to use" >&5 64981 $as_echo_n "checking for which libjpeg to use... " >&6; } 64982 # default is bundled 64983 DEFAULT_LIBJPEG=bundled 64984 # if user didn't specify, use DEFAULT_LIBJPEG 64985 if test "x${with_libjpeg}" = "x"; then 64986 with_libjpeg=${DEFAULT_LIBJPEG} 64987 fi 64988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libjpeg}" >&5 64989 $as_echo "${with_libjpeg}" >&6; } 64990 64991 if test "x${with_libjpeg}" = "xbundled"; then 64992 USE_EXTERNAL_LIBJPEG=false 64993 elif test "x${with_libjpeg}" = "xsystem"; then 64994 ac_fn_cxx_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default" 64995 if test "x$ac_cv_header_jpeglib_h" = xyes; then : 64996 64997 else 64998 as_fn_error $? "--with-libjpeg=system specified, but jpeglib.h not found!" "$LINENO" 5 64999 fi 65000 65001 65002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateDecompress in -ljpeg" >&5 65003 $as_echo_n "checking for jpeg_CreateDecompress in -ljpeg... " >&6; } 65004 if ${ac_cv_lib_jpeg_jpeg_CreateDecompress+:} false; then : 65005 $as_echo_n "(cached) " >&6 65006 else 65007 ac_check_lib_save_LIBS=$LIBS 65008 LIBS="-ljpeg $LIBS" 65009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65010 /* end confdefs.h. */ 65011 65012 /* Override any GCC internal prototype to avoid an error. 65013 Use char because int might match the return type of a GCC 65014 builtin and then its argument prototype would still apply. */ 65015 #ifdef __cplusplus 65016 extern "C" 65017 #endif 65018 char jpeg_CreateDecompress (); 65019 int 65020 main () 65021 { 65022 return jpeg_CreateDecompress (); 65023 ; 65024 return 0; 65025 } 65026 _ACEOF 65027 if ac_fn_cxx_try_link "$LINENO"; then : 65028 ac_cv_lib_jpeg_jpeg_CreateDecompress=yes 65029 else 65030 ac_cv_lib_jpeg_jpeg_CreateDecompress=no 65031 fi 65032 rm -f core conftest.err conftest.$ac_objext \ 65033 conftest$ac_exeext conftest.$ac_ext 65034 LIBS=$ac_check_lib_save_LIBS 65035 fi 65036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateDecompress" >&5 65037 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateDecompress" >&6; } 65038 if test "x$ac_cv_lib_jpeg_jpeg_CreateDecompress" = xyes; then : 65039 cat >>confdefs.h <<_ACEOF 65040 #define HAVE_LIBJPEG 1 65041 _ACEOF 65042 65043 LIBS="-ljpeg $LIBS" 65044 65045 else 65046 as_fn_error $? "--with-libjpeg=system specified, but no libjpeg found" "$LINENO" 5 65047 fi 65048 65049 65050 USE_EXTERNAL_LIBJPEG=true 65051 else 65052 as_fn_error $? "Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'" "$LINENO" 5 65053 fi 65054 65055 65056 65057 65058 65059 # Check whether --with-giflib was given. 65060 if test "${with_giflib+set}" = set; then : 65061 withval=$with_giflib; 65062 fi 65063 65064 65065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 65066 $as_echo_n "checking for which giflib to use... " >&6; } 65067 # default is bundled 65068 DEFAULT_GIFLIB=bundled 65069 # if user didn't specify, use DEFAULT_GIFLIB 65070 if test "x${with_giflib}" = "x"; then 65071 with_giflib=${DEFAULT_GIFLIB} 65072 fi 65073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 65074 $as_echo "${with_giflib}" >&6; } 65075 65076 if test "x${with_giflib}" = "xbundled"; then 65077 USE_EXTERNAL_LIBGIF=false 65078 elif test "x${with_giflib}" = "xsystem"; then 65079 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 65080 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 65081 65082 else 65083 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 65084 fi 65085 65086 65087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 65088 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 65089 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 65090 $as_echo_n "(cached) " >&6 65091 else 65092 ac_check_lib_save_LIBS=$LIBS 65093 LIBS="-lgif $LIBS" 65094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65095 /* end confdefs.h. */ 65096 65097 /* Override any GCC internal prototype to avoid an error. 65098 Use char because int might match the return type of a GCC 65099 builtin and then its argument prototype would still apply. */ 65100 #ifdef __cplusplus 65101 extern "C" 65102 #endif 65103 char DGifGetCode (); 65104 int 65105 main () 65106 { 65107 return DGifGetCode (); 65108 ; 65109 return 0; 65110 } 65111 _ACEOF 65112 if ac_fn_cxx_try_link "$LINENO"; then : 65113 ac_cv_lib_gif_DGifGetCode=yes 65114 else 65115 ac_cv_lib_gif_DGifGetCode=no 65116 fi 65117 rm -f core conftest.err conftest.$ac_objext \ 65118 conftest$ac_exeext conftest.$ac_ext 65119 LIBS=$ac_check_lib_save_LIBS 65120 fi 65121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 65122 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 65123 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 65124 cat >>confdefs.h <<_ACEOF 65125 #define HAVE_LIBGIF 1 65126 _ACEOF 65127 65128 LIBS="-lgif $LIBS" 65129 65130 else 65131 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 65132 fi 65133 65134 65135 USE_EXTERNAL_LIBGIF=true 65136 else 65137 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 65138 fi 65139 65140 65141 65142 65143 65144 # Check whether --with-libpng was given. 65145 if test "${with_libpng+set}" = set; then : 65146 withval=$with_libpng; 65147 fi 65148 65149 65150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5 65151 $as_echo_n "checking for which libpng to use... " >&6; } 65152 65153 # default is bundled 65154 DEFAULT_LIBPNG=bundled 65155 # if user didn't specify, use DEFAULT_LIBPNG 65156 if test "x${with_libpng}" = "x"; then 65157 with_libpng=${DEFAULT_LIBPNG} 65158 fi 65159 65160 if test "x${with_libpng}" = "xbundled"; then 65161 USE_EXTERNAL_LIBPNG=false 65162 PNG_CFLAGS="" 65163 PNG_LIBS="" 65164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 65165 $as_echo "bundled" >&6; } 65166 elif test "x${with_libpng}" = "xsystem"; then 65167 65168 pkg_failed=no 65169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5 65170 $as_echo_n "checking for PNG... " >&6; } 65171 65172 if test -n "$PNG_CFLAGS"; then 65173 pkg_cv_PNG_CFLAGS="$PNG_CFLAGS" 65174 elif test -n "$PKG_CONFIG"; then 65175 if test -n "$PKG_CONFIG" && \ 65176 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 65177 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 65178 ac_status=$? 65179 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65180 test $ac_status = 0; }; then 65181 pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null` 65182 else 65183 pkg_failed=yes 65184 fi 65185 else 65186 pkg_failed=untried 65187 fi 65188 if test -n "$PNG_LIBS"; then 65189 pkg_cv_PNG_LIBS="$PNG_LIBS" 65190 elif test -n "$PKG_CONFIG"; then 65191 if test -n "$PKG_CONFIG" && \ 65192 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 65193 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 65194 ac_status=$? 65195 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65196 test $ac_status = 0; }; then 65197 pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null` 65198 else 65199 pkg_failed=yes 65200 fi 65201 else 65202 pkg_failed=untried 65203 fi 65204 65205 65206 65207 if test $pkg_failed = yes; then 65208 65209 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 65210 _pkg_short_errors_supported=yes 65211 else 65212 _pkg_short_errors_supported=no 65213 fi 65214 if test $_pkg_short_errors_supported = yes; then 65215 PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1` 65216 else 65217 PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1` 65218 fi 65219 # Put the nasty error message in config.log where it belongs 65220 echo "$PNG_PKG_ERRORS" >&5 65221 65222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65223 $as_echo "no" >&6; } 65224 LIBPNG_FOUND=no 65225 elif test $pkg_failed = untried; then 65226 LIBPNG_FOUND=no 65227 else 65228 PNG_CFLAGS=$pkg_cv_PNG_CFLAGS 65229 PNG_LIBS=$pkg_cv_PNG_LIBS 65230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65231 $as_echo "yes" >&6; } 65232 LIBPNG_FOUND=yes 65233 fi 65234 if test "x${LIBPNG_FOUND}" = "xyes"; then 65235 # PKG_CHECK_MODULES will set PNG_CFLAGS and PNG_LIBS 65236 USE_EXTERNAL_LIBPNG=true 65237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 65238 $as_echo "system" >&6; } 65239 else 65240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 65241 $as_echo "system not found" >&6; } 65242 as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5 65243 fi 65244 else 65245 as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5 65246 fi 65247 65248 65249 65250 65251 65252 65253 65254 # Check whether --with-zlib was given. 65255 if test "${with_zlib+set}" = set; then : 65256 withval=$with_zlib; 65257 fi 65258 65259 65260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 65261 $as_echo_n "checking for compress in -lz... " >&6; } 65262 if ${ac_cv_lib_z_compress+:} false; then : 65263 $as_echo_n "(cached) " >&6 65264 else 65265 ac_check_lib_save_LIBS=$LIBS 65266 LIBS="-lz $LIBS" 65267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65268 /* end confdefs.h. */ 65269 65270 /* Override any GCC internal prototype to avoid an error. 65271 Use char because int might match the return type of a GCC 65272 builtin and then its argument prototype would still apply. */ 65273 #ifdef __cplusplus 65274 extern "C" 65275 #endif 65276 char compress (); 65277 int 65278 main () 65279 { 65280 return compress (); 65281 ; 65282 return 0; 65283 } 65284 _ACEOF 65285 if ac_fn_cxx_try_link "$LINENO"; then : 65286 ac_cv_lib_z_compress=yes 65287 else 65288 ac_cv_lib_z_compress=no 65289 fi 65290 rm -f core conftest.err conftest.$ac_objext \ 65291 conftest$ac_exeext conftest.$ac_ext 65292 LIBS=$ac_check_lib_save_LIBS 65293 fi 65294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 65295 $as_echo "$ac_cv_lib_z_compress" >&6; } 65296 if test "x$ac_cv_lib_z_compress" = xyes; then : 65297 ZLIB_FOUND=yes 65298 else 65299 ZLIB_FOUND=no 65300 fi 65301 65302 65303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 65304 $as_echo_n "checking for which zlib to use... " >&6; } 65305 65306 DEFAULT_ZLIB=system 65307 if test "x$OPENJDK_TARGET_OS" = xwindows; then 65308 # On windows default is bundled...on others default is system 65309 DEFAULT_ZLIB=bundled 65310 fi 65311 65312 if test "x${ZLIB_FOUND}" != "xyes"; then 65313 # If we don't find any system...set default to bundled 65314 DEFAULT_ZLIB=bundled 65315 fi 65316 65317 # If user didn't specify, use DEFAULT_ZLIB 65318 if test "x${with_zlib}" = "x"; then 65319 with_zlib=${DEFAULT_ZLIB} 65320 fi 65321 65322 if test "x${with_zlib}" = "xbundled"; then 65323 USE_EXTERNAL_LIBZ=false 65324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 65325 $as_echo "bundled" >&6; } 65326 elif test "x${with_zlib}" = "xsystem"; then 65327 if test "x${ZLIB_FOUND}" = "xyes"; then 65328 USE_EXTERNAL_LIBZ=true 65329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 65330 $as_echo "system" >&6; } 65331 else 65332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 65333 $as_echo "system not found" >&6; } 65334 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 65335 fi 65336 else 65337 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 65338 fi 65339 65340 65341 65342 65343 65344 # Check whether --with-lcms was given. 65345 if test "${with_lcms+set}" = set; then : 65346 withval=$with_lcms; 65347 fi 65348 65349 65350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which lcms to use" >&5 65351 $as_echo_n "checking for which lcms to use... " >&6; } 65352 65353 DEFAULT_LCMS=bundled 65354 # If user didn't specify, use DEFAULT_LCMS 65355 if test "x${with_lcms}" = "x"; then 65356 with_lcms=${DEFAULT_LCMS} 65357 fi 65358 65359 if test "x${with_lcms}" = "xbundled"; then 65360 USE_EXTERNAL_LCMS=false 65361 LCMS_CFLAGS="" 65362 LCMS_LIBS="" 65363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 65364 $as_echo "bundled" >&6; } 65365 elif test "x${with_lcms}" = "xsystem"; then 65366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 65367 $as_echo "system" >&6; } 65368 65369 pkg_failed=no 65370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCMS" >&5 65371 $as_echo_n "checking for LCMS... " >&6; } 65372 65373 if test -n "$LCMS_CFLAGS"; then 65374 pkg_cv_LCMS_CFLAGS="$LCMS_CFLAGS" 65375 elif test -n "$PKG_CONFIG"; then 65376 if test -n "$PKG_CONFIG" && \ 65377 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 65378 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 65379 ac_status=$? 65380 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65381 test $ac_status = 0; }; then 65382 pkg_cv_LCMS_CFLAGS=`$PKG_CONFIG --cflags "lcms2" 2>/dev/null` 65383 else 65384 pkg_failed=yes 65385 fi 65386 else 65387 pkg_failed=untried 65388 fi 65389 if test -n "$LCMS_LIBS"; then 65390 pkg_cv_LCMS_LIBS="$LCMS_LIBS" 65391 elif test -n "$PKG_CONFIG"; then 65392 if test -n "$PKG_CONFIG" && \ 65393 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 65394 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 65395 ac_status=$? 65396 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65397 test $ac_status = 0; }; then 65398 pkg_cv_LCMS_LIBS=`$PKG_CONFIG --libs "lcms2" 2>/dev/null` 65399 else 65400 pkg_failed=yes 65401 fi 65402 else 65403 pkg_failed=untried 65404 fi 65405 65406 65407 65408 if test $pkg_failed = yes; then 65409 65410 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 65411 _pkg_short_errors_supported=yes 65412 else 65413 _pkg_short_errors_supported=no 65414 fi 65415 if test $_pkg_short_errors_supported = yes; then 65416 LCMS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lcms2" 2>&1` 65417 else 65418 LCMS_PKG_ERRORS=`$PKG_CONFIG --print-errors "lcms2" 2>&1` 65419 fi 65420 # Put the nasty error message in config.log where it belongs 65421 echo "$LCMS_PKG_ERRORS" >&5 65422 65423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65424 $as_echo "no" >&6; } 65425 LCMS_FOUND=no 65426 elif test $pkg_failed = untried; then 65427 LCMS_FOUND=no 65428 else 65429 LCMS_CFLAGS=$pkg_cv_LCMS_CFLAGS 65430 LCMS_LIBS=$pkg_cv_LCMS_LIBS 65431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65432 $as_echo "yes" >&6; } 65433 LCMS_FOUND=yes 65434 fi 65435 if test "x${LCMS_FOUND}" = "xyes"; then 65436 # PKG_CHECK_MODULES will set LCMS_CFLAGS and LCMS_LIBS 65437 USE_EXTERNAL_LCMS=true 65438 else 65439 as_fn_error $? "--with-lcms=system specified, but no lcms found!" "$LINENO" 5 65440 fi 65441 else 65442 as_fn_error $? "Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'" "$LINENO" 5 65443 fi 65444 65445 65446 65447 65448 65449 65450 65451 65452 65453 65454 65455 65456 65457 # Setup libm (the maths library) 65458 if test "x$OPENJDK_TARGET_OS" != "xwindows"; then 65459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 65460 $as_echo_n "checking for cos in -lm... " >&6; } 65461 if ${ac_cv_lib_m_cos+:} false; then : 65462 $as_echo_n "(cached) " >&6 65463 else 65464 ac_check_lib_save_LIBS=$LIBS 65465 LIBS="-lm $LIBS" 65466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65467 /* end confdefs.h. */ 65468 65469 /* Override any GCC internal prototype to avoid an error. 65470 Use char because int might match the return type of a GCC 65471 builtin and then its argument prototype would still apply. */ 65472 #ifdef __cplusplus 65473 extern "C" 65474 #endif 65475 char cos (); 65476 int 65477 main () 65478 { 65479 return cos (); 65480 ; 65481 return 0; 65482 } 65483 _ACEOF 65484 if ac_fn_cxx_try_link "$LINENO"; then : 65485 ac_cv_lib_m_cos=yes 65486 else 65487 ac_cv_lib_m_cos=no 65488 fi 65489 rm -f core conftest.err conftest.$ac_objext \ 65490 conftest$ac_exeext conftest.$ac_ext 65491 LIBS=$ac_check_lib_save_LIBS 65492 fi 65493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 65494 $as_echo "$ac_cv_lib_m_cos" >&6; } 65495 if test "x$ac_cv_lib_m_cos" = xyes; then : 65496 cat >>confdefs.h <<_ACEOF 65497 #define HAVE_LIBM 1 65498 _ACEOF 65499 65500 LIBS="-lm $LIBS" 65501 65502 else 65503 65504 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 65505 $as_echo "$as_me: Maths library was not found" >&6;} 65506 65507 fi 65508 65509 LIBM="-lm" 65510 else 65511 LIBM="" 65512 fi 65513 65514 65515 # Setup libdl (for dynamic library loading) 65516 save_LIBS="$LIBS" 65517 LIBS="" 65518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 65519 $as_echo_n "checking for dlopen in -ldl... " >&6; } 65520 if ${ac_cv_lib_dl_dlopen+:} false; then : 65521 $as_echo_n "(cached) " >&6 65522 else 65523 ac_check_lib_save_LIBS=$LIBS 65524 LIBS="-ldl $LIBS" 65525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65526 /* end confdefs.h. */ 65527 65528 /* Override any GCC internal prototype to avoid an error. 65529 Use char because int might match the return type of a GCC 65530 builtin and then its argument prototype would still apply. */ 65531 #ifdef __cplusplus 65532 extern "C" 65533 #endif 65534 char dlopen (); 65535 int 65536 main () 65537 { 65538 return dlopen (); 65539 ; 65540 return 0; 65541 } 65542 _ACEOF 65543 if ac_fn_cxx_try_link "$LINENO"; then : 65544 ac_cv_lib_dl_dlopen=yes 65545 else 65546 ac_cv_lib_dl_dlopen=no 65547 fi 65548 rm -f core conftest.err conftest.$ac_objext \ 65549 conftest$ac_exeext conftest.$ac_ext 65550 LIBS=$ac_check_lib_save_LIBS 65551 fi 65552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 65553 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 65554 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 65555 cat >>confdefs.h <<_ACEOF 65556 #define HAVE_LIBDL 1 65557 _ACEOF 65558 65559 LIBS="-ldl $LIBS" 65560 65561 fi 65562 65563 LIBDL="$LIBS" 65564 65565 LIBS="$save_LIBS" 65566 65567 # Deprecated libraries, keep the flags for backwards compatibility 65568 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 65569 65570 65571 # Check whether --with-dxsdk was given. 65572 if test "${with_dxsdk+set}" = set; then : 65573 withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5 65574 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;} 65575 fi 65576 65577 65578 65579 65580 # Check whether --with-dxsdk-lib was given. 65581 if test "${with_dxsdk_lib+set}" = set; then : 65582 withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5 65583 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;} 65584 fi 65585 65586 65587 65588 65589 # Check whether --with-dxsdk-include was given. 65590 if test "${with_dxsdk_include+set}" = set; then : 65591 withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5 65592 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;} 65593 fi 65594 65595 65596 fi 65597 65598 # Control if libzip can use mmap. Available for purposes of overriding. 65599 LIBZIP_CAN_USE_MMAP=true 65600 65601 65602 65603 if test "$OPENJDK_TARGET_OS" = "solaris" && test "x$BUILD_GTEST" = "xtrue"; then 65604 # Find the root of the Solaris Studio installation from the compiler path 65605 SOLARIS_STUDIO_DIR="$(dirname $CC)/.." 65606 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4$OPENJDK_TARGET_CPU_ISADIR/libstlport.so.1" 65607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libstlport.so.1" >&5 65608 $as_echo_n "checking for libstlport.so.1... " >&6; } 65609 if ! test -f "$STLPORT_LIB" && test "x$OPENJDK_TARGET_CPU_ISADIR" = "x/sparcv9"; then 65610 # SS12u3 has libstlport under 'stlport4/v9' instead of 'stlport4/sparcv9' 65611 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4/v9/libstlport.so.1" 65612 fi 65613 if test -f "$STLPORT_LIB"; then 65614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, $STLPORT_LIB" >&5 65615 $as_echo "yes, $STLPORT_LIB" >&6; } 65616 65617 # Only process if variable expands to non-empty 65618 65619 if test "x$STLPORT_LIB" != x; then 65620 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65621 65622 # Input might be given as Windows format, start by converting to 65623 # unix format. 65624 path="$STLPORT_LIB" 65625 new_path=`$CYGPATH -u "$path"` 65626 65627 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 65628 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 65629 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 65630 # "foo.exe" is OK but "foo" is an error. 65631 # 65632 # This test is therefore slightly more accurate than "test -f" to check for file precense. 65633 # It is also a way to make sure we got the proper file name for the real test later on. 65634 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 65635 if test "x$test_shortpath" = x; then 65636 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 65637 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 65638 as_fn_error $? "Cannot locate the the path of STLPORT_LIB" "$LINENO" 5 65639 fi 65640 65641 # Call helper function which possibly converts this using DOS-style short mode. 65642 # If so, the updated path is stored in $new_path. 65643 65644 input_path="$new_path" 65645 # Check if we need to convert this using DOS-style short mode. If the path 65646 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65647 # take no chances and rewrite it. 65648 # Note: m4 eats our [], so we need to use [ and ] instead. 65649 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 65650 if test "x$has_forbidden_chars" != x; then 65651 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65652 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 65653 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 65654 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 65655 # Going to short mode and back again did indeed matter. Since short mode is 65656 # case insensitive, let's make it lowercase to improve readability. 65657 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65658 # Now convert it back to Unix-style (cygpath) 65659 input_path=`$CYGPATH -u "$shortmode_path"` 65660 new_path="$input_path" 65661 fi 65662 fi 65663 65664 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 65665 if test "x$test_cygdrive_prefix" = x; then 65666 # As a simple fix, exclude /usr/bin since it's not a real path. 65667 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 65668 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 65669 # a path prefixed by /cygdrive for fixpath to work. 65670 new_path="$CYGWIN_ROOT_PATH$input_path" 65671 fi 65672 fi 65673 65674 65675 if test "x$path" != "x$new_path"; then 65676 STLPORT_LIB="$new_path" 65677 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 65678 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 65679 fi 65680 65681 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65682 65683 path="$STLPORT_LIB" 65684 has_colon=`$ECHO $path | $GREP ^.:` 65685 new_path="$path" 65686 if test "x$has_colon" = x; then 65687 # Not in mixed or Windows style, start by that. 65688 new_path=`cmd //c echo $path` 65689 fi 65690 65691 65692 input_path="$new_path" 65693 # Check if we need to convert this using DOS-style short mode. If the path 65694 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65695 # take no chances and rewrite it. 65696 # Note: m4 eats our [], so we need to use [ and ] instead. 65697 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 65698 if test "x$has_forbidden_chars" != x; then 65699 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65700 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65701 fi 65702 65703 65704 windows_path="$new_path" 65705 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65706 unix_path=`$CYGPATH -u "$windows_path"` 65707 new_path="$unix_path" 65708 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65709 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 65710 new_path="$unix_path" 65711 fi 65712 65713 if test "x$path" != "x$new_path"; then 65714 STLPORT_LIB="$new_path" 65715 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 65716 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 65717 fi 65718 65719 # Save the first 10 bytes of this path to the storage, so fixpath can work. 65720 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 65721 65722 else 65723 # We're on a unix platform. Hooray! :) 65724 path="$STLPORT_LIB" 65725 has_space=`$ECHO "$path" | $GREP " "` 65726 if test "x$has_space" != x; then 65727 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 65728 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 65729 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 65730 fi 65731 65732 # Use eval to expand a potential ~ 65733 eval path="$path" 65734 if test ! -f "$path" && test ! -d "$path"; then 65735 as_fn_error $? "The path of STLPORT_LIB, which resolves as \"$path\", is not found." "$LINENO" 5 65736 fi 65737 65738 if test -d "$path"; then 65739 STLPORT_LIB="`cd "$path"; $THEPWDCMD -L`" 65740 else 65741 dir="`$DIRNAME "$path"`" 65742 base="`$BASENAME "$path"`" 65743 STLPORT_LIB="`cd "$dir"; $THEPWDCMD -L`/$base" 65744 fi 65745 fi 65746 fi 65747 65748 else 65749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found at $STLPORT_LIB" >&5 65750 $as_echo "no, not found at $STLPORT_LIB" >&6; } 65751 as_fn_error $? "Failed to find libstlport.so.1, cannot build Hotspot gtests" "$LINENO" 5 65752 fi 65753 65754 fi 65755 65756 65757 65758 65759 65760 65761 65762 65763 65764 65765 65766 65767 65768 65769 # Hotspot setup depends on lib checks. 65770 65771 65772 # The user can in some cases supply additional jvm features. For the custom 65773 # variant, this defines the entire variant. 65774 65775 # Check whether --with-jvm-features was given. 65776 if test "${with_jvm_features+set}" = set; then : 65777 withval=$with_jvm_features; 65778 fi 65779 65780 if test "x$with_jvm_features" != x; then 65781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional JVM features" >&5 65782 $as_echo_n "checking additional JVM features... " >&6; } 65783 JVM_FEATURES=`$ECHO $with_jvm_features | $SED -e 's/,/ /g'` 65784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES" >&5 65785 $as_echo "$JVM_FEATURES" >&6; } 65786 fi 65787 65788 # Override hotspot cpu definitions for ARM platforms 65789 if test "x$OPENJDK_TARGET_CPU" = xarm; then 65790 HOTSPOT_TARGET_CPU=arm_32 65791 HOTSPOT_TARGET_CPU_DEFINE="ARM32" 65792 JVM_LDFLAGS="$JVM_LDFLAGS -fsigned-char" 65793 JVM_CFLAGS="$JVM_CFLAGS -DARM -fsigned-char" 65794 elif test "x$OPENJDK_TARGET_CPU" = xaarch64 && test "x$HOTSPOT_TARGET_CPU_PORT" = xarm64; then 65795 HOTSPOT_TARGET_CPU=arm_64 65796 HOTSPOT_TARGET_CPU_ARCH=arm 65797 JVM_LDFLAGS="$JVM_LDFLAGS -fsigned-char" 65798 JVM_CFLAGS="$JVM_CFLAGS -DARM -fsigned-char" 65799 fi 65800 65801 # Verify that dependencies are met for explicitly set features. 65802 if [[ " $JVM_FEATURES " =~ " jvmti " ]] && ! [[ " $JVM_FEATURES " =~ " services " ]] ; then 65803 as_fn_error $? "Specified JVM feature 'jvmti' requires feature 'services'" "$LINENO" 5 65804 fi 65805 65806 if [[ " $JVM_FEATURES " =~ " management " ]] && ! [[ " $JVM_FEATURES " =~ " nmt " ]] ; then 65807 as_fn_error $? "Specified JVM feature 'management' requires feature 'nmt'" "$LINENO" 5 65808 fi 65809 65810 if [[ " $JVM_FEATURES " =~ " jvmci " ]] && ! ( [[ " $JVM_FEATURES " =~ " compiler1 " ]] || [[ " $JVM_FEATURES " =~ " compiler2 " ]] ); then 65811 as_fn_error $? "Specified JVM feature 'jvmci' requires feature 'compiler2' or 'compiler1'" "$LINENO" 5 65812 fi 65813 65814 if [[ " $JVM_FEATURES " =~ " compiler2 " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 65815 as_fn_error $? "Specified JVM feature 'compiler2' requires feature 'all-gcs'" "$LINENO" 5 65816 fi 65817 65818 if [[ " $JVM_FEATURES " =~ " vm-structs " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 65819 as_fn_error $? "Specified JVM feature 'vm-structs' requires feature 'all-gcs'" "$LINENO" 5 65820 fi 65821 65822 # Turn on additional features based on other parts of configure 65823 if test "x$INCLUDE_DTRACE" = "xtrue"; then 65824 JVM_FEATURES="$JVM_FEATURES dtrace" 65825 else 65826 if [[ " $JVM_FEATURES " =~ " dtrace " ]] ; then 65827 as_fn_error $? "To enable dtrace, you must use --enable-dtrace" "$LINENO" 5 65828 fi 65829 fi 65830 65831 if test "x$STATIC_BUILD" = "xtrue"; then 65832 JVM_FEATURES="$JVM_FEATURES static-build" 65833 else 65834 if [[ " $JVM_FEATURES " =~ " static-build " ]] ; then 65835 as_fn_error $? "To enable static-build, you must use --enable-static-build" "$LINENO" 5 65836 fi 65837 fi 65838 65839 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 65840 if [[ " $JVM_FEATURES " =~ " zero " ]] ; then 65841 as_fn_error $? "To enable zero/zeroshark, you must use --with-jvm-variants=zero/zeroshark" "$LINENO" 5 65842 fi 65843 fi 65844 65845 if ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 65846 if [[ " $JVM_FEATURES " =~ " shark " ]] ; then 65847 as_fn_error $? "To enable shark, you must use --with-jvm-variants=zeroshark" "$LINENO" 5 65848 fi 65849 fi 65850 65851 # Only enable jvmci on x86_64, sparcv9 and aarch64. 65852 if test "x$OPENJDK_TARGET_CPU" = "xx86_64" || \ 65853 test "x$OPENJDK_TARGET_CPU" = "xsparcv9" || \ 65854 test "x$OPENJDK_TARGET_CPU" = "xaarch64" ; then 65855 JVM_FEATURES_jvmci="jvmci" 65856 else 65857 JVM_FEATURES_jvmci="" 65858 fi 65859 65860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jdk.internal.vm.compiler should be built" >&5 65861 $as_echo_n "checking if jdk.internal.vm.compiler should be built... " >&6; } 65862 if [[ " $JVM_FEATURES " =~ " graal " ]] ; then 65863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 65864 $as_echo "yes, forced" >&6; } 65865 if test "x$JVM_FEATURES_jvmci" != "xjvmci" ; then 65866 as_fn_error $? "Specified JVM feature 'graal' requires feature 'jvmci'" "$LINENO" 5 65867 fi 65868 INCLUDE_GRAAL="true" 65869 else 65870 # By default enable graal build on linux-x64 or where AOT is available. 65871 # graal build requires jvmci. 65872 if test "x$JVM_FEATURES_jvmci" = "xjvmci" && \ 65873 (test "x$OPENJDK_TARGET_CPU" = "xx86_64" && \ 65874 test "x$OPENJDK_TARGET_OS" = "xlinux" || \ 65875 test "x$ENABLE_AOT" = "xtrue") ; then 65876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65877 $as_echo "yes" >&6; } 65878 JVM_FEATURES_graal="graal" 65879 INCLUDE_GRAAL="true" 65880 else 65881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65882 $as_echo "no" >&6; } 65883 JVM_FEATURES_graal="" 65884 INCLUDE_GRAAL="false" 65885 fi 65886 fi 65887 65888 65889 65890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aot should be enabled" >&5 65891 $as_echo_n "checking if aot should be enabled... " >&6; } 65892 if test "x$ENABLE_AOT" = "xtrue"; then 65893 if test "x$enable_aot" = "xyes"; then 65894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 65895 $as_echo "yes, forced" >&6; } 65896 else 65897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65898 $as_echo "yes" >&6; } 65899 fi 65900 JVM_FEATURES_aot="aot" 65901 else 65902 if test "x$enable_aot" = "xno"; then 65903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 65904 $as_echo "no, forced" >&6; } 65905 else 65906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65907 $as_echo "no" >&6; } 65908 fi 65909 JVM_FEATURES_aot="" 65910 fi 65911 65912 if test "x$OPENJDK_TARGET_CPU" = xarm ; then 65913 # Default to use link time optimizations on minimal on arm 65914 JVM_FEATURES_link_time_opt="link-time-opt" 65915 else 65916 JVM_FEATURES_link_time_opt="" 65917 fi 65918 65919 # All variants but minimal (and custom) get these features 65920 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES jvmti vm-structs jni-check services management all-gcs nmt" 65921 if test "x$ENABLE_CDS" = "xtrue"; then 65922 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES cds" 65923 fi 65924 65925 # Enable features depending on variant. 65926 JVM_FEATURES_server="compiler1 compiler2 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci $JVM_FEATURES_aot $JVM_FEATURES_graal" 65927 JVM_FEATURES_client="compiler1 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 65928 JVM_FEATURES_core="$NON_MINIMAL_FEATURES $JVM_FEATURES" 65929 JVM_FEATURES_minimal="compiler1 minimal $JVM_FEATURES $JVM_FEATURES_link_time_opt" 65930 JVM_FEATURES_zero="zero $NON_MINIMAL_FEATURES $JVM_FEATURES" 65931 JVM_FEATURES_zeroshark="zero shark $NON_MINIMAL_FEATURES $JVM_FEATURES" 65932 JVM_FEATURES_custom="$JVM_FEATURES" 65933 65934 65935 65936 65937 65938 65939 65940 65941 65942 # Used for verification of Makefiles by check-jvm-feature 65943 65944 65945 # We don't support --with-jvm-interpreter anymore, use zero instead. 65946 65947 65948 # Check whether --with-jvm-interpreter was given. 65949 if test "${with_jvm_interpreter+set}" = set; then : 65950 withval=$with_jvm_interpreter; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&5 65951 $as_echo "$as_me: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&2;} 65952 fi 65953 65954 65955 65956 65957 ############################################################################### 65958 # 65959 # We need to do some final tweaking, when everything else is done. 65960 # 65961 ############################################################################### 65962 65963 65964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 65965 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 65966 65967 if test -d "${TOPDIR}/src/jdk.crypto.ec/share/native/libsunec/impl"; then 65968 ENABLE_INTREE_EC=true 65969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65970 $as_echo "yes" >&6; } 65971 else 65972 ENABLE_INTREE_EC=false 65973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65974 $as_echo "no" >&6; } 65975 fi 65976 65977 65978 65979 65980 # Check whether --enable-jtreg-failure-handler was given. 65981 if test "${enable_jtreg_failure_handler+set}" = set; then : 65982 enableval=$enable_jtreg_failure_handler; 65983 fi 65984 65985 65986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jtreg failure handler should be built" >&5 65987 $as_echo_n "checking if jtreg failure handler should be built... " >&6; } 65988 65989 if test "x$enable_jtreg_failure_handler" = "xyes"; then 65990 if test "x$JT_HOME" = "x"; then 65991 as_fn_error $? "Cannot enable jtreg failure handler without jtreg." "$LINENO" 5 65992 else 65993 BUILD_FAILURE_HANDLER=true 65994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 65995 $as_echo "yes, forced" >&6; } 65996 fi 65997 elif test "x$enable_jtreg_failure_handler" = "xno"; then 65998 BUILD_FAILURE_HANDLER=false 65999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 66000 $as_echo "no, forced" >&6; } 66001 elif test "x$enable_jtreg_failure_handler" = "xauto" \ 66002 || test "x$enable_jtreg_failure_handler" = "x"; then 66003 if test "x$JT_HOME" = "x"; then 66004 BUILD_FAILURE_HANDLER=false 66005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing jtreg" >&5 66006 $as_echo "no, missing jtreg" >&6; } 66007 else 66008 BUILD_FAILURE_HANDLER=true 66009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, jtreg present" >&5 66010 $as_echo "yes, jtreg present" >&6; } 66011 fi 66012 else 66013 as_fn_error $? "Invalid value for --enable-jtreg-failure-handler: $enable_jtreg_failure_handler" "$LINENO" 5 66014 fi 66015 66016 66017 66018 66019 # Check whether --enable-generate-classlist was given. 66020 if test "${enable_generate_classlist+set}" = set; then : 66021 enableval=$enable_generate_classlist; 66022 fi 66023 66024 66025 # Check if it's likely that it's possible to generate the classlist. Depending 66026 # on exact jvm configuration it could be possible anyway. 66027 if test "x$ENABLE_CDS" = "xtrue" && ( [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] ); then 66028 ENABLE_GENERATE_CLASSLIST_POSSIBLE="true" 66029 else 66030 ENABLE_GENERATE_CLASSLIST_POSSIBLE="false" 66031 fi 66032 66033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the CDS classlist generation should be enabled" >&5 66034 $as_echo_n "checking if the CDS classlist generation should be enabled... " >&6; } 66035 if test "x$enable_generate_classlist" = "xyes"; then 66036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 66037 $as_echo "yes, forced" >&6; } 66038 ENABLE_GENERATE_CLASSLIST="true" 66039 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xfalse"; then 66040 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS and enable-cds=$ENABLE_CDS" >&5 66041 $as_echo "$as_me: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS and enable-cds=$ENABLE_CDS" >&2;} 66042 fi 66043 elif test "x$enable_generate_classlist" = "xno"; then 66044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 66045 $as_echo "no, forced" >&6; } 66046 ENABLE_GENERATE_CLASSLIST="false" 66047 elif test "x$enable_generate_classlist" = "x"; then 66048 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xtrue"; then 66049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 66050 $as_echo "yes" >&6; } 66051 ENABLE_GENERATE_CLASSLIST="true" 66052 else 66053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66054 $as_echo "no" >&6; } 66055 ENABLE_GENERATE_CLASSLIST="false" 66056 fi 66057 else 66058 as_fn_error $? "Invalid value for --enable-generate-classlist: $enable_generate_classlist" "$LINENO" 5 66059 fi 66060 66061 66062 66063 66064 ############################################################################### 66065 # 66066 # Configure parts of the build that only affect the build performance, 66067 # not the result. 66068 # 66069 ############################################################################### 66070 66071 66072 # How many cores do we have on this build system? 66073 66074 # Check whether --with-num-cores was given. 66075 if test "${with_num_cores+set}" = set; then : 66076 withval=$with_num_cores; 66077 fi 66078 66079 if test "x$with_num_cores" = x; then 66080 # The number of cores were not specified, try to probe them. 66081 66082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 66083 $as_echo_n "checking for number of cores... " >&6; } 66084 NUM_CORES=1 66085 FOUND_CORES=no 66086 66087 if test -f /proc/cpuinfo; then 66088 # Looks like a Linux (or cygwin) system 66089 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 66090 FOUND_CORES=yes 66091 elif test -x /usr/sbin/psrinfo; then 66092 # Looks like a Solaris system 66093 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 66094 FOUND_CORES=yes 66095 elif test -x /usr/sbin/sysctl; then 66096 # Looks like a MacOSX system 66097 NUM_CORES=`/usr/sbin/sysctl -n hw.ncpu` 66098 FOUND_CORES=yes 66099 elif test "x$OPENJDK_BUILD_OS" = xaix ; then 66100 NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'` 66101 FOUND_CORES=yes 66102 elif test -n "$NUMBER_OF_PROCESSORS"; then 66103 # On windows, look in the env 66104 NUM_CORES=$NUMBER_OF_PROCESSORS 66105 FOUND_CORES=yes 66106 fi 66107 66108 if test "x$FOUND_CORES" = xyes; then 66109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 66110 $as_echo "$NUM_CORES" >&6; } 66111 else 66112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 66113 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 66114 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 66115 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 66116 fi 66117 66118 else 66119 NUM_CORES=$with_num_cores 66120 fi 66121 66122 66123 66124 # How much memory do we have on this build system? 66125 66126 # Check whether --with-memory-size was given. 66127 if test "${with_memory_size+set}" = set; then : 66128 withval=$with_memory_size; 66129 fi 66130 66131 if test "x$with_memory_size" = x; then 66132 # The memory size was not specified, try to probe it. 66133 66134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 66135 $as_echo_n "checking for memory size... " >&6; } 66136 # Default to 1024 MB 66137 MEMORY_SIZE=1024 66138 FOUND_MEM=no 66139 66140 if test -f /proc/meminfo; then 66141 # Looks like a Linux (or cygwin) system 66142 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 66143 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 66144 FOUND_MEM=yes 66145 elif test -x /usr/sbin/prtconf; then 66146 # Looks like a Solaris or AIX system 66147 MEMORY_SIZE=`/usr/sbin/prtconf 2> /dev/null | grep "^Memory [Ss]ize" | awk '{ print $3 }'` 66148 FOUND_MEM=yes 66149 elif test -x /usr/sbin/sysctl; then 66150 # Looks like a MacOSX system 66151 MEMORY_SIZE=`/usr/sbin/sysctl -n hw.memsize` 66152 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 66153 FOUND_MEM=yes 66154 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 66155 # Windows, but without cygwin 66156 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 66157 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 66158 FOUND_MEM=yes 66159 fi 66160 66161 if test "x$FOUND_MEM" = xyes; then 66162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 66163 $as_echo "$MEMORY_SIZE MB" >&6; } 66164 else 66165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to $MEMORY_SIZE MB" >&5 66166 $as_echo "could not detect memory size, defaulting to $MEMORY_SIZE MB" >&6; } 66167 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 66168 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 66169 fi 66170 66171 else 66172 MEMORY_SIZE=$with_memory_size 66173 fi 66174 66175 66176 66177 # Provide a decent default number of parallel jobs for make depending on 66178 # number of cores, amount of memory and machine architecture. 66179 66180 # Check whether --with-jobs was given. 66181 if test "${with_jobs+set}" = set; then : 66182 withval=$with_jobs; 66183 fi 66184 66185 if test "x$with_jobs" = x; then 66186 # Number of jobs was not specified, calculate. 66187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 66188 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 66189 # Approximate memory in GB. 66190 memory_gb=`expr $MEMORY_SIZE / 1024` 66191 # Pick the lowest of memory in gb and number of cores. 66192 if test "$memory_gb" -lt "$NUM_CORES"; then 66193 JOBS="$memory_gb" 66194 else 66195 JOBS="$NUM_CORES" 66196 fi 66197 if test "$JOBS" -eq "0"; then 66198 JOBS=1 66199 fi 66200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 66201 $as_echo "$JOBS" >&6; } 66202 else 66203 JOBS=$with_jobs 66204 fi 66205 66206 66207 66208 # The number of test jobs will be chosen automatically if TEST_JOBS is 0 66209 66210 # Check whether --with-test-jobs was given. 66211 if test "${with_test_jobs+set}" = set; then : 66212 withval=$with_test_jobs; 66213 fi 66214 66215 if test "x$with_test_jobs" = x; then 66216 TEST_JOBS=0 66217 else 66218 TEST_JOBS=$with_test_jobs 66219 fi 66220 66221 66222 66223 # Setup arguments for the boot jdk (after cores and memory have been setup) 66224 66225 ############################################################################## 66226 # 66227 # Specify jvm options for anything that is run with the Boot JDK. 66228 # Not all JVM:s accept the same arguments on the command line. 66229 # 66230 66231 # Check whether --with-boot-jdk-jvmargs was given. 66232 if test "${with_boot_jdk_jvmargs+set}" = set; then : 66233 withval=$with_boot_jdk_jvmargs; 66234 fi 66235 66236 66237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5 66238 $as_echo_n "checking flags for boot jdk java command ... " >&6; } 66239 66240 # Disable special log output when a debug build is used as Boot JDK... 66241 66242 $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5 66243 $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5 66244 OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1` 66245 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66246 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66247 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66248 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" 66249 JVM_ARG_OK=true 66250 else 66251 $ECHO "Arg failed:" >&5 66252 $ECHO "$OUTPUT" >&5 66253 JVM_ARG_OK=false 66254 fi 66255 66256 66257 # Force en-US environment 66258 66259 $ECHO "Check if jvm arg is ok: -Duser.language=en -Duser.country=US" >&5 66260 $ECHO "Command: $JAVA -Duser.language=en -Duser.country=US -version" >&5 66261 OUTPUT=`$JAVA -Duser.language=en -Duser.country=US -version 2>&1` 66262 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66263 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66264 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66265 boot_jdk_jvmargs="$boot_jdk_jvmargs -Duser.language=en -Duser.country=US" 66266 JVM_ARG_OK=true 66267 else 66268 $ECHO "Arg failed:" >&5 66269 $ECHO "$OUTPUT" >&5 66270 JVM_ARG_OK=false 66271 fi 66272 66273 66274 if test "x$BOOTJDK_USE_LOCAL_CDS" = xtrue; then 66275 # Use our own CDS archive 66276 66277 $ECHO "Check if jvm arg is ok: $boot_jdk_cds_args -Xshare:auto" >&5 66278 $ECHO "Command: $JAVA $boot_jdk_cds_args -Xshare:auto -version" >&5 66279 OUTPUT=`$JAVA $boot_jdk_cds_args -Xshare:auto -version 2>&1` 66280 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66281 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66282 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66283 boot_jdk_jvmargs="$boot_jdk_jvmargs $boot_jdk_cds_args -Xshare:auto" 66284 JVM_ARG_OK=true 66285 else 66286 $ECHO "Arg failed:" >&5 66287 $ECHO "$OUTPUT" >&5 66288 JVM_ARG_OK=false 66289 fi 66290 66291 else 66292 # Otherwise optimistically use the system-wide one, if one is present 66293 66294 $ECHO "Check if jvm arg is ok: -Xshare:auto" >&5 66295 $ECHO "Command: $JAVA -Xshare:auto -version" >&5 66296 OUTPUT=`$JAVA -Xshare:auto -version 2>&1` 66297 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66298 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66299 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66300 boot_jdk_jvmargs="$boot_jdk_jvmargs -Xshare:auto" 66301 JVM_ARG_OK=true 66302 else 66303 $ECHO "Arg failed:" >&5 66304 $ECHO "$OUTPUT" >&5 66305 JVM_ARG_OK=false 66306 fi 66307 66308 fi 66309 66310 # Apply user provided options. 66311 66312 $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5 66313 $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5 66314 OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1` 66315 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66316 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66317 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66318 boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs" 66319 JVM_ARG_OK=true 66320 else 66321 $ECHO "Arg failed:" >&5 66322 $ECHO "$OUTPUT" >&5 66323 JVM_ARG_OK=false 66324 fi 66325 66326 66327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5 66328 $as_echo "$boot_jdk_jvmargs" >&6; } 66329 66330 # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs 66331 JAVA_FLAGS=$boot_jdk_jvmargs 66332 66333 66334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5 66335 $as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; } 66336 66337 # Starting amount of heap memory. 66338 66339 $ECHO "Check if jvm arg is ok: -Xms64M" >&5 66340 $ECHO "Command: $JAVA -Xms64M -version" >&5 66341 OUTPUT=`$JAVA -Xms64M -version 2>&1` 66342 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66343 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66344 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66345 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M" 66346 JVM_ARG_OK=true 66347 else 66348 $ECHO "Arg failed:" >&5 66349 $ECHO "$OUTPUT" >&5 66350 JVM_ARG_OK=false 66351 fi 66352 66353 BOOTCYCLE_JVM_ARGS_BIG=-Xms64M 66354 66355 # Maximum amount of heap memory and stack size. 66356 JVM_HEAP_LIMIT_32="1024" 66357 # Running a 64 bit JVM allows for and requires a bigger heap 66358 JVM_HEAP_LIMIT_64="1600" 66359 STACK_SIZE_32=768 66360 STACK_SIZE_64=1536 66361 JVM_HEAP_LIMIT_GLOBAL=`expr $MEMORY_SIZE / 2` 66362 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_32"; then 66363 JVM_HEAP_LIMIT_32=$JVM_HEAP_LIMIT_GLOBAL 66364 fi 66365 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_64"; then 66366 JVM_HEAP_LIMIT_64=$JVM_HEAP_LIMIT_GLOBAL 66367 fi 66368 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "512"; then 66369 JVM_HEAP_LIMIT_32=512 66370 JVM_HEAP_LIMIT_64=512 66371 fi 66372 66373 if test "x$BOOT_JDK_BITS" = "x32"; then 66374 STACK_SIZE=$STACK_SIZE_32 66375 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_32 66376 else 66377 STACK_SIZE=$STACK_SIZE_64 66378 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_64 66379 fi 66380 66381 $ECHO "Check if jvm arg is ok: -Xmx${JVM_MAX_HEAP}M" >&5 66382 $ECHO "Command: $JAVA -Xmx${JVM_MAX_HEAP}M -version" >&5 66383 OUTPUT=`$JAVA -Xmx${JVM_MAX_HEAP}M -version 2>&1` 66384 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66385 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66386 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66387 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx${JVM_MAX_HEAP}M" 66388 JVM_ARG_OK=true 66389 else 66390 $ECHO "Arg failed:" >&5 66391 $ECHO "$OUTPUT" >&5 66392 JVM_ARG_OK=false 66393 fi 66394 66395 66396 $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5 66397 $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5 66398 OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1` 66399 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66400 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66401 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66402 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE" 66403 JVM_ARG_OK=true 66404 else 66405 $ECHO "Arg failed:" >&5 66406 $ECHO "$OUTPUT" >&5 66407 JVM_ARG_OK=false 66408 fi 66409 66410 66411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5 66412 $as_echo "$boot_jdk_jvmargs_big" >&6; } 66413 66414 JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big 66415 66416 66417 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 66418 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_32 66419 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_32 66420 else 66421 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_64 66422 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_64 66423 fi 66424 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -Xmx${BOOTCYCLE_MAX_HEAP}M" 66425 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -XX:ThreadStackSize=$BOOTCYCLE_STACK_SIZE" 66426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for bootcycle boot jdk java command for big workloads" >&5 66427 $as_echo_n "checking flags for bootcycle boot jdk java command for big workloads... " >&6; } 66428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOTCYCLE_JVM_ARGS_BIG" >&5 66429 $as_echo "$BOOTCYCLE_JVM_ARGS_BIG" >&6; } 66430 66431 66432 # By default, the main javac compilations use big 66433 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_BIG" 66434 66435 66436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5 66437 $as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; } 66438 66439 # Use serial gc for small short lived tools if possible 66440 66441 $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5 66442 $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5 66443 OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1` 66444 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66445 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66446 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66447 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC" 66448 JVM_ARG_OK=true 66449 else 66450 $ECHO "Arg failed:" >&5 66451 $ECHO "$OUTPUT" >&5 66452 JVM_ARG_OK=false 66453 fi 66454 66455 66456 $ECHO "Check if jvm arg is ok: -Xms32M" >&5 66457 $ECHO "Command: $JAVA -Xms32M -version" >&5 66458 OUTPUT=`$JAVA -Xms32M -version 2>&1` 66459 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66460 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66461 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66462 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M" 66463 JVM_ARG_OK=true 66464 else 66465 $ECHO "Arg failed:" >&5 66466 $ECHO "$OUTPUT" >&5 66467 JVM_ARG_OK=false 66468 fi 66469 66470 66471 $ECHO "Check if jvm arg is ok: -Xmx512M" >&5 66472 $ECHO "Command: $JAVA -Xmx512M -version" >&5 66473 OUTPUT=`$JAVA -Xmx512M -version 2>&1` 66474 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66475 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66476 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66477 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M" 66478 JVM_ARG_OK=true 66479 else 66480 $ECHO "Arg failed:" >&5 66481 $ECHO "$OUTPUT" >&5 66482 JVM_ARG_OK=false 66483 fi 66484 66485 66486 $ECHO "Check if jvm arg is ok: -XX:TieredStopAtLevel=1" >&5 66487 $ECHO "Command: $JAVA -XX:TieredStopAtLevel=1 -version" >&5 66488 OUTPUT=`$JAVA -XX:TieredStopAtLevel=1 -version 2>&1` 66489 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66490 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66491 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66492 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:TieredStopAtLevel=1" 66493 JVM_ARG_OK=true 66494 else 66495 $ECHO "Arg failed:" >&5 66496 $ECHO "$OUTPUT" >&5 66497 JVM_ARG_OK=false 66498 fi 66499 66500 66501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5 66502 $as_echo "$boot_jdk_jvmargs_small" >&6; } 66503 66504 JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small 66505 66506 66507 JAVA_TOOL_FLAGS_SMALL="" 66508 for f in $JAVA_FLAGS_SMALL; do 66509 JAVA_TOOL_FLAGS_SMALL="$JAVA_TOOL_FLAGS_SMALL -J$f" 66510 done 66511 66512 66513 66514 # Setup smart javac (after cores and memory have been setup) 66515 66516 66517 # Check whether --with-sjavac-server-java was given. 66518 if test "${with_sjavac_server_java+set}" = set; then : 66519 withval=$with_sjavac_server_java; 66520 fi 66521 66522 66523 if test "x$with_sjavac_server_java" != x; then 66524 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 66525 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 66526 if test "x$FOUND_VERSION" = x; then 66527 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 66528 fi 66529 else 66530 SJAVAC_SERVER_JAVA="$JAVA" 66531 fi 66532 66533 66534 if test "$MEMORY_SIZE" -gt "3000"; then 66535 if "$JAVA" -version 2>&1 | $GREP -q "64-Bit"; then 66536 JVM_64BIT=true 66537 fi 66538 fi 66539 66540 MX_VALUE=`expr $MEMORY_SIZE / 2` 66541 if test "$JVM_64BIT" = true; then 66542 # Set ms lower than mx since more than one instance of the server might 66543 # get launched at the same time before they figure out which instance won. 66544 MS_VALUE=512 66545 if test "$MX_VALUE" -gt "2048"; then 66546 MX_VALUE=2048 66547 fi 66548 else 66549 MS_VALUE=256 66550 if test "$MX_VALUE" -gt "1500"; then 66551 MX_VALUE=1500 66552 fi 66553 fi 66554 if test "$MX_VALUE" -lt "512"; then 66555 MX_VALUE=512 66556 fi 66557 66558 $ECHO "Check if jvm arg is ok: -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" >&5 66559 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version" >&5 66560 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version 2>&1` 66561 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66562 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66563 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66564 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" 66565 JVM_ARG_OK=true 66566 else 66567 $ECHO "Arg failed:" >&5 66568 $ECHO "$OUTPUT" >&5 66569 JVM_ARG_OK=false 66570 fi 66571 66572 66573 66574 # Check whether --enable-sjavac was given. 66575 if test "${enable_sjavac+set}" = set; then : 66576 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 66577 else 66578 ENABLE_SJAVAC="no" 66579 fi 66580 66581 if test "x$JVM_ARG_OK" = "xfalse"; then 66582 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&5 66583 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&2;} 66584 ENABLE_SJAVAC="no" 66585 fi 66586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 66587 $as_echo_n "checking whether to use sjavac... " >&6; } 66588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 66589 $as_echo "$ENABLE_SJAVAC" >&6; } 66590 66591 66592 # Check whether --enable-javac-server was given. 66593 if test "${enable_javac_server+set}" = set; then : 66594 enableval=$enable_javac_server; ENABLE_JAVAC_SERVER="${enableval}" 66595 else 66596 ENABLE_JAVAC_SERVER="yes" 66597 fi 66598 66599 if test "x$JVM_ARG_OK" = "xfalse"; then 66600 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&5 66601 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&2;} 66602 ENABLE_JAVAC_SERVER="no" 66603 fi 66604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use javac server" >&5 66605 $as_echo_n "checking whether to use javac server... " >&6; } 66606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_JAVAC_SERVER" >&5 66607 $as_echo "$ENABLE_JAVAC_SERVER" >&6; } 66608 66609 66610 if test "x$ENABLE_JAVAC_SERVER" = "xyes" || test "x$ENABLE_SJAVAC" = "xyes"; then 66611 # When using a server javac, the small client instances do not need much 66612 # resources. 66613 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_SMALL" 66614 fi 66615 66616 66617 # Setup use of icecc if requested 66618 66619 # Check whether --enable-icecc was given. 66620 if test "${enable_icecc+set}" = set; then : 66621 enableval=$enable_icecc; 66622 fi 66623 66624 66625 if test "x${enable_icecc}" = "xyes"; then 66626 66627 66628 66629 # Publish this variable in the help. 66630 66631 66632 if [ -z "${ICECC_CMD+x}" ]; then 66633 # The variable is not set by user, try to locate tool using the code snippet 66634 for ac_prog in icecc 66635 do 66636 # Extract the first word of "$ac_prog", so it can be a program name with args. 66637 set dummy $ac_prog; ac_word=$2 66638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66639 $as_echo_n "checking for $ac_word... " >&6; } 66640 if ${ac_cv_path_ICECC_CMD+:} false; then : 66641 $as_echo_n "(cached) " >&6 66642 else 66643 case $ICECC_CMD in 66644 [\\/]* | ?:[\\/]*) 66645 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 66646 ;; 66647 *) 66648 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66649 for as_dir in $PATH 66650 do 66651 IFS=$as_save_IFS 66652 test -z "$as_dir" && as_dir=. 66653 for ac_exec_ext in '' $ac_executable_extensions; do 66654 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66655 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 66656 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66657 break 2 66658 fi 66659 done 66660 done 66661 IFS=$as_save_IFS 66662 66663 ;; 66664 esac 66665 fi 66666 ICECC_CMD=$ac_cv_path_ICECC_CMD 66667 if test -n "$ICECC_CMD"; then 66668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 66669 $as_echo "$ICECC_CMD" >&6; } 66670 else 66671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66672 $as_echo "no" >&6; } 66673 fi 66674 66675 66676 test -n "$ICECC_CMD" && break 66677 done 66678 66679 else 66680 # The variable is set, but is it from the command line or the environment? 66681 66682 # Try to remove the string !ICECC_CMD! from our list. 66683 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CMD!/} 66684 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 66685 # If it failed, the variable was not from the command line. Ignore it, 66686 # but warn the user (except for BASH, which is always set by the calling BASH). 66687 if test "xICECC_CMD" != xBASH; then 66688 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&5 66689 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&2;} 66690 fi 66691 # Try to locate tool using the code snippet 66692 for ac_prog in icecc 66693 do 66694 # Extract the first word of "$ac_prog", so it can be a program name with args. 66695 set dummy $ac_prog; ac_word=$2 66696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66697 $as_echo_n "checking for $ac_word... " >&6; } 66698 if ${ac_cv_path_ICECC_CMD+:} false; then : 66699 $as_echo_n "(cached) " >&6 66700 else 66701 case $ICECC_CMD in 66702 [\\/]* | ?:[\\/]*) 66703 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 66704 ;; 66705 *) 66706 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66707 for as_dir in $PATH 66708 do 66709 IFS=$as_save_IFS 66710 test -z "$as_dir" && as_dir=. 66711 for ac_exec_ext in '' $ac_executable_extensions; do 66712 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66713 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 66714 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66715 break 2 66716 fi 66717 done 66718 done 66719 IFS=$as_save_IFS 66720 66721 ;; 66722 esac 66723 fi 66724 ICECC_CMD=$ac_cv_path_ICECC_CMD 66725 if test -n "$ICECC_CMD"; then 66726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 66727 $as_echo "$ICECC_CMD" >&6; } 66728 else 66729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66730 $as_echo "no" >&6; } 66731 fi 66732 66733 66734 test -n "$ICECC_CMD" && break 66735 done 66736 66737 else 66738 # If it succeeded, then it was overridden by the user. We will use it 66739 # for the tool. 66740 66741 # First remove it from the list of overridden variables, so we can test 66742 # for unknown variables in the end. 66743 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 66744 66745 # Check if we try to supply an empty value 66746 if test "x$ICECC_CMD" = x; then 66747 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CMD= (no value)" >&5 66748 $as_echo "$as_me: Setting user supplied tool ICECC_CMD= (no value)" >&6;} 66749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 66750 $as_echo_n "checking for ICECC_CMD... " >&6; } 66751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 66752 $as_echo "disabled" >&6; } 66753 else 66754 # Check if the provided tool contains a complete path. 66755 tool_specified="$ICECC_CMD" 66756 tool_basename="${tool_specified##*/}" 66757 if test "x$tool_basename" = "x$tool_specified"; then 66758 # A command without a complete path is provided, search $PATH. 66759 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CMD=$tool_basename" >&5 66760 $as_echo "$as_me: Will search for user supplied tool ICECC_CMD=$tool_basename" >&6;} 66761 # Extract the first word of "$tool_basename", so it can be a program name with args. 66762 set dummy $tool_basename; ac_word=$2 66763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66764 $as_echo_n "checking for $ac_word... " >&6; } 66765 if ${ac_cv_path_ICECC_CMD+:} false; then : 66766 $as_echo_n "(cached) " >&6 66767 else 66768 case $ICECC_CMD in 66769 [\\/]* | ?:[\\/]*) 66770 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 66771 ;; 66772 *) 66773 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66774 for as_dir in $PATH 66775 do 66776 IFS=$as_save_IFS 66777 test -z "$as_dir" && as_dir=. 66778 for ac_exec_ext in '' $ac_executable_extensions; do 66779 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66780 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 66781 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66782 break 2 66783 fi 66784 done 66785 done 66786 IFS=$as_save_IFS 66787 66788 ;; 66789 esac 66790 fi 66791 ICECC_CMD=$ac_cv_path_ICECC_CMD 66792 if test -n "$ICECC_CMD"; then 66793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 66794 $as_echo "$ICECC_CMD" >&6; } 66795 else 66796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66797 $as_echo "no" >&6; } 66798 fi 66799 66800 66801 if test "x$ICECC_CMD" = x; then 66802 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 66803 fi 66804 else 66805 # Otherwise we believe it is a complete path. Use it as it is. 66806 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CMD=$tool_specified" >&5 66807 $as_echo "$as_me: Will use user supplied tool ICECC_CMD=$tool_specified" >&6;} 66808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 66809 $as_echo_n "checking for ICECC_CMD... " >&6; } 66810 if test ! -x "$tool_specified"; then 66811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 66812 $as_echo "not found" >&6; } 66813 as_fn_error $? "User supplied tool ICECC_CMD=$tool_specified does not exist or is not executable" "$LINENO" 5 66814 fi 66815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 66816 $as_echo "$tool_specified" >&6; } 66817 fi 66818 fi 66819 fi 66820 66821 fi 66822 66823 66824 66825 if test "x$ICECC_CMD" = x; then 66826 as_fn_error $? "Could not find required tool for ICECC_CMD" "$LINENO" 5 66827 fi 66828 66829 66830 old_path="$PATH" 66831 66832 # Look for icecc-create-env in some known places 66833 PATH="$PATH:/usr/lib/icecc:/usr/lib64/icecc" 66834 66835 66836 66837 # Publish this variable in the help. 66838 66839 66840 if [ -z "${ICECC_CREATE_ENV+x}" ]; then 66841 # The variable is not set by user, try to locate tool using the code snippet 66842 for ac_prog in icecc-create-env 66843 do 66844 # Extract the first word of "$ac_prog", so it can be a program name with args. 66845 set dummy $ac_prog; ac_word=$2 66846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66847 $as_echo_n "checking for $ac_word... " >&6; } 66848 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 66849 $as_echo_n "(cached) " >&6 66850 else 66851 case $ICECC_CREATE_ENV in 66852 [\\/]* | ?:[\\/]*) 66853 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 66854 ;; 66855 *) 66856 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66857 for as_dir in $PATH 66858 do 66859 IFS=$as_save_IFS 66860 test -z "$as_dir" && as_dir=. 66861 for ac_exec_ext in '' $ac_executable_extensions; do 66862 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66863 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 66864 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66865 break 2 66866 fi 66867 done 66868 done 66869 IFS=$as_save_IFS 66870 66871 ;; 66872 esac 66873 fi 66874 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 66875 if test -n "$ICECC_CREATE_ENV"; then 66876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 66877 $as_echo "$ICECC_CREATE_ENV" >&6; } 66878 else 66879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66880 $as_echo "no" >&6; } 66881 fi 66882 66883 66884 test -n "$ICECC_CREATE_ENV" && break 66885 done 66886 66887 else 66888 # The variable is set, but is it from the command line or the environment? 66889 66890 # Try to remove the string !ICECC_CREATE_ENV! from our list. 66891 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CREATE_ENV!/} 66892 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 66893 # If it failed, the variable was not from the command line. Ignore it, 66894 # but warn the user (except for BASH, which is always set by the calling BASH). 66895 if test "xICECC_CREATE_ENV" != xBASH; then 66896 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&5 66897 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&2;} 66898 fi 66899 # Try to locate tool using the code snippet 66900 for ac_prog in icecc-create-env 66901 do 66902 # Extract the first word of "$ac_prog", so it can be a program name with args. 66903 set dummy $ac_prog; ac_word=$2 66904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66905 $as_echo_n "checking for $ac_word... " >&6; } 66906 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 66907 $as_echo_n "(cached) " >&6 66908 else 66909 case $ICECC_CREATE_ENV in 66910 [\\/]* | ?:[\\/]*) 66911 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 66912 ;; 66913 *) 66914 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66915 for as_dir in $PATH 66916 do 66917 IFS=$as_save_IFS 66918 test -z "$as_dir" && as_dir=. 66919 for ac_exec_ext in '' $ac_executable_extensions; do 66920 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66921 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 66922 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66923 break 2 66924 fi 66925 done 66926 done 66927 IFS=$as_save_IFS 66928 66929 ;; 66930 esac 66931 fi 66932 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 66933 if test -n "$ICECC_CREATE_ENV"; then 66934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 66935 $as_echo "$ICECC_CREATE_ENV" >&6; } 66936 else 66937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66938 $as_echo "no" >&6; } 66939 fi 66940 66941 66942 test -n "$ICECC_CREATE_ENV" && break 66943 done 66944 66945 else 66946 # If it succeeded, then it was overridden by the user. We will use it 66947 # for the tool. 66948 66949 # First remove it from the list of overridden variables, so we can test 66950 # for unknown variables in the end. 66951 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 66952 66953 # Check if we try to supply an empty value 66954 if test "x$ICECC_CREATE_ENV" = x; then 66955 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&5 66956 $as_echo "$as_me: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&6;} 66957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 66958 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 66959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 66960 $as_echo "disabled" >&6; } 66961 else 66962 # Check if the provided tool contains a complete path. 66963 tool_specified="$ICECC_CREATE_ENV" 66964 tool_basename="${tool_specified##*/}" 66965 if test "x$tool_basename" = "x$tool_specified"; then 66966 # A command without a complete path is provided, search $PATH. 66967 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&5 66968 $as_echo "$as_me: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&6;} 66969 # Extract the first word of "$tool_basename", so it can be a program name with args. 66970 set dummy $tool_basename; ac_word=$2 66971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66972 $as_echo_n "checking for $ac_word... " >&6; } 66973 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 66974 $as_echo_n "(cached) " >&6 66975 else 66976 case $ICECC_CREATE_ENV in 66977 [\\/]* | ?:[\\/]*) 66978 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 66979 ;; 66980 *) 66981 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66982 for as_dir in $PATH 66983 do 66984 IFS=$as_save_IFS 66985 test -z "$as_dir" && as_dir=. 66986 for ac_exec_ext in '' $ac_executable_extensions; do 66987 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66988 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 66989 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66990 break 2 66991 fi 66992 done 66993 done 66994 IFS=$as_save_IFS 66995 66996 ;; 66997 esac 66998 fi 66999 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 67000 if test -n "$ICECC_CREATE_ENV"; then 67001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 67002 $as_echo "$ICECC_CREATE_ENV" >&6; } 67003 else 67004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67005 $as_echo "no" >&6; } 67006 fi 67007 67008 67009 if test "x$ICECC_CREATE_ENV" = x; then 67010 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 67011 fi 67012 else 67013 # Otherwise we believe it is a complete path. Use it as it is. 67014 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&5 67015 $as_echo "$as_me: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&6;} 67016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 67017 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 67018 if test ! -x "$tool_specified"; then 67019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 67020 $as_echo "not found" >&6; } 67021 as_fn_error $? "User supplied tool ICECC_CREATE_ENV=$tool_specified does not exist or is not executable" "$LINENO" 5 67022 fi 67023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 67024 $as_echo "$tool_specified" >&6; } 67025 fi 67026 fi 67027 fi 67028 67029 fi 67030 67031 67032 67033 if test "x$ICECC_CREATE_ENV" = x; then 67034 as_fn_error $? "Could not find required tool for ICECC_CREATE_ENV" "$LINENO" 5 67035 fi 67036 67037 67038 # Use icecc-create-env to create a minimal compilation environment that can 67039 # be sent to the other hosts in the icecream cluster. 67040 icecc_create_env_log="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env.log" 67041 ${MKDIR} -p ${CONFIGURESUPPORT_OUTPUTDIR}/icecc 67042 # Older versions of icecc does not have the --gcc parameter 67043 if ${ICECC_CREATE_ENV} | $GREP -q -e --gcc; then 67044 icecc_gcc_arg="--gcc" 67045 fi 67046 if test "x${TOOLCHAIN_TYPE}" = "xgcc"; then 67047 67048 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 67049 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${CC} ${CXX} > \ 67050 ${icecc_create_env_log} 2>&1 ) 67051 if test "$?" != "0"; then 67052 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 67053 $as_echo "$as_me: icecc-create-env output:" >&6;} 67054 cat \ 67055 ${icecc_create_env_log} 67056 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 67057 fi 67058 67059 elif test "x$TOOLCHAIN_TYPE" = "xclang"; then 67060 # For clang, the icecc compilerwrapper is needed. It usually resides next 67061 # to icecc-create-env. 67062 67063 67064 67065 # Publish this variable in the help. 67066 67067 67068 if [ -z "${ICECC_WRAPPER+x}" ]; then 67069 # The variable is not set by user, try to locate tool using the code snippet 67070 for ac_prog in compilerwrapper 67071 do 67072 # Extract the first word of "$ac_prog", so it can be a program name with args. 67073 set dummy $ac_prog; ac_word=$2 67074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67075 $as_echo_n "checking for $ac_word... " >&6; } 67076 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 67077 $as_echo_n "(cached) " >&6 67078 else 67079 case $ICECC_WRAPPER in 67080 [\\/]* | ?:[\\/]*) 67081 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 67082 ;; 67083 *) 67084 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67085 for as_dir in $PATH 67086 do 67087 IFS=$as_save_IFS 67088 test -z "$as_dir" && as_dir=. 67089 for ac_exec_ext in '' $ac_executable_extensions; do 67090 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67091 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 67092 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67093 break 2 67094 fi 67095 done 67096 done 67097 IFS=$as_save_IFS 67098 67099 ;; 67100 esac 67101 fi 67102 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 67103 if test -n "$ICECC_WRAPPER"; then 67104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 67105 $as_echo "$ICECC_WRAPPER" >&6; } 67106 else 67107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67108 $as_echo "no" >&6; } 67109 fi 67110 67111 67112 test -n "$ICECC_WRAPPER" && break 67113 done 67114 67115 else 67116 # The variable is set, but is it from the command line or the environment? 67117 67118 # Try to remove the string !ICECC_WRAPPER! from our list. 67119 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_WRAPPER!/} 67120 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 67121 # If it failed, the variable was not from the command line. Ignore it, 67122 # but warn the user (except for BASH, which is always set by the calling BASH). 67123 if test "xICECC_WRAPPER" != xBASH; then 67124 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&5 67125 $as_echo "$as_me: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&2;} 67126 fi 67127 # Try to locate tool using the code snippet 67128 for ac_prog in compilerwrapper 67129 do 67130 # Extract the first word of "$ac_prog", so it can be a program name with args. 67131 set dummy $ac_prog; ac_word=$2 67132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67133 $as_echo_n "checking for $ac_word... " >&6; } 67134 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 67135 $as_echo_n "(cached) " >&6 67136 else 67137 case $ICECC_WRAPPER in 67138 [\\/]* | ?:[\\/]*) 67139 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 67140 ;; 67141 *) 67142 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67143 for as_dir in $PATH 67144 do 67145 IFS=$as_save_IFS 67146 test -z "$as_dir" && as_dir=. 67147 for ac_exec_ext in '' $ac_executable_extensions; do 67148 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67149 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 67150 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67151 break 2 67152 fi 67153 done 67154 done 67155 IFS=$as_save_IFS 67156 67157 ;; 67158 esac 67159 fi 67160 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 67161 if test -n "$ICECC_WRAPPER"; then 67162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 67163 $as_echo "$ICECC_WRAPPER" >&6; } 67164 else 67165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67166 $as_echo "no" >&6; } 67167 fi 67168 67169 67170 test -n "$ICECC_WRAPPER" && break 67171 done 67172 67173 else 67174 # If it succeeded, then it was overridden by the user. We will use it 67175 # for the tool. 67176 67177 # First remove it from the list of overridden variables, so we can test 67178 # for unknown variables in the end. 67179 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 67180 67181 # Check if we try to supply an empty value 67182 if test "x$ICECC_WRAPPER" = x; then 67183 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_WRAPPER= (no value)" >&5 67184 $as_echo "$as_me: Setting user supplied tool ICECC_WRAPPER= (no value)" >&6;} 67185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 67186 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 67187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 67188 $as_echo "disabled" >&6; } 67189 else 67190 # Check if the provided tool contains a complete path. 67191 tool_specified="$ICECC_WRAPPER" 67192 tool_basename="${tool_specified##*/}" 67193 if test "x$tool_basename" = "x$tool_specified"; then 67194 # A command without a complete path is provided, search $PATH. 67195 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&5 67196 $as_echo "$as_me: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&6;} 67197 # Extract the first word of "$tool_basename", so it can be a program name with args. 67198 set dummy $tool_basename; ac_word=$2 67199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67200 $as_echo_n "checking for $ac_word... " >&6; } 67201 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 67202 $as_echo_n "(cached) " >&6 67203 else 67204 case $ICECC_WRAPPER in 67205 [\\/]* | ?:[\\/]*) 67206 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 67207 ;; 67208 *) 67209 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67210 for as_dir in $PATH 67211 do 67212 IFS=$as_save_IFS 67213 test -z "$as_dir" && as_dir=. 67214 for ac_exec_ext in '' $ac_executable_extensions; do 67215 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67216 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 67217 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67218 break 2 67219 fi 67220 done 67221 done 67222 IFS=$as_save_IFS 67223 67224 ;; 67225 esac 67226 fi 67227 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 67228 if test -n "$ICECC_WRAPPER"; then 67229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 67230 $as_echo "$ICECC_WRAPPER" >&6; } 67231 else 67232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67233 $as_echo "no" >&6; } 67234 fi 67235 67236 67237 if test "x$ICECC_WRAPPER" = x; then 67238 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 67239 fi 67240 else 67241 # Otherwise we believe it is a complete path. Use it as it is. 67242 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&5 67243 $as_echo "$as_me: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&6;} 67244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 67245 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 67246 if test ! -x "$tool_specified"; then 67247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 67248 $as_echo "not found" >&6; } 67249 as_fn_error $? "User supplied tool ICECC_WRAPPER=$tool_specified does not exist or is not executable" "$LINENO" 5 67250 fi 67251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 67252 $as_echo "$tool_specified" >&6; } 67253 fi 67254 fi 67255 fi 67256 67257 fi 67258 67259 67260 67261 if test "x$ICECC_WRAPPER" = x; then 67262 as_fn_error $? "Could not find required tool for ICECC_WRAPPER" "$LINENO" 5 67263 fi 67264 67265 67266 67267 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 67268 && ${ICECC_CREATE_ENV} --clang ${CC} ${ICECC_WRAPPER} > ${icecc_create_env_log} 2>&1 ) 67269 if test "$?" != "0"; then 67270 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 67271 $as_echo "$as_me: icecc-create-env output:" >&6;} 67272 cat ${icecc_create_env_log} 67273 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 67274 fi 67275 67276 else 67277 as_fn_error $? "Can only create icecc compiler packages for toolchain types gcc and clang" "$LINENO" 5 67278 fi 67279 PATH="$old_path" 67280 # The bundle with the compiler gets a name based on checksums. Parse log file 67281 # to find it. 67282 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log}`" 67283 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 67284 if test ! -f ${ICECC_ENV_BUNDLE}; then 67285 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 67286 fi 67287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for target compiler" >&5 67288 $as_echo_n "checking for icecc build environment for target compiler... " >&6; } 67289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 67290 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 67291 ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${CC} ICECC_CXX=${CXX} ${ICECC_CMD}" 67292 67293 if test "x${COMPILE_TYPE}" = "xcross"; then 67294 # If cross compiling, create a separate env package for the build compiler 67295 # Assume "gcc" or "cc" is gcc and "clang" is clang. Otherwise bail. 67296 icecc_create_env_log_build="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env_build.log" 67297 if test "x${BUILD_CC##*/}" = "xgcc" || test "x${BUILD_CC##*/}" = "xcc"; then 67298 67299 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 67300 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${BUILD_CC} ${BUILD_CXX} > \ 67301 ${icecc_create_env_log_build} 2>&1 ) 67302 if test "$?" != "0"; then 67303 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 67304 $as_echo "$as_me: icecc-create-env output:" >&6;} 67305 cat \ 67306 ${icecc_create_env_log_build} 67307 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 67308 fi 67309 67310 elif test "x${BUILD_CC##*/}" = "xclang"; then 67311 67312 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 67313 && ${ICECC_CREATE_ENV} --clang ${BUILD_CC} ${ICECC_WRAPPER} > ${icecc_create_env_log_build} 2>&1 ) 67314 if test "$?" != "0"; then 67315 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 67316 $as_echo "$as_me: icecc-create-env output:" >&6;} 67317 cat ${icecc_create_env_log_build} 67318 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 67319 fi 67320 67321 else 67322 as_fn_error $? "Cannot create icecc compiler package for ${BUILD_CC}" "$LINENO" 5 67323 fi 67324 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log_build}`" 67325 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 67326 if test ! -f ${ICECC_ENV_BUNDLE}; then 67327 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 67328 fi 67329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for build compiler" >&5 67330 $as_echo_n "checking for icecc build environment for build compiler... " >&6; } 67331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 67332 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 67333 BUILD_ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${BUILD_CC} \ 67334 ICECC_CXX=${BUILD_CXX} ${ICECC_CMD}" 67335 else 67336 BUILD_ICECC="${ICECC}" 67337 fi 67338 67339 67340 fi 67341 67342 67343 # Can the C/C++ compiler use precompiled headers? 67344 67345 67346 ############################################################################### 67347 # 67348 # Can the C/C++ compiler use precompiled headers? 67349 # 67350 # Check whether --enable-precompiled-headers was given. 67351 if test "${enable_precompiled_headers+set}" = set; then : 67352 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 67353 else 67354 ENABLE_PRECOMPH=yes 67355 fi 67356 67357 67358 USE_PRECOMPILED_HEADER=true 67359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking If precompiled header is enabled" >&5 67360 $as_echo_n "checking If precompiled header is enabled... " >&6; } 67361 if test "x$ENABLE_PRECOMPH" = xno; then 67362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 67363 $as_echo "no, forced" >&6; } 67364 USE_PRECOMPILED_HEADER=false 67365 elif test "x$ICECC" != "x"; then 67366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work effectively with icecc" >&5 67367 $as_echo "no, does not work effectively with icecc" >&6; } 67368 USE_PRECOMPILED_HEADER=false 67369 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 67370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with Solaris Studio" >&5 67371 $as_echo "no, does not work with Solaris Studio" >&6; } 67372 USE_PRECOMPILED_HEADER=false 67373 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 67374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with xlc" >&5 67375 $as_echo "no, does not work with xlc" >&6; } 67376 USE_PRECOMPILED_HEADER=false 67377 else 67378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67379 $as_echo "yes" >&6; } 67380 fi 67381 67382 if test "x$ENABLE_PRECOMPH" = xyes; then 67383 # Check that the compiler actually supports precomp headers. 67384 if test "x$TOOLCHAIN_TYPE" = xgcc; then 67385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 67386 $as_echo_n "checking that precompiled headers work... " >&6; } 67387 echo "int alfa();" > conftest.h 67388 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 67389 if test ! -f conftest.hpp.gch; then 67390 USE_PRECOMPILED_HEADER=false 67391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67392 $as_echo "no" >&6; } 67393 else 67394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67395 $as_echo "yes" >&6; } 67396 fi 67397 $RM conftest.h conftest.hpp.gch 67398 fi 67399 fi 67400 67401 67402 67403 67404 # Setup use of ccache, if available 67405 67406 # Check whether --enable-ccache was given. 67407 if test "${enable_ccache+set}" = set; then : 67408 enableval=$enable_ccache; 67409 fi 67410 67411 67412 CCACHE_STATUS= 67413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5 67414 $as_echo_n "checking is ccache enabled... " >&6; } 67415 if test "x$enable_ccache" = xyes; then 67416 if test "x$TOOLCHAIN_TYPE" = "xgcc" -o "x$TOOLCHAIN_TYPE" = "xclang"; then 67417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67418 $as_echo "yes" >&6; } 67419 OLD_PATH="$PATH" 67420 if test "x$TOOLCHAIN_PATH" != x; then 67421 PATH=$TOOLCHAIN_PATH:$PATH 67422 fi 67423 67424 67425 67426 # Publish this variable in the help. 67427 67428 67429 if [ -z "${CCACHE+x}" ]; then 67430 # The variable is not set by user, try to locate tool using the code snippet 67431 for ac_prog in ccache 67432 do 67433 # Extract the first word of "$ac_prog", so it can be a program name with args. 67434 set dummy $ac_prog; ac_word=$2 67435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67436 $as_echo_n "checking for $ac_word... " >&6; } 67437 if ${ac_cv_path_CCACHE+:} false; then : 67438 $as_echo_n "(cached) " >&6 67439 else 67440 case $CCACHE in 67441 [\\/]* | ?:[\\/]*) 67442 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 67443 ;; 67444 *) 67445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67446 for as_dir in $PATH 67447 do 67448 IFS=$as_save_IFS 67449 test -z "$as_dir" && as_dir=. 67450 for ac_exec_ext in '' $ac_executable_extensions; do 67451 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67452 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 67453 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67454 break 2 67455 fi 67456 done 67457 done 67458 IFS=$as_save_IFS 67459 67460 ;; 67461 esac 67462 fi 67463 CCACHE=$ac_cv_path_CCACHE 67464 if test -n "$CCACHE"; then 67465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 67466 $as_echo "$CCACHE" >&6; } 67467 else 67468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67469 $as_echo "no" >&6; } 67470 fi 67471 67472 67473 test -n "$CCACHE" && break 67474 done 67475 67476 else 67477 # The variable is set, but is it from the command line or the environment? 67478 67479 # Try to remove the string !CCACHE! from our list. 67480 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/} 67481 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 67482 # If it failed, the variable was not from the command line. Ignore it, 67483 # but warn the user (except for BASH, which is always set by the calling BASH). 67484 if test "xCCACHE" != xBASH; then 67485 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5 67486 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;} 67487 fi 67488 # Try to locate tool using the code snippet 67489 for ac_prog in ccache 67490 do 67491 # Extract the first word of "$ac_prog", so it can be a program name with args. 67492 set dummy $ac_prog; ac_word=$2 67493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67494 $as_echo_n "checking for $ac_word... " >&6; } 67495 if ${ac_cv_path_CCACHE+:} false; then : 67496 $as_echo_n "(cached) " >&6 67497 else 67498 case $CCACHE in 67499 [\\/]* | ?:[\\/]*) 67500 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 67501 ;; 67502 *) 67503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67504 for as_dir in $PATH 67505 do 67506 IFS=$as_save_IFS 67507 test -z "$as_dir" && as_dir=. 67508 for ac_exec_ext in '' $ac_executable_extensions; do 67509 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67510 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 67511 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67512 break 2 67513 fi 67514 done 67515 done 67516 IFS=$as_save_IFS 67517 67518 ;; 67519 esac 67520 fi 67521 CCACHE=$ac_cv_path_CCACHE 67522 if test -n "$CCACHE"; then 67523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 67524 $as_echo "$CCACHE" >&6; } 67525 else 67526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67527 $as_echo "no" >&6; } 67528 fi 67529 67530 67531 test -n "$CCACHE" && break 67532 done 67533 67534 else 67535 # If it succeeded, then it was overridden by the user. We will use it 67536 # for the tool. 67537 67538 # First remove it from the list of overridden variables, so we can test 67539 # for unknown variables in the end. 67540 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 67541 67542 # Check if we try to supply an empty value 67543 if test "x$CCACHE" = x; then 67544 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CCACHE= (no value)" >&5 67545 $as_echo "$as_me: Setting user supplied tool CCACHE= (no value)" >&6;} 67546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 67547 $as_echo_n "checking for CCACHE... " >&6; } 67548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 67549 $as_echo "disabled" >&6; } 67550 else 67551 # Check if the provided tool contains a complete path. 67552 tool_specified="$CCACHE" 67553 tool_basename="${tool_specified##*/}" 67554 if test "x$tool_basename" = "x$tool_specified"; then 67555 # A command without a complete path is provided, search $PATH. 67556 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5 67557 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;} 67558 # Extract the first word of "$tool_basename", so it can be a program name with args. 67559 set dummy $tool_basename; ac_word=$2 67560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67561 $as_echo_n "checking for $ac_word... " >&6; } 67562 if ${ac_cv_path_CCACHE+:} false; then : 67563 $as_echo_n "(cached) " >&6 67564 else 67565 case $CCACHE in 67566 [\\/]* | ?:[\\/]*) 67567 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 67568 ;; 67569 *) 67570 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67571 for as_dir in $PATH 67572 do 67573 IFS=$as_save_IFS 67574 test -z "$as_dir" && as_dir=. 67575 for ac_exec_ext in '' $ac_executable_extensions; do 67576 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67577 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 67578 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67579 break 2 67580 fi 67581 done 67582 done 67583 IFS=$as_save_IFS 67584 67585 ;; 67586 esac 67587 fi 67588 CCACHE=$ac_cv_path_CCACHE 67589 if test -n "$CCACHE"; then 67590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 67591 $as_echo "$CCACHE" >&6; } 67592 else 67593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67594 $as_echo "no" >&6; } 67595 fi 67596 67597 67598 if test "x$CCACHE" = x; then 67599 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 67600 fi 67601 else 67602 # Otherwise we believe it is a complete path. Use it as it is. 67603 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5 67604 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;} 67605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 67606 $as_echo_n "checking for CCACHE... " >&6; } 67607 if test ! -x "$tool_specified"; then 67608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 67609 $as_echo "not found" >&6; } 67610 as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5 67611 fi 67612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 67613 $as_echo "$tool_specified" >&6; } 67614 fi 67615 fi 67616 fi 67617 67618 fi 67619 67620 67621 67622 if test "x$CCACHE" = x; then 67623 as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5 67624 fi 67625 67626 67627 PATH="$OLD_PATH" 67628 CCACHE_VERSION=`$CCACHE --version | head -n1 | $SED 's/[A-Za-z ]*//'` 67629 CCACHE_STATUS="Active ($CCACHE_VERSION)" 67630 else 67631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67632 $as_echo "no" >&6; } 67633 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&5 67634 $as_echo "$as_me: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&2;} 67635 fi 67636 elif test "x$enable_ccache" = xno; then 67637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5 67638 $as_echo "no, explicitly disabled" >&6; } 67639 CCACHE_STATUS="Disabled" 67640 elif test "x$enable_ccache" = x; then 67641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67642 $as_echo "no" >&6; } 67643 else 67644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 67645 $as_echo "unknown" >&6; } 67646 as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5 67647 fi 67648 67649 67650 67651 # Check whether --with-ccache-dir was given. 67652 if test "${with_ccache_dir+set}" = set; then : 67653 withval=$with_ccache_dir; 67654 fi 67655 67656 67657 if test "x$with_ccache_dir" != x; then 67658 # When using a non home ccache directory, assume the use is to share ccache files 67659 # with other users. Thus change the umask. 67660 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 67661 if test "x$CCACHE" = x; then 67662 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5 67663 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;} 67664 fi 67665 fi 67666 67667 if test "x$CCACHE" != x; then 67668 67669 if test "x$CCACHE" != x; then 67670 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 67671 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 67672 $GREP -e '^1\.' -e '^2\.' -e '^3\.0\.' -e '^3\.1\.'` 67673 if test "x$HAS_BAD_CCACHE" != "x"; then 67674 as_fn_error $? "On macosx, ccache 3.2 or later is required, found $CCACHE_VERSION" "$LINENO" 5 67675 fi 67676 fi 67677 if test "x$USE_PRECOMPILED_HEADER" = "xtrue"; then 67678 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 67679 $GREP -e '^1.*' -e '^2.*' -e '^3\.0.*' -e '^3\.1\.[0123]$'` 67680 if test "x$HAS_BAD_CCACHE" != "x"; then 67681 as_fn_error $? "Precompiled headers requires ccache 3.1.4 or later, found $CCACHE_VERSION" "$LINENO" 5 67682 fi 67683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 67684 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 67685 CCACHE_PRECOMP_FLAG="-fpch-preprocess" 67686 PUSHED_FLAGS="$CXXFLAGS" 67687 CXXFLAGS="$CCACHE_PRECOMP_FLAG $CXXFLAGS" 67688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 67689 /* end confdefs.h. */ 67690 67691 int 67692 main () 67693 { 67694 67695 ; 67696 return 0; 67697 } 67698 _ACEOF 67699 if ac_fn_cxx_try_compile "$LINENO"; then : 67700 CC_KNOWS_CCACHE_TRICK=yes 67701 else 67702 CC_KNOWS_CCACHE_TRICK=no 67703 fi 67704 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 67705 CXXFLAGS="$PUSHED_FLAGS" 67706 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 67707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67708 $as_echo "yes" >&6; } 67709 CFLAGS_CCACHE="$CCACHE_PRECOMP_FLAG" 67710 67711 CCACHE_SLOPPINESS=pch_defines,time_macros 67712 else 67713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67714 $as_echo "no" >&6; } 67715 as_fn_error $? "Cannot use ccache with precompiled headers without compiler support for $CCACHE_PRECOMP_FLAG" "$LINENO" 5 67716 fi 67717 fi 67718 67719 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR \ 67720 CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS CCACHE_BASEDIR=$TOPDIR $CCACHE" 67721 67722 if test "x$SET_CCACHE_DIR" != x; then 67723 mkdir -p $CCACHE_DIR > /dev/null 2>&1 67724 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 67725 fi 67726 fi 67727 67728 fi 67729 67730 67731 ############################################################################### 67732 # 67733 # And now the finish... 67734 # 67735 ############################################################################### 67736 67737 # Check for some common pitfalls 67738 67739 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 67740 file_to_test="$TOPDIR/LICENSE" 67741 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 67742 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 67743 fi 67744 fi 67745 67746 67747 # Did user specify any unknown variables? 67748 67749 if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then 67750 # Replace the separating ! with spaces before presenting for end user. 67751 unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ } 67752 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5 67753 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;} 67754 fi 67755 67756 67757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 67758 $as_echo_n "checking if build directory is on local disk... " >&6; } 67759 67760 # df -l lists only local disks; if the given directory is not found then 67761 # a non-zero exit code is given 67762 if test "x$DF" = x; then 67763 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 67764 # msys does not have df; use Windows "net use" instead. 67765 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 67766 if test "x$IS_NETWORK_DISK" = x; then 67767 OUTPUT_DIR_IS_LOCAL="yes" 67768 else 67769 OUTPUT_DIR_IS_LOCAL="no" 67770 fi 67771 else 67772 # No df here, say it's local 67773 OUTPUT_DIR_IS_LOCAL="yes" 67774 fi 67775 else 67776 if $DF -l $OUTPUTDIR > /dev/null 2>&1; then 67777 OUTPUT_DIR_IS_LOCAL="yes" 67778 else 67779 OUTPUT_DIR_IS_LOCAL="no" 67780 fi 67781 fi 67782 67783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 67784 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 67785 67786 67787 67788 # Check if the user has any old-style ALT_ variables set. 67789 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 67790 67791 # Before generating output files, test if they exist. If they do, this is a reconfigure. 67792 # Since we can't properly handle the dependencies for this, warn the user about the situation 67793 if test -e $OUTPUTDIR/spec.gmk; then 67794 IS_RECONFIGURE=yes 67795 else 67796 IS_RECONFIGURE=no 67797 fi 67798 67799 67800 # At the end, call the custom hook. (Dummy macro if no custom sources available) 67801 67802 67803 # This needs to be done after CUSTOM_LATE_HOOK since we can setup custom features. 67804 67805 # Keep feature lists sorted and free of duplicates 67806 JVM_FEATURES_server="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_server | $SORT -u))" 67807 JVM_FEATURES_client="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_client | $SORT -u))" 67808 JVM_FEATURES_core="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_core | $SORT -u))" 67809 JVM_FEATURES_minimal="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_minimal | $SORT -u))" 67810 JVM_FEATURES_zero="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zero | $SORT -u))" 67811 JVM_FEATURES_zeroshark="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zeroshark | $SORT -u))" 67812 JVM_FEATURES_custom="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_custom | $SORT -u))" 67813 67814 # Validate features 67815 for variant in $JVM_VARIANTS; do 67816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking JVM features for JVM variant '$variant'" >&5 67817 $as_echo_n "checking JVM features for JVM variant '$variant'... " >&6; } 67818 features_var_name=JVM_FEATURES_$variant 67819 JVM_FEATURES_TO_TEST=${!features_var_name} 67820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES_TO_TEST" >&5 67821 $as_echo "$JVM_FEATURES_TO_TEST" >&6; } 67822 NEEDLE=${VALID_JVM_FEATURES// /$'\n'} 67823 STACK=${JVM_FEATURES_TO_TEST// /$'\n'} 67824 INVALID_FEATURES=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 67825 if test "x$INVALID_FEATURES" != x; then 67826 as_fn_error $? "Invalid JVM feature(s): $INVALID_FEATURES" "$LINENO" 5 67827 fi 67828 done 67829 67830 67831 # We're messing a bit with internal autoconf variables to put the config.status 67832 # in the output directory instead of the current directory. 67833 CONFIG_STATUS="$CONFIGURESUPPORT_OUTPUTDIR/config.status" 67834 67835 # Create the actual output files. Now the main work of configure is done. 67836 cat >confcache <<\_ACEOF 67837 # This file is a shell script that caches the results of configure 67838 # tests run on this system so they can be shared between configure 67839 # scripts and configure runs, see configure's option --config-cache. 67840 # It is not useful on other systems. If it contains results you don't 67841 # want to keep, you may remove or edit it. 67842 # 67843 # config.status only pays attention to the cache file if you give it 67844 # the --recheck option to rerun configure. 67845 # 67846 # `ac_cv_env_foo' variables (set or unset) will be overridden when 67847 # loading this file, other *unset* `ac_cv_foo' will be assigned the 67848 # following values. 67849 67850 _ACEOF 67851 67852 # The following way of writing the cache mishandles newlines in values, 67853 # but we know of no workaround that is simple, portable, and efficient. 67854 # So, we kill variables containing newlines. 67855 # Ultrix sh set writes to stderr and can't be redirected directly, 67856 # and sets the high bit in the cache file unless we assign to the vars. 67857 ( 67858 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 67859 eval ac_val=\$$ac_var 67860 case $ac_val in #( 67861 *${as_nl}*) 67862 case $ac_var in #( 67863 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 67864 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 67865 esac 67866 case $ac_var in #( 67867 _ | IFS | as_nl) ;; #( 67868 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 67869 *) { eval $ac_var=; unset $ac_var;} ;; 67870 esac ;; 67871 esac 67872 done 67873 67874 (set) 2>&1 | 67875 case $as_nl`(ac_space=' '; set) 2>&1` in #( 67876 *${as_nl}ac_space=\ *) 67877 # `set' does not quote correctly, so add quotes: double-quote 67878 # substitution turns \\\\ into \\, and sed turns \\ into \. 67879 sed -n \ 67880 "s/'/'\\\\''/g; 67881 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 67882 ;; #( 67883 *) 67884 # `set' quotes correctly as required by POSIX, so do not add quotes. 67885 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 67886 ;; 67887 esac | 67888 sort 67889 ) | 67890 sed ' 67891 /^ac_cv_env_/b end 67892 t clear 67893 :clear 67894 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 67895 t end 67896 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 67897 :end' >>confcache 67898 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 67899 if test -w "$cache_file"; then 67900 if test "x$cache_file" != "x/dev/null"; then 67901 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 67902 $as_echo "$as_me: updating cache $cache_file" >&6;} 67903 if test ! -f "$cache_file" || test -h "$cache_file"; then 67904 cat confcache >"$cache_file" 67905 else 67906 case $cache_file in #( 67907 */* | ?:*) 67908 mv -f confcache "$cache_file"$$ && 67909 mv -f "$cache_file"$$ "$cache_file" ;; #( 67910 *) 67911 mv -f confcache "$cache_file" ;; 67912 esac 67913 fi 67914 fi 67915 else 67916 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 67917 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 67918 fi 67919 fi 67920 rm -f confcache 67921 67922 test "x$prefix" = xNONE && prefix=$ac_default_prefix 67923 # Let make expand exec_prefix. 67924 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 67925 67926 # Transform confdefs.h into DEFS. 67927 # Protect against shell expansion while executing Makefile rules. 67928 # Protect against Makefile macro expansion. 67929 # 67930 # If the first sed substitution is executed (which looks for macros that 67931 # take arguments), then branch to the quote section. Otherwise, 67932 # look for a macro that doesn't take arguments. 67933 ac_script=' 67934 :mline 67935 /\\$/{ 67936 N 67937 s,\\\n,, 67938 b mline 67939 } 67940 t clear 67941 :clear 67942 s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g 67943 t quote 67944 s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g 67945 t quote 67946 b any 67947 :quote 67948 s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g 67949 s/\[/\\&/g 67950 s/\]/\\&/g 67951 s/\$/$$/g 67952 H 67953 :any 67954 ${ 67955 g 67956 s/^\n// 67957 s/\n/ /g 67958 p 67959 } 67960 ' 67961 DEFS=`sed -n "$ac_script" confdefs.h` 67962 67963 67964 ac_libobjs= 67965 ac_ltlibobjs= 67966 U= 67967 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 67968 # 1. Remove the extension, and $U if already installed. 67969 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 67970 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 67971 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 67972 # will be set to the directory where LIBOBJS objects are built. 67973 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 67974 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 67975 done 67976 LIBOBJS=$ac_libobjs 67977 67978 LTLIBOBJS=$ac_ltlibobjs 67979 67980 67981 67982 : "${CONFIG_STATUS=./config.status}" 67983 ac_write_fail=0 67984 ac_clean_files_save=$ac_clean_files 67985 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 67986 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 67987 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 67988 as_write_fail=0 67989 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 67990 #! $SHELL 67991 # Generated by $as_me. 67992 # Run this file to recreate the current configuration. 67993 # Compiler output produced by configure, useful for debugging 67994 # configure, is in config.log if it exists. 67995 67996 debug=false 67997 ac_cs_recheck=false 67998 ac_cs_silent=false 67999 68000 SHELL=\${CONFIG_SHELL-$SHELL} 68001 export SHELL 68002 _ASEOF 68003 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 68004 ## -------------------- ## 68005 ## M4sh Initialization. ## 68006 ## -------------------- ## 68007 68008 # Be more Bourne compatible 68009 DUALCASE=1; export DUALCASE # for MKS sh 68010 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 68011 emulate sh 68012 NULLCMD=: 68013 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 68014 # is contrary to our usage. Disable this feature. 68015 alias -g '${1+"$@"}'='"$@"' 68016 setopt NO_GLOB_SUBST 68017 else 68018 case `(set -o) 2>/dev/null` in #( 68019 *posix*) : 68020 set -o posix ;; #( 68021 *) : 68022 ;; 68023 esac 68024 fi 68025 68026 68027 as_nl=' 68028 ' 68029 export as_nl 68030 # Printing a long string crashes Solaris 7 /usr/bin/printf. 68031 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 68032 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 68033 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 68034 # Prefer a ksh shell builtin over an external printf program on Solaris, 68035 # but without wasting forks for bash or zsh. 68036 if test -z "$BASH_VERSION$ZSH_VERSION" \ 68037 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 68038 as_echo='print -r --' 68039 as_echo_n='print -rn --' 68040 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 68041 as_echo='printf %s\n' 68042 as_echo_n='printf %s' 68043 else 68044 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 68045 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 68046 as_echo_n='/usr/ucb/echo -n' 68047 else 68048 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 68049 as_echo_n_body='eval 68050 arg=$1; 68051 case $arg in #( 68052 *"$as_nl"*) 68053 expr "X$arg" : "X\\(.*\\)$as_nl"; 68054 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 68055 esac; 68056 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 68057 ' 68058 export as_echo_n_body 68059 as_echo_n='sh -c $as_echo_n_body as_echo' 68060 fi 68061 export as_echo_body 68062 as_echo='sh -c $as_echo_body as_echo' 68063 fi 68064 68065 # The user is always right. 68066 if test "${PATH_SEPARATOR+set}" != set; then 68067 PATH_SEPARATOR=: 68068 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 68069 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 68070 PATH_SEPARATOR=';' 68071 } 68072 fi 68073 68074 68075 # IFS 68076 # We need space, tab and new line, in precisely that order. Quoting is 68077 # there to prevent editors from complaining about space-tab. 68078 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 68079 # splitting by setting IFS to empty value.) 68080 IFS=" "" $as_nl" 68081 68082 # Find who we are. Look in the path if we contain no directory separator. 68083 as_myself= 68084 case $0 in #(( 68085 *[\\/]* ) as_myself=$0 ;; 68086 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 68087 for as_dir in $PATH 68088 do 68089 IFS=$as_save_IFS 68090 test -z "$as_dir" && as_dir=. 68091 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 68092 done 68093 IFS=$as_save_IFS 68094 68095 ;; 68096 esac 68097 # We did not find ourselves, most probably we were run as `sh COMMAND' 68098 # in which case we are not to be found in the path. 68099 if test "x$as_myself" = x; then 68100 as_myself=$0 68101 fi 68102 if test ! -f "$as_myself"; then 68103 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 68104 exit 1 68105 fi 68106 68107 # Unset variables that we do not need and which cause bugs (e.g. in 68108 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 68109 # suppresses any "Segmentation fault" message there. '((' could 68110 # trigger a bug in pdksh 5.2.14. 68111 for as_var in BASH_ENV ENV MAIL MAILPATH 68112 do eval test x\${$as_var+set} = xset \ 68113 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 68114 done 68115 PS1='$ ' 68116 PS2='> ' 68117 PS4='+ ' 68118 68119 # NLS nuisances. 68120 LC_ALL=C 68121 export LC_ALL 68122 LANGUAGE=C 68123 export LANGUAGE 68124 68125 # CDPATH. 68126 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 68127 68128 68129 # as_fn_error STATUS ERROR [LINENO LOG_FD] 68130 # ---------------------------------------- 68131 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 68132 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 68133 # script with STATUS, using 1 if that was 0. 68134 as_fn_error () 68135 { 68136 as_status=$1; test $as_status -eq 0 && as_status=1 68137 if test "$4"; then 68138 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 68139 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 68140 fi 68141 $as_echo "$as_me: error: $2" >&2 68142 as_fn_exit $as_status 68143 } # as_fn_error 68144 68145 68146 # as_fn_set_status STATUS 68147 # ----------------------- 68148 # Set $? to STATUS, without forking. 68149 as_fn_set_status () 68150 { 68151 return $1 68152 } # as_fn_set_status 68153 68154 # as_fn_exit STATUS 68155 # ----------------- 68156 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 68157 as_fn_exit () 68158 { 68159 set +e 68160 as_fn_set_status $1 68161 exit $1 68162 } # as_fn_exit 68163 68164 # as_fn_unset VAR 68165 # --------------- 68166 # Portably unset VAR. 68167 as_fn_unset () 68168 { 68169 { eval $1=; unset $1;} 68170 } 68171 as_unset=as_fn_unset 68172 # as_fn_append VAR VALUE 68173 # ---------------------- 68174 # Append the text in VALUE to the end of the definition contained in VAR. Take 68175 # advantage of any shell optimizations that allow amortized linear growth over 68176 # repeated appends, instead of the typical quadratic growth present in naive 68177 # implementations. 68178 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 68179 eval 'as_fn_append () 68180 { 68181 eval $1+=\$2 68182 }' 68183 else 68184 as_fn_append () 68185 { 68186 eval $1=\$$1\$2 68187 } 68188 fi # as_fn_append 68189 68190 # as_fn_arith ARG... 68191 # ------------------ 68192 # Perform arithmetic evaluation on the ARGs, and store the result in the 68193 # global $as_val. Take advantage of shells that can avoid forks. The arguments 68194 # must be portable across $(()) and expr. 68195 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 68196 eval 'as_fn_arith () 68197 { 68198 as_val=$(( $* )) 68199 }' 68200 else 68201 as_fn_arith () 68202 { 68203 as_val=`expr "$@" || test $? -eq 1` 68204 } 68205 fi # as_fn_arith 68206 68207 68208 if expr a : '\(a\)' >/dev/null 2>&1 && 68209 test "X`expr 00001 : '.*\(...\)'`" = X001; then 68210 as_expr=expr 68211 else 68212 as_expr=false 68213 fi 68214 68215 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 68216 as_basename=basename 68217 else 68218 as_basename=false 68219 fi 68220 68221 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 68222 as_dirname=dirname 68223 else 68224 as_dirname=false 68225 fi 68226 68227 as_me=`$as_basename -- "$0" || 68228 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 68229 X"$0" : 'X\(//\)$' \| \ 68230 X"$0" : 'X\(/\)' \| . 2>/dev/null || 68231 $as_echo X/"$0" | 68232 sed '/^.*\/\([^/][^/]*\)\/*$/{ 68233 s//\1/ 68234 q 68235 } 68236 /^X\/\(\/\/\)$/{ 68237 s//\1/ 68238 q 68239 } 68240 /^X\/\(\/\).*/{ 68241 s//\1/ 68242 q 68243 } 68244 s/.*/./; q'` 68245 68246 # Avoid depending upon Character Ranges. 68247 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 68248 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 68249 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 68250 as_cr_digits='0123456789' 68251 as_cr_alnum=$as_cr_Letters$as_cr_digits 68252 68253 ECHO_C= ECHO_N= ECHO_T= 68254 case `echo -n x` in #((((( 68255 -n*) 68256 case `echo 'xy\c'` in 68257 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 68258 xy) ECHO_C='\c';; 68259 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 68260 ECHO_T=' ';; 68261 esac;; 68262 *) 68263 ECHO_N='-n';; 68264 esac 68265 68266 rm -f conf$$ conf$$.exe conf$$.file 68267 if test -d conf$$.dir; then 68268 rm -f conf$$.dir/conf$$.file 68269 else 68270 rm -f conf$$.dir 68271 mkdir conf$$.dir 2>/dev/null 68272 fi 68273 if (echo >conf$$.file) 2>/dev/null; then 68274 if ln -s conf$$.file conf$$ 2>/dev/null; then 68275 as_ln_s='ln -s' 68276 # ... but there are two gotchas: 68277 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 68278 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 68279 # In both cases, we have to default to `cp -pR'. 68280 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 68281 as_ln_s='cp -pR' 68282 elif ln conf$$.file conf$$ 2>/dev/null; then 68283 as_ln_s=ln 68284 else 68285 as_ln_s='cp -pR' 68286 fi 68287 else 68288 as_ln_s='cp -pR' 68289 fi 68290 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 68291 rmdir conf$$.dir 2>/dev/null 68292 68293 68294 # as_fn_mkdir_p 68295 # ------------- 68296 # Create "$as_dir" as a directory, including parents if necessary. 68297 as_fn_mkdir_p () 68298 { 68299 68300 case $as_dir in #( 68301 -*) as_dir=./$as_dir;; 68302 esac 68303 test -d "$as_dir" || eval $as_mkdir_p || { 68304 as_dirs= 68305 while :; do 68306 case $as_dir in #( 68307 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 68308 *) as_qdir=$as_dir;; 68309 esac 68310 as_dirs="'$as_qdir' $as_dirs" 68311 as_dir=`$as_dirname -- "$as_dir" || 68312 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 68313 X"$as_dir" : 'X\(//\)[^/]' \| \ 68314 X"$as_dir" : 'X\(//\)$' \| \ 68315 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 68316 $as_echo X"$as_dir" | 68317 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 68318 s//\1/ 68319 q 68320 } 68321 /^X\(\/\/\)[^/].*/{ 68322 s//\1/ 68323 q 68324 } 68325 /^X\(\/\/\)$/{ 68326 s//\1/ 68327 q 68328 } 68329 /^X\(\/\).*/{ 68330 s//\1/ 68331 q 68332 } 68333 s/.*/./; q'` 68334 test -d "$as_dir" && break 68335 done 68336 test -z "$as_dirs" || eval "mkdir $as_dirs" 68337 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 68338 68339 68340 } # as_fn_mkdir_p 68341 if mkdir -p . 2>/dev/null; then 68342 as_mkdir_p='mkdir -p "$as_dir"' 68343 else 68344 test -d ./-p && rmdir ./-p 68345 as_mkdir_p=false 68346 fi 68347 68348 68349 # as_fn_executable_p FILE 68350 # ----------------------- 68351 # Test if FILE is an executable regular file. 68352 as_fn_executable_p () 68353 { 68354 test -f "$1" && test -x "$1" 68355 } # as_fn_executable_p 68356 as_test_x='test -x' 68357 as_executable_p=as_fn_executable_p 68358 68359 # Sed expression to map a string onto a valid CPP name. 68360 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 68361 68362 # Sed expression to map a string onto a valid variable name. 68363 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 68364 68365 68366 exec 6>&1 68367 ## ----------------------------------- ## 68368 ## Main body of $CONFIG_STATUS script. ## 68369 ## ----------------------------------- ## 68370 _ASEOF 68371 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 68372 68373 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68374 # Save the log message, to keep $0 and so on meaningful, and to 68375 # report actual input values of CONFIG_FILES etc. instead of their 68376 # values after options handling. 68377 ac_log=" 68378 This file was extended by OpenJDK $as_me jdk9, which was 68379 generated by GNU Autoconf 2.69. Invocation command line was 68380 68381 CONFIG_FILES = $CONFIG_FILES 68382 CONFIG_HEADERS = $CONFIG_HEADERS 68383 CONFIG_LINKS = $CONFIG_LINKS 68384 CONFIG_COMMANDS = $CONFIG_COMMANDS 68385 $ $0 $@ 68386 68387 on `(hostname || uname -n) 2>/dev/null | sed 1q` 68388 " 68389 68390 _ACEOF 68391 68392 case $ac_config_files in *" 68393 "*) set x $ac_config_files; shift; ac_config_files=$*;; 68394 esac 68395 68396 68397 68398 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68399 # Files that config.status was made for. 68400 config_files="$ac_config_files" 68401 68402 _ACEOF 68403 68404 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68405 ac_cs_usage="\ 68406 \`$as_me' instantiates files and other configuration actions 68407 from templates according to the current configuration. Unless the files 68408 and actions are specified as TAGs, all are instantiated by default. 68409 68410 Usage: $0 [OPTION]... [TAG]... 68411 68412 -h, --help print this help, then exit 68413 -V, --version print version number and configuration settings, then exit 68414 --config print configuration, then exit 68415 -q, --quiet, --silent 68416 do not print progress messages 68417 -d, --debug don't remove temporary files 68418 --recheck update $as_me by reconfiguring in the same conditions 68419 --file=FILE[:TEMPLATE] 68420 instantiate the configuration file FILE 68421 68422 Configuration files: 68423 $config_files 68424 68425 Report bugs to <build-dev@openjdk.java.net>. 68426 OpenJDK home page: <http://openjdk.java.net>." 68427 68428 _ACEOF 68429 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68430 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 68431 ac_cs_version="\\ 68432 OpenJDK config.status jdk9 68433 configured by $0, generated by GNU Autoconf 2.69, 68434 with options \\"\$ac_cs_config\\" 68435 68436 Copyright (C) 2012 Free Software Foundation, Inc. 68437 This config.status script is free software; the Free Software Foundation 68438 gives unlimited permission to copy, distribute and modify it." 68439 68440 ac_pwd='$ac_pwd' 68441 srcdir='$srcdir' 68442 AWK='$AWK' 68443 test -n "\$AWK" || AWK=awk 68444 _ACEOF 68445 68446 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68447 # The default lists apply if the user does not specify any file. 68448 ac_need_defaults=: 68449 while test $# != 0 68450 do 68451 case $1 in 68452 --*=?*) 68453 ac_option=`expr "X$1" : 'X\([^=]*\)='` 68454 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 68455 ac_shift=: 68456 ;; 68457 --*=) 68458 ac_option=`expr "X$1" : 'X\([^=]*\)='` 68459 ac_optarg= 68460 ac_shift=: 68461 ;; 68462 *) 68463 ac_option=$1 68464 ac_optarg=$2 68465 ac_shift=shift 68466 ;; 68467 esac 68468 68469 case $ac_option in 68470 # Handling of the options. 68471 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 68472 ac_cs_recheck=: ;; 68473 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 68474 $as_echo "$ac_cs_version"; exit ;; 68475 --config | --confi | --conf | --con | --co | --c ) 68476 $as_echo "$ac_cs_config"; exit ;; 68477 --debug | --debu | --deb | --de | --d | -d ) 68478 debug=: ;; 68479 --file | --fil | --fi | --f ) 68480 $ac_shift 68481 case $ac_optarg in 68482 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 68483 '') as_fn_error $? "missing file argument" ;; 68484 esac 68485 as_fn_append CONFIG_FILES " '$ac_optarg'" 68486 ac_need_defaults=false;; 68487 --he | --h | --help | --hel | -h ) 68488 $as_echo "$ac_cs_usage"; exit ;; 68489 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 68490 | -silent | --silent | --silen | --sile | --sil | --si | --s) 68491 ac_cs_silent=: ;; 68492 68493 # This is an error. 68494 -*) as_fn_error $? "unrecognized option: \`$1' 68495 Try \`$0 --help' for more information." ;; 68496 68497 *) as_fn_append ac_config_targets " $1" 68498 ac_need_defaults=false ;; 68499 68500 esac 68501 shift 68502 done 68503 68504 ac_configure_extra_args= 68505 68506 if $ac_cs_silent; then 68507 exec 6>/dev/null 68508 ac_configure_extra_args="$ac_configure_extra_args --silent" 68509 fi 68510 68511 _ACEOF 68512 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68513 if \$ac_cs_recheck; then 68514 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 68515 shift 68516 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 68517 CONFIG_SHELL='$SHELL' 68518 export CONFIG_SHELL 68519 exec "\$@" 68520 fi 68521 68522 _ACEOF 68523 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68524 exec 5>>config.log 68525 { 68526 echo 68527 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 68528 ## Running $as_me. ## 68529 _ASBOX 68530 $as_echo "$ac_log" 68531 } >&5 68532 68533 _ACEOF 68534 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68535 _ACEOF 68536 68537 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68538 68539 # Handling of arguments. 68540 for ac_config_target in $ac_config_targets 68541 do 68542 case $ac_config_target in 68543 "$OUTPUTDIR/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUTDIR/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 68544 "$OUTPUTDIR/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUTDIR/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 68545 "$OUTPUTDIR/buildjdk-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUTDIR/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" ;; 68546 "$OUTPUTDIR/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUTDIR/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 68547 "$OUTPUTDIR/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUTDIR/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 68548 68549 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 68550 esac 68551 done 68552 68553 68554 # If the user did not use the arguments to specify the items to instantiate, 68555 # then the envvar interface is used. Set only those that are not. 68556 # We use the long form for the default assignment because of an extremely 68557 # bizarre bug on SunOS 4.1.3. 68558 if $ac_need_defaults; then 68559 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 68560 fi 68561 68562 # Have a temporary directory for convenience. Make it in the build tree 68563 # simply because there is no reason against having it here, and in addition, 68564 # creating and moving files from /tmp can sometimes cause problems. 68565 # Hook for its removal unless debugging. 68566 # Note that there is a small window in which the directory will not be cleaned: 68567 # after its creation but before its name has been assigned to `$tmp'. 68568 $debug || 68569 { 68570 tmp= ac_tmp= 68571 trap 'exit_status=$? 68572 : "${ac_tmp:=$tmp}" 68573 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 68574 ' 0 68575 trap 'as_fn_exit 1' 1 2 13 15 68576 } 68577 # Create a (secure) tmp directory for tmp files. 68578 68579 { 68580 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 68581 test -d "$tmp" 68582 } || 68583 { 68584 tmp=./conf$$-$RANDOM 68585 (umask 077 && mkdir "$tmp") 68586 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 68587 ac_tmp=$tmp 68588 68589 # Set up the scripts for CONFIG_FILES section. 68590 # No need to generate them if there are no CONFIG_FILES. 68591 # This happens for instance with `./config.status config.h'. 68592 if test -n "$CONFIG_FILES"; then 68593 68594 68595 ac_cr=`echo X | tr X '\015'` 68596 # On cygwin, bash can eat \r inside `` if the user requested igncr. 68597 # But we know of no other shell where ac_cr would be empty at this 68598 # point, so we can use a bashism as a fallback. 68599 if test "x$ac_cr" = x; then 68600 eval ac_cr=\$\'\\r\' 68601 fi 68602 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 68603 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 68604 ac_cs_awk_cr='\\r' 68605 else 68606 ac_cs_awk_cr=$ac_cr 68607 fi 68608 68609 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 68610 _ACEOF 68611 68612 68613 { 68614 echo "cat >conf$$subs.awk <<_ACEOF" && 68615 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 68616 echo "_ACEOF" 68617 } >conf$$subs.sh || 68618 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 68619 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 68620 ac_delim='%!_!# ' 68621 for ac_last_try in false false false false false :; do 68622 . ./conf$$subs.sh || 68623 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 68624 68625 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 68626 if test $ac_delim_n = $ac_delim_num; then 68627 break 68628 elif $ac_last_try; then 68629 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 68630 else 68631 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 68632 fi 68633 done 68634 rm -f conf$$subs.sh 68635 68636 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68637 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 68638 _ACEOF 68639 sed -n ' 68640 h 68641 s/^/S["/; s/!.*/"]=/ 68642 p 68643 g 68644 s/^[^!]*!// 68645 :repl 68646 t repl 68647 s/'"$ac_delim"'$// 68648 t delim 68649 :nl 68650 h 68651 s/\(.\{148\}\)..*/\1/ 68652 t more1 68653 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 68654 p 68655 n 68656 b repl 68657 :more1 68658 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 68659 p 68660 g 68661 s/.\{148\}// 68662 t nl 68663 :delim 68664 h 68665 s/\(.\{148\}\)..*/\1/ 68666 t more2 68667 s/["\\]/\\&/g; s/^/"/; s/$/"/ 68668 p 68669 b 68670 :more2 68671 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 68672 p 68673 g 68674 s/.\{148\}// 68675 t delim 68676 ' <conf$$subs.awk | sed ' 68677 /^[^""]/{ 68678 N 68679 s/\n// 68680 } 68681 ' >>$CONFIG_STATUS || ac_write_fail=1 68682 rm -f conf$$subs.awk 68683 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68684 _ACAWK 68685 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 68686 for (key in S) S_is_set[key] = 1 68687 FS = "" 68688 68689 } 68690 { 68691 line = $ 0 68692 nfields = split(line, field, "@") 68693 substed = 0 68694 len = length(field[1]) 68695 for (i = 2; i < nfields; i++) { 68696 key = field[i] 68697 keylen = length(key) 68698 if (S_is_set[key]) { 68699 value = S[key] 68700 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 68701 len += length(value) + length(field[++i]) 68702 substed = 1 68703 } else 68704 len += 1 + keylen 68705 } 68706 68707 print line 68708 } 68709 68710 _ACAWK 68711 _ACEOF 68712 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68713 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 68714 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 68715 else 68716 cat 68717 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 68718 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 68719 _ACEOF 68720 68721 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 68722 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 68723 # trailing colons and then remove the whole line if VPATH becomes empty 68724 # (actually we leave an empty line to preserve line numbers). 68725 if test "x$srcdir" = x.; then 68726 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 68727 h 68728 s/// 68729 s/^/:/ 68730 s/[ ]*$/:/ 68731 s/:\$(srcdir):/:/g 68732 s/:\${srcdir}:/:/g 68733 s/:@srcdir@:/:/g 68734 s/^:*// 68735 s/:*$// 68736 x 68737 s/\(=[ ]*\).*/\1/ 68738 G 68739 s/\n// 68740 s/^[^=]*=[ ]*$// 68741 }' 68742 fi 68743 68744 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68745 fi # test -n "$CONFIG_FILES" 68746 68747 68748 eval set X " :F $CONFIG_FILES " 68749 shift 68750 for ac_tag 68751 do 68752 case $ac_tag in 68753 :[FHLC]) ac_mode=$ac_tag; continue;; 68754 esac 68755 case $ac_mode$ac_tag in 68756 :[FHL]*:*);; 68757 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 68758 :[FH]-) ac_tag=-:-;; 68759 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 68760 esac 68761 ac_save_IFS=$IFS 68762 IFS=: 68763 set x $ac_tag 68764 IFS=$ac_save_IFS 68765 shift 68766 ac_file=$1 68767 shift 68768 68769 case $ac_mode in 68770 :L) ac_source=$1;; 68771 :[FH]) 68772 ac_file_inputs= 68773 for ac_f 68774 do 68775 case $ac_f in 68776 -) ac_f="$ac_tmp/stdin";; 68777 *) # Look for the file first in the build tree, then in the source tree 68778 # (if the path is not absolute). The absolute path cannot be DOS-style, 68779 # because $ac_f cannot contain `:'. 68780 test -f "$ac_f" || 68781 case $ac_f in 68782 [\\/$]*) false;; 68783 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 68784 esac || 68785 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 68786 esac 68787 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 68788 as_fn_append ac_file_inputs " '$ac_f'" 68789 done 68790 68791 # Let's still pretend it is `configure' which instantiates (i.e., don't 68792 # use $as_me), people would be surprised to read: 68793 # /* config.h. Generated by config.status. */ 68794 configure_input='Generated from '` 68795 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 68796 `' by configure.' 68797 if test x"$ac_file" != x-; then 68798 configure_input="$ac_file. $configure_input" 68799 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 68800 $as_echo "$as_me: creating $ac_file" >&6;} 68801 fi 68802 # Neutralize special characters interpreted by sed in replacement strings. 68803 case $configure_input in #( 68804 *\&* | *\|* | *\\* ) 68805 ac_sed_conf_input=`$as_echo "$configure_input" | 68806 sed 's/[\\\\&|]/\\\\&/g'`;; #( 68807 *) ac_sed_conf_input=$configure_input;; 68808 esac 68809 68810 case $ac_tag in 68811 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 68812 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 68813 esac 68814 ;; 68815 esac 68816 68817 ac_dir=`$as_dirname -- "$ac_file" || 68818 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 68819 X"$ac_file" : 'X\(//\)[^/]' \| \ 68820 X"$ac_file" : 'X\(//\)$' \| \ 68821 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 68822 $as_echo X"$ac_file" | 68823 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 68824 s//\1/ 68825 q 68826 } 68827 /^X\(\/\/\)[^/].*/{ 68828 s//\1/ 68829 q 68830 } 68831 /^X\(\/\/\)$/{ 68832 s//\1/ 68833 q 68834 } 68835 /^X\(\/\).*/{ 68836 s//\1/ 68837 q 68838 } 68839 s/.*/./; q'` 68840 as_dir="$ac_dir"; as_fn_mkdir_p 68841 ac_builddir=. 68842 68843 case "$ac_dir" in 68844 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 68845 *) 68846 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 68847 # A ".." for each directory in $ac_dir_suffix. 68848 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 68849 case $ac_top_builddir_sub in 68850 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 68851 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 68852 esac ;; 68853 esac 68854 ac_abs_top_builddir=$ac_pwd 68855 ac_abs_builddir=$ac_pwd$ac_dir_suffix 68856 # for backward compatibility: 68857 ac_top_builddir=$ac_top_build_prefix 68858 68859 case $srcdir in 68860 .) # We are building in place. 68861 ac_srcdir=. 68862 ac_top_srcdir=$ac_top_builddir_sub 68863 ac_abs_top_srcdir=$ac_pwd ;; 68864 [\\/]* | ?:[\\/]* ) # Absolute name. 68865 ac_srcdir=$srcdir$ac_dir_suffix; 68866 ac_top_srcdir=$srcdir 68867 ac_abs_top_srcdir=$srcdir ;; 68868 *) # Relative name. 68869 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 68870 ac_top_srcdir=$ac_top_build_prefix$srcdir 68871 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 68872 esac 68873 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 68874 68875 68876 case $ac_mode in 68877 :F) 68878 # 68879 # CONFIG_FILE 68880 # 68881 68882 _ACEOF 68883 68884 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68885 # If the template does not know about datarootdir, expand it. 68886 # FIXME: This hack should be removed a few years after 2.60. 68887 ac_datarootdir_hack=; ac_datarootdir_seen= 68888 ac_sed_dataroot=' 68889 /datarootdir/ { 68890 p 68891 q 68892 } 68893 /@datadir@/p 68894 /@docdir@/p 68895 /@infodir@/p 68896 /@localedir@/p 68897 /@mandir@/p' 68898 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 68899 *datarootdir*) ac_datarootdir_seen=yes;; 68900 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 68901 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 68902 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 68903 _ACEOF 68904 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68905 ac_datarootdir_hack=' 68906 s&@datadir@&$datadir&g 68907 s&@docdir@&$docdir&g 68908 s&@infodir@&$infodir&g 68909 s&@localedir@&$localedir&g 68910 s&@mandir@&$mandir&g 68911 s&\\\${datarootdir}&$datarootdir&g' ;; 68912 esac 68913 _ACEOF 68914 68915 # Neutralize VPATH when `$srcdir' = `.'. 68916 # Shell code in configure.ac might set extrasub. 68917 # FIXME: do we really want to maintain this feature? 68918 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68919 ac_sed_extra="$ac_vpsub 68920 $extrasub 68921 _ACEOF 68922 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68923 :t 68924 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 68925 s|@configure_input@|$ac_sed_conf_input|;t t 68926 s&@top_builddir@&$ac_top_builddir_sub&;t t 68927 s&@top_build_prefix@&$ac_top_build_prefix&;t t 68928 s&@srcdir@&$ac_srcdir&;t t 68929 s&@abs_srcdir@&$ac_abs_srcdir&;t t 68930 s&@top_srcdir@&$ac_top_srcdir&;t t 68931 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 68932 s&@builddir@&$ac_builddir&;t t 68933 s&@abs_builddir@&$ac_abs_builddir&;t t 68934 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 68935 $ac_datarootdir_hack 68936 " 68937 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 68938 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 68939 68940 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 68941 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 68942 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 68943 "$ac_tmp/out"`; test -z "$ac_out"; } && 68944 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 68945 which seems to be undefined. Please make sure it is defined" >&5 68946 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 68947 which seems to be undefined. Please make sure it is defined" >&2;} 68948 68949 rm -f "$ac_tmp/stdin" 68950 case $ac_file in 68951 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 68952 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 68953 esac \ 68954 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 68955 ;; 68956 68957 68958 68959 esac 68960 68961 done # for ac_tag 68962 68963 68964 as_fn_exit 0 68965 _ACEOF 68966 ac_clean_files=$ac_clean_files_save 68967 68968 test $ac_write_fail = 0 || 68969 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 68970 68971 68972 # configure is writing to config.log, and then calls config.status. 68973 # config.status does its own redirection, appending to config.log. 68974 # Unfortunately, on DOS this fails, as config.log is still kept open 68975 # by configure, so config.status won't be able to write to it; its 68976 # output is simply discarded. So we exec the FD to /dev/null, 68977 # effectively closing config.log, so it can be properly (re)opened and 68978 # appended to by config.status. When coming back to configure, we 68979 # need to make the FD available again. 68980 if test "$no_create" != yes; then 68981 ac_cs_success=: 68982 ac_config_status_args= 68983 test "$silent" = yes && 68984 ac_config_status_args="$ac_config_status_args --quiet" 68985 exec 5>/dev/null 68986 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 68987 exec 5>>config.log 68988 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 68989 # would make configure fail if this is the last instruction. 68990 $ac_cs_success || as_fn_exit 1 68991 fi 68992 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 68993 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 68994 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 68995 fi 68996 68997 68998 # After AC_OUTPUT, we need to do final work 68999 69000 69001 # Try to move config.log (generated by autoconf) to the configure-support directory. 69002 if test -e ./config.log; then 69003 $MV -f ./config.log "$CONFIGURESUPPORT_OUTPUTDIR/config.log" 2> /dev/null 69004 fi 69005 69006 # Rotate our log file (configure.log) 69007 if test -e "$OUTPUTDIR/configure.log.old"; then 69008 $RM -f "$OUTPUTDIR/configure.log.old" 69009 fi 69010 if test -e "$OUTPUTDIR/configure.log"; then 69011 $MV -f "$OUTPUTDIR/configure.log" "$OUTPUTDIR/configure.log.old" 2> /dev/null 69012 fi 69013 69014 # Move configure.log from current directory to the build output root 69015 if test -e ./configure.log; then 69016 $MV -f ./configure.log "$OUTPUTDIR/configure.log" 2> /dev/null 69017 fi 69018 69019 # Make the compare script executable 69020 $CHMOD +x $OUTPUTDIR/compare.sh 69021 69022 69023 # Finally output some useful information to the user 69024 69025 # Finally output some useful information to the user 69026 69027 printf "\n" 69028 printf "====================================================\n" 69029 if test "x$no_create" != "xyes"; then 69030 if test "x$IS_RECONFIGURE" != "xyes"; then 69031 printf "A new configuration has been successfully created in\n%s\n" "$OUTPUTDIR" 69032 else 69033 printf "The existing configuration has been successfully updated in\n%s\n" "$OUTPUTDIR" 69034 fi 69035 else 69036 if test "x$IS_RECONFIGURE" != "xyes"; then 69037 printf "A configuration has been successfully checked but not created\n" 69038 else 69039 printf "The existing configuration has been successfully checked in\n%s\n" "$OUTPUTDIR" 69040 fi 69041 fi 69042 if test "x$CONFIGURE_COMMAND_LINE" != x; then 69043 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 69044 else 69045 printf "using default settings.\n" 69046 fi 69047 69048 printf "\n" 69049 printf "Configuration summary:\n" 69050 printf "* Debug level: $DEBUG_LEVEL\n" 69051 printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n" 69052 printf "* JDK variant: $JDK_VARIANT\n" 69053 printf "* JVM variants: $JVM_VARIANTS\n" 69054 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 69055 printf "* Version string: $VERSION_STRING ($VERSION_SHORT)\n" 69056 69057 printf "\n" 69058 printf "Tools summary:\n" 69059 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 69060 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 69061 fi 69062 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 69063 if test "x$TOOLCHAIN_VERSION" != "x"; then 69064 print_version=" $TOOLCHAIN_VERSION" 69065 fi 69066 printf "* Toolchain: $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION$print_version)\n" 69067 printf "* C Compiler: Version $CC_VERSION_NUMBER (at $CC)\n" 69068 printf "* C++ Compiler: Version $CXX_VERSION_NUMBER (at $CXX)\n" 69069 69070 printf "\n" 69071 printf "Build performance summary:\n" 69072 printf "* Cores to use: $JOBS\n" 69073 printf "* Memory limit: $MEMORY_SIZE MB\n" 69074 if test "x$CCACHE_STATUS" != "x"; then 69075 printf "* ccache status: $CCACHE_STATUS\n" 69076 fi 69077 printf "\n" 69078 69079 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 69080 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 69081 printf "will result in longer build times.\n" 69082 printf "\n" 69083 fi 69084 69085 if test "x$FOUND_ALT_VARIABLES" != "x"; then 69086 printf "WARNING: You have old-style ALT_ environment variables set.\n" 69087 printf "These are not respected, and will be ignored. It is recommended\n" 69088 printf "that you clean your environment. The following variables are set:\n" 69089 printf "$FOUND_ALT_VARIABLES\n" 69090 printf "\n" 69091 fi 69092 69093 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 69094 printf "WARNING: Your build output directory is not on a local disk.\n" 69095 printf "This will severely degrade build performance!\n" 69096 printf "It is recommended that you create an output directory on a local disk,\n" 69097 printf "and run the configure script again from that directory.\n" 69098 printf "\n" 69099 fi 69100 69101 if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then 69102 printf "WARNING: The result of this configuration has overridden an older\n" 69103 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 69104 printf "proper build. Failure to do so might result in strange build problems.\n" 69105 printf "\n" 69106 fi 69107 69108 if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then 69109 printf "WARNING: The result of this configuration was not saved.\n" 69110 printf "You should run without '--no-create | -n' to create the configuration.\n" 69111 printf "\n" 69112 fi 69113 69114 69115 69116 # Locate config.log. 69117 if test -e "$CONFIGURESUPPORT_OUTPUTDIR/config.log"; then 69118 CONFIG_LOG_PATH="$CONFIGURESUPPORT_OUTPUTDIR" 69119 elif test -e "./config.log"; then 69120 CONFIG_LOG_PATH="." 69121 fi 69122 69123 if test -e "$CONFIG_LOG_PATH/config.log"; then 69124 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" > /dev/null 2>&1 69125 if test $? -eq 0; then 69126 printf "The following warnings were produced. Repeated here for convenience:\n" 69127 # We must quote sed expression (using []) to stop m4 from eating the []. 69128 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" | $SED -e 's/^configure:[0-9]*: //' 69129 printf "\n" 69130 fi 69131 fi 69132